From d8310ed6e7acfdfa6bb63a5b271879b8b8870b3b Mon Sep 17 00:00:00 2001 From: Xu Date: Mon, 20 Nov 2023 17:13:45 +0100 Subject: [PATCH] minor improvements on angeltypes --- includes/view/AngelTypes_view.php | 5 +++-- resources/lang/de_DE/default.po | 3 +++ 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/includes/view/AngelTypes_view.php b/includes/view/AngelTypes_view.php index ecbc07b4..00aa9bd3 100644 --- a/includes/view/AngelTypes_view.php +++ b/includes/view/AngelTypes_view.php @@ -87,11 +87,12 @@ function AngelType_edit_view(AngelType $angeltype, bool $supporter_mode) ? url('/angeltypes', ['action' => 'view', 'angeltype_id' => $angeltype->id]) : url('/angeltypes'), icon('chevron-left'), 'btn-sm'); return page_with_title( - $link . ' ' . sprintf(__('Edit %s'), $angeltype->name), + $link . ' ' . ($angeltype->id ? sprintf(__('Edit %s'), $angeltype->name) : __('Create angeltype')), [ + $angeltype->id ? buttons([ button(url('/angeltypes'), icon('person-lines-fill') . __('angeltypes.angeltypes'), 'back'), - ]), + ]) : '', msg(), form([ $supporter_mode diff --git a/resources/lang/de_DE/default.po b/resources/lang/de_DE/default.po index 8b069711..fef2d6b5 100644 --- a/resources/lang/de_DE/default.po +++ b/resources/lang/de_DE/default.po @@ -176,6 +176,9 @@ msgstr "Lösche Engeltyp %s" msgid "Please check the name. Maybe it already exists." msgstr "Bitte überprüfe den Namen. Vielleicht ist er bereits vergeben." +msgid "Create angeltype" +msgstr "Engeltyp erstellen" + msgid "Edit %s" msgstr "%s bearbeiten"