From 98838f79edd2fdb6c4ed2f6e6faed6cf89e417e5 Mon Sep 17 00:00:00 2001 From: weicw <594098497@qq.com> Date: Sat, 31 Oct 2026 20:24:05 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E5=B0=8F=E7=A8=8B=E5=BA=8F=E7=99=BB?= =?UTF-8?q?=E5=BD=95=E6=94=AF=E6=8C=81=E5=88=87=E6=8D=A2=E5=88=B0=E6=89=8B?= =?UTF-8?q?=E6=9C=BA=E5=8F=B7=E9=AA=8C=E8=AF=81=E7=A0=81=EF=BC=8C=E8=A1=A5?= =?UTF-8?q?=E9=BD=90=E5=B0=8F=E5=86=99=20phone=20=E7=99=BB=E5=BD=95?= =?UTF-8?q?=E6=80=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - ws-login: 小程序默认微信快捷登录,可切到手机号+验证码,或切回 - loginBySms: 同时存小写 phone,页面登录态统一读它 - .env: 审批服务指向 8.134.55.105 --- .env.development | 3 +- .env.production | 3 +- src/api/passport/login/index.ts | 2 + .../ws-login/components/ws-login/ws-login.vue | 63 ++++++++++++++----- 4 files changed, 55 insertions(+), 16 deletions(-) diff --git a/.env.development b/.env.development index a7a5b3c..fb995ad 100644 --- a/.env.development +++ b/.env.development @@ -2,6 +2,7 @@ VITE_APP_NAME=后台管理系统 VITE_SOCKET_URL=wss://server.gxwebsoft.com VITE_SERVER_URL=https://gxtyzx-server.websoft.top/api VITE_API_URL=https://gxtyzx-modules.websoft.top/api -VITE_THINK_URL=https://gxtyzx-api2.websoft.top/api +# 审批服务:部署在 8.134.55.105(经 nginx 80 端口反代) +VITE_THINK_URL=http://8.134.55.105/api #VITE_THINK_URL=http://127.0.0.1:9099/api diff --git a/.env.production b/.env.production index f89b06b..9f49a50 100644 --- a/.env.production +++ b/.env.production @@ -2,4 +2,5 @@ VITE_APP_NAME=后台管理系统 VITE_SOCKET_URL=wss://server.gxwebsoft.com VITE_SERVER_URL=https://gxtyzx-server.websoft.top/api VITE_API_URL=https://gxtyzx-modules.websoft.top/api -VITE_THINK_URL=https://gxtyzx-api2.websoft.top/api +# 审批服务:本次部署的 gxtyzx-api(经 nginx 80 端口反代) +VITE_THINK_URL=http://8.134.55.105/api diff --git a/src/api/passport/login/index.ts b/src/api/passport/login/index.ts index 398a4a9..c98373a 100644 --- a/src/api/passport/login/index.ts +++ b/src/api/passport/login/index.ts @@ -39,6 +39,8 @@ export async function loginBySms(data: LoginParam): Promise console.log('UserId: ', user.userId); console.log('MerchantId: ', user.merchantId); uni.setStorageSync('TenantId', user.tenantId) + // 页面登录态统一读小写 phone(user.vue 等),不能只存大写 Phone + uni.setStorageSync('phone', user.phone) uni.setStorageSync('Phone', user.phone) uni.setStorageSync('UserId', user.userId) if (user.merchantId) { diff --git a/src/uni_modules/ws-login/components/ws-login/ws-login.vue b/src/uni_modules/ws-login/components/ws-login/ws-login.vue index 8fc905d..b6dbe0b 100644 --- a/src/uni_modules/ws-login/components/ws-login/ws-login.vue +++ b/src/uni_modules/ws-login/components/ws-login/ws-login.vue @@ -15,25 +15,37 @@ -