/*
 * @Date: 2021-12-08 16:23:20
 * @LastEditors: JinxuChen
 * @LastEditTime: 2021-12-08 16:23:45
 * @FilePath: \GpsCardAdmin\src\utils\clear-local-storage.js
 * @description: 增加 清除local Storage的方法
 */
const  prefix = 'gps_card_admin_';
const LocalStorageService = {
    clearAll(store) {
        for (let k in store.getters) {
            this.clear(store, k);
        }
    },
    clear(store, type) {
        store.commit(type, '');
        window.localStorage[ prefix + type ] = '';
    },
};
export default LocalStorageService;