refactor: 移动端升级 Vue3 + uView Plus

将 lilishop-uniapp 从 Vue2/uView 1.6 迁移到 Vue3/uview-plus,优先支持 H5/微商城与微信小程序;移除 vendored uview-ui,改用 npm 依赖、Vuex4 与迁移脚本/补丁,并补充 VUE3_MIGRATION.md 回归清单。

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
pikachu1995@126.com
2026-06-30 18:50:38 +08:00
parent c290c7a329
commit dc2bef455a
299 changed files with 5507 additions and 43811 deletions

View File

@@ -1,39 +1,34 @@
import Vue from "vue";
import Vuex from "vuex";
import storage from "@/utils/storage";
import { createStore } from 'vuex'
import storage from '@/utils/storage'
Vue.use(Vuex);
const store = new Vuex.Store({
const store = createStore({
state: {
isShowToast:false, // 是否在展示Toast中
remark:[], //填写订单备注
shareLink:"", //分享链接
verificationKey: "", //获取key表示验证通过
distributionId:"", //分销员Id 如果当前账户从未登录过时记录
isShowToast: false,
remark: [],
shareLink: '',
verificationKey: '',
distributionId: '',
hasLogin: storage.getHasLogin(),
userInfo: storage.getUserInfo(),
uuid: storage.getUuid(),
token: "",
token: ''
},
mutations: {
login(state, userInfo) {
state.userInfo = userInfo || {};
state.userInfo = userInfo || {}
state.userName =
userInfo.Name || userInfo.Nickname || userInfo.Username || "匿名用户";
state.hasLogin = true;
userInfo.Name || userInfo.Nickname || userInfo.Username || '匿名用户'
state.hasLogin = true
},
logout(state) {
state.userName = "";
state.hasLogin = false;
state.userName = ''
state.hasLogin = false
},
// 设置填写订单中备注
setRemark(state, remark) {
state.remark = remark;
state.remark = remark
}
},
actions: {},
});
actions: {}
})
export default store;
export default store