jy-safe-app/store/index.js

41 lines
774 B
JavaScript
Raw Permalink Normal View History

2025-10-14 15:17:30 +08:00
import Vue from 'vue'
import Vuex from 'vuex'
// import homeModule from './modules/home.js'
Vue.use(Vuex)
export default new Vuex.Store({
state: {
imageLists: [],
auditModel: {},
userAndDepartment: {
allIds: [],
userIds: [],
departmentIds: [],
allUserIdWithName: [],
allUserInfos: [],
allDepartmentInfos: [],
allInfos: []
},
BASE_API: '',
count: 1
},
mutations: {
increment (state) {
state.count++
},
updateImageLists(state, lists) {
state.imageLists = lists
},
updateAuditModel(state, obj) {
state.auditModel = obj
},
updateUserAndDepartment(state, obj) {
state.userAndDepartment = obj
}
// modules: {
// homeModule
// },
}
})