1234567891011121314151617181920212223242526272829 |
- // store/index.js
- import Vue from 'vue';
- import Vuex from 'vuex';
- Vue.use(Vuex);
- export default new Vuex.Store({
- state: {
- // imgpath: 'https://fbylive.obs.cn-southwest-2.myhuaweicloud.com',//福本源图片请求地址
- Requestpath: 'https://userapp.fbylive.com',//福本源接口请求地址
- logoname:'本源一身轻',
- imgpath: 'https://zkzh-2024.oss-cn-beijing.aliyuncs.com',//中康图片请求地址
- // Requestpath: 'https://userapp.zkhj6.com'//中康接口请求地址
- },
- mutations: {
- setCount(state, value) {
- state.count = value;
- },
- setUserInfo(state, info) {
- state.userInfo = info;
- }
- },
- actions: {
- fetchUser({ commit }) {
- // const res = await uni.request({ url: '/api/user' });
- commit('setUserInfo', 'noe');
- }
- }
- });
|