From dcdf3ccc9fe72a3a6494a113e1234c891ce7921a Mon Sep 17 00:00:00 2001 From: CaIon <1808837298@qq.com> Date: Mon, 6 Nov 2023 22:09:48 +0800 Subject: [PATCH] fix bug --- controller/misc.go | 3 --- web/src/components/SystemSetting.js | 8 ++++++-- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/controller/misc.go b/controller/misc.go index 316e01c6..50c29f2c 100644 --- a/controller/misc.go +++ b/controller/misc.go @@ -27,9 +27,6 @@ func GetStatus(c *gin.Context) { "wechat_qrcode": common.WeChatAccountQRCodeImageURL, "wechat_login": common.WeChatAuthEnabled, "server_address": common.ServerAddress, - "pay_address": common.PayAddress, - "epay_id": common.EpayId, - "epay_key": common.EpayKey, "price": common.Price, "min_charge": common.MinCharge, "turnstile_check": common.TurnstileCheckEnabled, diff --git a/web/src/components/SystemSetting.js b/web/src/components/SystemSetting.js index 572f1d04..c029db73 100644 --- a/web/src/components/SystemSetting.js +++ b/web/src/components/SystemSetting.js @@ -157,8 +157,12 @@ const SystemSetting = () => { } let PayAddress = removeTrailingSlash(inputs.PayAddress); await updateOption('PayAddress', PayAddress); - await updateOption('EpayId', inputs.EpayId); - await updateOption('EpayKey', inputs.EpayKey); + if (inputs.EpayId !== '') { + await updateOption('EpayId', inputs.EpayId); + } + if (inputs.EpayKey !== '') { + await updateOption('EpayKey', inputs.EpayKey); + } await updateOption('Price', "" + inputs.Price); await updateOption('MinCharge', "" + inputs.MinCharge); };