Files
autoAiWorkSys/app/store/modules/app.js
张成 e17d5610f5 1
2025-12-22 16:26:59 +08:00

29 lines
523 B
JavaScript

/**
* 应用全局状态管理
*/
export default {
namespaced: true,
state: {
currentVersion: '1.0.0',
isLoading: true,
startTime: Date.now()
},
mutations: {
SET_VERSION(state, version) {
state.currentVersion = version;
},
SET_LOADING(state, loading) {
state.isLoading = loading;
}
},
actions: {
setVersion({ commit }, version) {
commit('SET_VERSION', version);
},
setLoading({ commit }, loading) {
commit('SET_LOADING', loading);
}
}
};