From ea8c45e5cf5a693b0a90bd7bac0158ff25c3b443 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9E=AB=E8=B0=B7=E5=89=91=E4=BB=99?= Date: Fri, 1 Jul 2022 15:01:55 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E6=89=93=E5=BC=80=E7=AE=B1?= =?UTF-8?q?=E5=AD=90=E7=BB=91=E5=AE=9A=E6=95=B0=E6=8D=AE=E5=8F=8D=E8=80=8C?= =?UTF-8?q?=E8=A7=A3=E7=BB=91=E7=9A=84bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- script.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/script.js b/script.js index 710470a0..81da7761 100644 --- a/script.js +++ b/script.js @@ -1960,7 +1960,7 @@ function initialize(event) { const cfgName = cfgPrefix + "default-player-name"; const dataPlayerName = table.getAttribute("data-player-name"); const checkInput = table.parentNode.querySelector("[name=default-player-data]"); - if (localStorage.getItem(cfgName) === dataPlayerName) { + if (localStorage.getItem(cfgName) === dataPlayerName || e === true) { currentPlayerData = null; localStorage.removeItem(cfgName); checkInput.checked = false; @@ -1975,7 +1975,7 @@ function initialize(event) { const table = this.parentNode.parentNode.parentNode.parentNode; table.querySelector(".set-default").onclick(); //打开箱子前先绑定这个数据 showSearch(table.data.parsedCards.map(m=>m.toOldMember())); - playerDataFrame.btnClose.onclick(); + playerDataFrame.btnClose.onclick(true); } playerDataFrame.playerList.add = function(data) { this.appendChild(this.newPlayerData(data));