修改登录页面

This commit is contained in:
xuli3099
2025-08-19 16:47:33 +08:00
parent 96a9932e70
commit d40d8e1e91

View File

@@ -83,14 +83,15 @@ import { AGREEWELCOME_KEY } from '@/enums/cacheEnums';
import { getNavBarPaddingTop} from '@/utils/system.js'
import { useUserStore } from '@/stores/user';
import encryptObj from '@/utils/encrypt.js'
import { CLIENT_ID } from '@/enums/cacheEnums';
import {showAlert} from '@/utils/message.js'
// #ifdef APP-PLUS
// 获取 存储手机的module
const safeSave = uni.requireNativePlugin("Tm-TmSafeSaveFileModule");
// #endif
const userStore = useUserStore()
const userStore = useUserStore();
let clientId = `${proxy.$CLIENT_ID || 2}`;
let networkEnv = ref(proxy.$NETWORK_ENV);//1-内网 2-外网
onLoad(async(opt) => {
uni.setStorageSync('page_cache',true);
})
@@ -248,13 +249,13 @@ const submitForm = () => {
// 用户名和密码登录
form2.value.validate().then(async param => {
param.loginType = activeTab.value;
let clientId = `${CLIENT_ID || "2"}`;
param.clientId = clientId;
let password = encryptObj.Encrypt(param.username + clientId + "," + param.password);
param.password = password;
param.runEnv = networkEnv;
// #ifdef H5
param.uniqCode = '7f47cfb4-59e2-4cb9-ac46-9da5e23c4de2';//uni.getStorageSync('app_device_id');//先从缓存取之后处理 '7f47cfb4-59e2-4cb9-ac46-9da5e23c4de2'//
param.uniqCode = '7f47cfb4-59e2-4cb9-ac46-9da5e23c4de2';//uni.getStorageSync('app_device_id');//先从缓存取之后处理
let res = await login(param);
userStore.login(res);
uni.switchTab({ url: '/pages/home/home' })