fixed info messages

This commit is contained in:
2025-09-23 13:24:17 +02:00
parent 48dc74be0f
commit 2ff7aba2dd
2 changed files with 7 additions and 3 deletions

View File

@@ -190,9 +190,7 @@ class UserController extends mfBaseController
$user->apikey = $user->createApiKey();
$user->save();
$this->layout()->setFlash("API Key erfolgreich generiert.", "success");
$this->redirect("User", "edit", ['id' => $id]);
self::returnJson(['success' => true]);
}
protected function saveAction() {

View File

@@ -275,6 +275,12 @@ Vue.component("UserEdit", {
return;
}
if (this.isNewUser && !this.password.new) {
window.notify('error', 'Bitte Passwort angeben.');
this.isSaving = false;
return;
}
if (this.password.new && this.password.new !== this.password.repeat) {
window.notify('error', 'Die Passwörter stimmen nicht überein!');
this.isSaving = false;