优化返回页面

This commit is contained in:
pengxiaolong
2025-05-22 22:05:55 +08:00
parent 6ca66f45d4
commit c55be10783
59 changed files with 3428 additions and 44 deletions

View File

@@ -20,6 +20,7 @@ export default {
userInfo: {},
info: {},
userSig: "",
lastPage: "",
};
},
onLoad() {
@@ -29,7 +30,18 @@ export default {
this.userInfo = res.userInfo;
},
});
uni.getStorage({
key: "lastPage",
success: (res) => {
this.lastPage = "/"+res.data;
console.log(this.lastPage);
},
fail: () => {
this.lastPage = "/pages/Home/Home";
},
})
},
methods: {
// 获取手机号
async getPhoneNumber(e) {
@@ -66,8 +78,9 @@ export default {
uni.hideLoading();
TUIlogin(this.info.data.chatInfo.appId, this.info.data.info.id,this.userSig.userSig)
//跳转原来页面否则首页
console.log("跳的地址", this.lastPage);
uni.reLaunch({
url: this.$global.lastPage || "/pages/Home/Home", // 默认页
url: this.lastPage,
});
}
} else {