more sub-navigation links; rename 'cancel' to 'discard changes' as it is a form-reset button

Signed-off-by: Michael Kaufmann <d00p@froxlor.org>
This commit is contained in:
Michael Kaufmann
2022-10-18 20:39:01 +02:00
parent 3e1ad050a8
commit e7ccc7bf76
7 changed files with 10 additions and 8 deletions

View File

@@ -403,6 +403,7 @@ if ($action == '') {
'formdata' => [
'title' => lng('admin.templates.template_add'),
'image' => 'fa-solid fa-plus',
'self_overview' => ['section' => 'templates', 'page' => 'email'],
'sections' => [
'section_a' => [
'title' => lng('admin.templates.template_add'),

View File

@@ -27,6 +27,7 @@ return [
'filetemplate_add' => [
'title' => lng('admin.templates.template_add'),
'image' => 'fa-solid fa-plus',
'self_overview' => ['section' => 'templates', 'page' => 'email'],
'sections' => [
'section_a' => [
'title' => lng('admin.templates.template_add'),

View File

@@ -27,6 +27,7 @@ return [
'filetemplate_edit' => [
'title' => lng('admin.templates.template_edit'),
'image' => 'fa-solid fa-pen',
'self_overview' => ['section' => 'templates', 'page' => 'email'],
'sections' => [
'section_a' => [
'title' => lng('admin.templates.template_edit'),

View File

@@ -27,6 +27,7 @@ return [
'template_add' => [
'title' => lng('admin.templates.template_add'),
'image' => 'fa-solid fa-plus',
'self_overview' => ['section' => 'templates', 'page' => 'email', 'action' => 'add'],
'sections' => [
'section_a' => [
'title' => lng('admin.templates.template_add'),

View File

@@ -27,6 +27,7 @@ return [
'template_edit' => [
'title' => lng('admin.templates.template_edit'),
'image' => 'fa-solid fa-pen',
'self_overview' => ['section' => 'templates', 'page' => 'email'],
'sections' => [
'section_a' => [
'title' => lng('admin.templates.template_edit'),

View File

@@ -34,7 +34,6 @@ return [
'section_a' => [
'title' => lng('emails.emails_edit'),
'image' => 'icons/email_edit.png',
'nobuttons' => true,
'fields' => [
'email_full' => [
'label' => lng('emails.emailaddress'),
@@ -120,9 +119,7 @@ return [
]
],
'buttons' => [
[
'label' => lng('panel.backtooverview')
]
/* none */
]
]
];

View File

@@ -33,14 +33,14 @@
<input type="hidden" name="action" value="{{ action }}"/>
<input type="hidden" name="send" value="send"/>
<div class="col-12 text-end">
<div class="col-12 text-center p-2">
{% if form_data.buttons is defined and form_data.buttons is iterable %}
{% for btn in form_data.buttons %}
<button type="{{ btn.type|default("submit") }}" class="btn {{ btn.class|default(" btn-primary") }}">{{ btn.label }}</button>
<button type="{{ btn.type|default("submit") }}" class="btn btn-lg {{ btn.class|default(" btn-primary") }}">{{ btn.label }}</button>
{% endfor %}
{% else %}
<button type="reset" class="btn btn-outline-secondary">{{ lng('panel.cancel') }}</button>
<button type="submit" class="btn btn-primary">{{ lng('panel.save') }}</button>
<button type="reset" class="btn btn-lg btn-outline-secondary me-3">{{ lng('panel.reset') }}</button>
<button type="submit" class="btn btn-lg btn-primary">{{ lng('panel.save') }}</button>
{% endif %}
</div>
</div>