You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
22 lines
441 B
JavaScript
22 lines
441 B
JavaScript
|
6 years ago
|
import Vue from 'vue'
|
||
|
|
import Vuex from 'vuex'
|
||
|
|
|
||
|
|
Vue.use(Vuex)
|
||
|
|
|
||
|
|
export default new Vuex.Store({
|
||
|
|
state: {
|
||
|
|
aside_collapsed: false,
|
||
|
|
userInfo: JSON.parse(sessionStorage.getItem('userInfo') || '{}')
|
||
|
|
},
|
||
|
|
mutations: {
|
||
|
|
// 通用修改
|
||
|
|
setState(state, object) {
|
||
|
|
for (let key in object) {
|
||
|
|
state[key] = object[key]
|
||
|
|
}
|
||
|
|
},
|
||
|
|
},
|
||
|
|
actions: {},
|
||
|
|
modules: {}
|
||
|
|
})
|