added documentation links to sidebar

Signed-off-by: Michael Kaufmann <d00p@froxlor.org>
This commit is contained in:
Michael Kaufmann
2022-11-14 12:59:51 +01:00
parent 5fa98811ab
commit da6c1992fa
5 changed files with 57 additions and 4 deletions

View File

@@ -88,7 +88,8 @@ class HTML
'active' => $active,
'label' => $navlabel,
'icon' => $icon,
'add_shortlink' => $element['add_shortlink'] ?? null
'add_shortlink' => $element['add_shortlink'] ?? null,
'is_external' => $element['is_external'] ?? false,
];
}
}

View File

@@ -45,7 +45,8 @@ return [
'new_window' => true,
'label' => lng('menue.email.webmail'),
'required_resources' => 'emails_used',
'show_element' => (Settings::Get('panel.webmail_url') != '')
'show_element' => (Settings::Get('panel.webmail_url') != ''),
'is_external' => true,
]
]
],
@@ -66,7 +67,8 @@ return [
'new_window' => true,
'label' => lng('menue.mysql.phpmyadmin'),
'required_resources' => 'mysqls_used',
'show_element' => (Settings::Get('panel.phpmyadmin_url') != '')
'show_element' => (Settings::Get('panel.phpmyadmin_url') != ''),
'is_external' => true,
]
]
],
@@ -102,7 +104,8 @@ return [
'url' => Settings::Get('panel.webftp_url'),
'new_window' => true,
'label' => lng('menue.ftp.webftp'),
'show_element' => (Settings::Get('panel.webftp_url') != '')
'show_element' => (Settings::Get('panel.webftp_url') != ''),
'is_external' => true,
]
]
],
@@ -151,6 +154,25 @@ return [
'label' => lng('menue.traffic.overview')
]
]
],
'docs' => [
'label' => lng('admin.documentation'),
'icon' => 'fa-solid fa-circle-info',
'elements' => [
[
'url' => 'https://docs2.froxlor.org/v2/user-guide/',
'label' => lng('admin.userguide'),
'new_window' => true,
'is_external' => true,
],
[
'url' => 'https://docs2.froxlor.org/v2/api-guide/',
'label' => lng('admin.apiguide'),
'new_window' => true,
'show_element' => Settings::Get('api.enabled') == 1 && CurrentUser::getField('api_allowed') == 1,
'is_external' => true,
]
]
]
],
'admin' => [
@@ -321,6 +343,25 @@ return [
'label' => lng('admin.testmail')
]
]
],
'docs' => [
'label' => lng('admin.documentation'),
'icon' => 'fa-solid fa-circle-info',
'elements' => [
[
'url' => 'https://docs2.froxlor.org/v2/admin-guide/',
'label' => lng('admin.adminguide'),
'new_window' => true,
'is_external' => true,
],
[
'url' => 'https://docs2.froxlor.org/v2/api-guide/',
'label' => lng('admin.apiguide'),
'new_window' => true,
'show_element' => Settings::Get('api.enabled') == 1,
'is_external' => true,
]
]
]
]
];

View File

@@ -482,6 +482,10 @@ return [
'verify_ca' => 'Aktiviere SSL Zertifikats-Verifikation',
],
'settings_importfile' => 'Wähle Import-Datei',
'documentation' => 'Dokumentation',
'adminguide' => 'Admin Guide',
'userguide' => 'User Guide',
'apiguide' => 'API Guide',
],
'apikeys' => [
'no_api_keys' => 'Keine API Keys gefunden',

View File

@@ -493,6 +493,10 @@ return [
'verify_ca' => 'Enable verification of the server SSL certificate',
],
'settings_importfile' => 'Chose import file',
'documentation' => 'Documentation',
'adminguide' => 'Admin guide',
'userguide' => 'User guide',
'apiguide' => 'API guide',
],
'apcuinfo' => [
'clearcache' => 'Clear APCu cache',

View File

@@ -19,6 +19,9 @@
{% if item.add_shortlink is defined and item.add_shortlink is not empty %}
<a href="{{ item.add_shortlink|raw }}" class="text-secondary me-2"><i class="fa-solid fa-plus-circle"></i></a>
{% endif %}
{% if item.is_external is defined and item.is_external %}
<span><i class="fa-solid fa-arrow-up-right-from-square"></i></span>
{% endif %}
</li>
{% endfor %}
</ul>