From 9e338b789fbe4a50a5da9e7e9cb7035e157cd66c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?old=E6=98=93?= <156663459@qq.com> Date: Thu, 10 Oct 2024 17:22:29 +0800 Subject: [PATCH] =?UTF-8?q?=E8=B0=83=E6=95=B4=E6=96=87=E5=AD=97?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/MinProLogin.vue | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/src/components/MinProLogin.vue b/src/components/MinProLogin.vue index 90f7041..376ba43 100644 --- a/src/components/MinProLogin.vue +++ b/src/components/MinProLogin.vue @@ -143,8 +143,10 @@ export default { // 3. Initialize SignalR client const connection = new signalR.HubConnectionBuilder() - .withUrl('https://api.sso.ycymedu.com/hubs/wechat?usercode=' + state.usercode) // Replace with your SignalR hub URL - .configureLogging(signalR.LogLevel.Information) // Optional: Configure logging + .withServerTimeout(30000) + .withAutomaticReconnect() + .withUrl('https://api.sso.ycymedu.com/hubs/wechat?usercode=' + state.usercode) // Replace with your SignalR hub URL + .configureLogging(signalR.LogLevel.Information) // Optional: Configure logging .build(); // 4. Handle connection events @@ -166,12 +168,12 @@ export default { } if (message.status == 1)//开始扫码登录 { - scanError.value = '开始扫码中...' + scanError.value = '已扫码等待授权...' } if (message.status == 2)//授权成功 { scanError.value = '授权成功' console.log('baseurl:', referer.value + message.baseurl); - // window.location.href = referer + message.baseurl; + window.location.href = referer.value + message.baseurl; } });