diff --git a/frontend/portal/src/views/creator/SettingsView.vue b/frontend/portal/src/views/creator/SettingsView.vue index 3fd0759..44f3fac 100644 --- a/frontend/portal/src/views/creator/SettingsView.vue +++ b/frontend/portal/src/views/creator/SettingsView.vue @@ -92,12 +92,14 @@

收款账户

+ 仅支持一个收款账户,删除后可更换
-
+
-
@@ -153,14 +155,14 @@
-
-
@@ -218,7 +220,7 @@ const fetchData = async () => { // Set defaults if empty if (!form.avatar) form.avatar = 'https://api.dicebear.com/7.x/avataaars/svg?seed=Master1'; } - if (accounts) payoutAccounts.value = accounts; + payoutAccounts.value = accounts || []; } catch (e) { console.error(e); } @@ -263,6 +265,13 @@ const handleFileChange = async (event) => { }; const handleAddAccount = async () => { + if (payoutAccounts.value.length >= 1) { + toast.add({ severity: 'error', summary: '限制', detail: '仅支持一个收款账户', life: 3000 }); + return; + } + if (newAccount.type === 'alipay') { + newAccount.name = '支付宝'; + } if (!newAccount.name || !newAccount.account || !newAccount.realname) { toast.add({ severity: 'warn', summary: '提示', detail: '请填写完整信息', life: 3000 }); return;