上传头像

This commit is contained in:
pengxiaolong
2025-05-20 19:09:04 +08:00
parent 6107739077
commit 829199a197
34 changed files with 4902 additions and 233 deletions

View File

@@ -8,7 +8,8 @@ const _sfc_main = {
data() {
return {
userInfo: {},
info: {}
info: {},
userSig: ""
};
},
onLoad() {
@@ -34,27 +35,26 @@ const _sfc_main = {
},
userInfo: false
});
common_vendor.index.__f__("log", "at pages/login/login.vue:47", "登录结果:", res);
this.info = res;
const sdkAppID = Number(this.info.data.chatInfo.appId);
const userID = "administrator";
this.userSig = components_debug_GenerateTestUserSig.genTestUserSig({
SDKAPPID: sdkAppID,
SECRETKEY: this.info.data.chatInfo.appKey,
userID
});
common_vendor.index.setStorageSync("chatInfo", this.info.data.chatInfo);
common_vendor.index.setStorageSync("userSig", this.userSig);
common_vendor.index.setStorageSync("userinfo", this.info.data.info);
if (this.info.code === 200) {
if (this.info.data.newAccount) {
const sdkAppID = Number(this.info.data.chatInfo.appId);
const userID = "administrator";
const { userSig: userSig2 } = components_debug_GenerateTestUserSig.genTestUserSig({
SDKAPPID: sdkAppID,
SECRETKEY: this.info.data.chatInfo.appKey,
userID
});
common_vendor.index.setStorageSync("chatInfo", this.info.data.chatInfo);
common_vendor.index.setStorageSync("userSig", userSig2);
common_vendor.index.setStorageSync("userinfo", this.info.data.info);
common_vendor.index.reLaunch({
url: "/pages/UserInformation/UserInformation"
});
} else {
common_vendor.index.setStorageSync("userinfo", this.info.data.info);
common_vendor.index.hideLoading();
components_TUILogin.TUIlogin(this.info.data.chatInfo.appId, this.info.data.info.userChatId, userSig);
components_TUILogin.TUIlogin(this.info.data.chatInfo.appId, this.info.data.info.id, this.userSig.userSig);
common_vendor.index.reLaunch({
url: this.$global.lastPage || "/pages/Home/Home"
// 默认页