123456789101112131415161718192021222324252627282930313233343536373839404142434445464748 |
- import Vue from 'vue'
- import Vuex from 'vuex'
- import mutations from './mutations'
- import actions from './action'
- import getters from './getters'
- // import { ctx } from '@/config/config.js';
- Vue.use(Vuex);
- const state = {
- // ctx: process.env.NODE_ENV === 'production' ? ('/' + ctx) : '',
- ctx: '',
- // 登录token
- token: null,
- // 面包屑
- breadcrumb: [],
- // 请求地址
- ajaxCtx: '',
- // 图片基础路径
- imgBaseUrl: '',
- // 文件基础路径
- fileBaseUrl: '',
- // 上传文件路径
- fileUploadUrl: '',
- // 下载文件路径
- fileDownloadUrl: '',
- // 从表页面返回的当前页面值
- currentStates: {},
- // 仓库编码
- storageattr: '',
- // 内控标准-成分、材质、公差、探伤-判断是否存在未保存的数据,1:存在、0:不存在
- nkHaveChild: '',
- // 内控标准-成分、材质、公差、探伤页面观察此属性的变化,如果为'1'则检验自身页面中是否存在未保存数据
- // 存在则将nkHaveChild赋值为'1',反之赋值为'0'
- nkDoCheck: '',
- jfHaveChild: '',
- jfDoCheck: '',
- // apollo
- apolloUser: [],
- apolloOrg: [],
- pageShow: true
- };
- export default new Vuex.Store({
- state,
- getters,
- actions,
- mutations
- });
|