From 4f6334abdbf7f4318054046a7b30f129e7b28e9c Mon Sep 17 00:00:00 2001 From: Yukino Song Date: Tue, 15 Jul 2025 20:54:07 +0800 Subject: [PATCH] Fix welcome.html --- src_assets/common/assets/web/welcome.html | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/src_assets/common/assets/web/welcome.html b/src_assets/common/assets/web/welcome.html index bdacf941..08103e34 100644 --- a/src_assets/common/assets/web/welcome.html +++ b/src_assets/common/assets/web/welcome.html @@ -11,7 +11,7 @@

- + {{ $t('welcome.greeting') }}

@@ -66,7 +66,7 @@ success: false, loading: false, passwordData: { - newUsername: "sunshine", + newUsername: "apollo", newPassword: "", confirmNewPassword: "", }, @@ -74,13 +74,17 @@ }, methods: { save() { + if (this.passwordData.newPassword !== this.passwordData.confirmNewPassword) { + this.error = "Password mismatch"; + return; + }; this.error = null; this.loading = true; fetch("./api/password", { - method: "POST", headers: { 'Content-Type': 'application/json' }, + method: 'POST', body: JSON.stringify(this.passwordData), }).then((r) => { this.loading = false;