From d39d581a802396a6fa6ba74718ae168db65d29a5 Mon Sep 17 00:00:00 2001 From: zhangguoping Date: Mon, 21 Jul 2025 17:27:18 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=96=B0=20front/templates/payPage.ht?= =?UTF-8?q?ml?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- front/templates/payPage.html | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/front/templates/payPage.html b/front/templates/payPage.html index ba4f365..3f30309 100644 --- a/front/templates/payPage.html +++ b/front/templates/payPage.html @@ -345,7 +345,7 @@ // 页面加载时执行 window.onload = function() { - alert(`auto-redirect:${!localStorage.getItem('auto-redirect')}`); + alert(localStorage.getItem('auto-redirect')); if (localStorage.getItem('auto-redirect') == 2) { alert('支付回调且不是自动跳转'); handlePaymentCallback(); // 如果是支付回调且不是自动跳转,处理支付结果 @@ -356,10 +356,6 @@ } }; - window.onunload = function() { - localStorage.removeItem('auto-redirect'); // 离开页面时清除自动跳转标记 - }; - {{ else}}