some more ui work
This commit is contained in:
BIN
src/applets/users/locales/af/LC_MESSAGES/users.mo
Normal file
BIN
src/applets/users/locales/af/LC_MESSAGES/users.mo
Normal file
Binary file not shown.
65
src/applets/users/locales/af/LC_MESSAGES/users.po
Normal file
65
src/applets/users/locales/af/LC_MESSAGES/users.po
Normal file
@@ -0,0 +1,65 @@
|
||||
# SOME DESCRIPTIVE TITLE.
|
||||
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
|
||||
# This file is distributed under the same license as the PACKAGE package.
|
||||
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
|
||||
#
|
||||
#, fuzzy
|
||||
msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: PACKAGE VERSION\n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2025-06-20 15:48+0200\n"
|
||||
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
||||
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
||||
"Language-Team: LANGUAGE <LL@li.org>\n"
|
||||
"Language: \n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=CHARSET\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
|
||||
#: routes.py:33
|
||||
msgid "Let's set up an initial user."
|
||||
msgstr "Kom on stel 'n gebruiker op."
|
||||
|
||||
msgid "Users"
|
||||
msgstr "Gebruikers"
|
||||
|
||||
#: routes.py:34
|
||||
msgid "Full Name"
|
||||
msgstr "Volle Naam"
|
||||
|
||||
#: routes.py:35
|
||||
msgid "Username"
|
||||
msgstr "Gebruikersnaam"
|
||||
|
||||
#: routes.py:36
|
||||
msgid "This username is available"
|
||||
msgstr "Hierdie gebruikersnaam is nie beskikbaar nie."
|
||||
|
||||
#: routes.py:37
|
||||
msgid "This username is not available"
|
||||
msgstr "Hierdie gebruikersnaam is nie beskikbaar nie."
|
||||
|
||||
#: routes.py:38
|
||||
msgid "This username is reserved by the system"
|
||||
msgstr "Hierdie gebruikersnaam is reserveerd deur vir die sisteem."
|
||||
|
||||
#: routes.py:39
|
||||
msgid "The username must be one word, lowercase, with no special characters"
|
||||
msgstr "Die gebruikersnaam moet een woord wees, kleinletters, met geen spesiale karakters."
|
||||
|
||||
#: routes.py:40
|
||||
msgid "Password"
|
||||
msgstr "Wagwoord"
|
||||
|
||||
#: routes.py:41
|
||||
msgid "Password (confirm)"
|
||||
msgstr "Wagwoord (bevestig)"
|
||||
|
||||
#: routes.py:42
|
||||
msgid "These passwords do now match"
|
||||
msgstr "Hierdie wagwoorde is nie dieselfde nie"
|
||||
|
||||
#: routes.py:43
|
||||
msgid "This password is too short"
|
||||
msgstr "Hierdie wagwoord is te kort"
|
||||
62
src/applets/users/locales/users.pot
Normal file
62
src/applets/users/locales/users.pot
Normal file
@@ -0,0 +1,62 @@
|
||||
# SOME DESCRIPTIVE TITLE.
|
||||
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
|
||||
# This file is distributed under the same license as the PACKAGE package.
|
||||
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
|
||||
#
|
||||
#, fuzzy
|
||||
msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: PACKAGE VERSION\n"
|
||||
"Report-Msgid-Bugs-To: \n"
|
||||
"POT-Creation-Date: 2025-06-20 15:48+0200\n"
|
||||
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
|
||||
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
|
||||
"Language-Team: LANGUAGE <LL@li.org>\n"
|
||||
"Language: \n"
|
||||
"MIME-Version: 1.0\n"
|
||||
"Content-Type: text/plain; charset=CHARSET\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
|
||||
#: routes.py:33
|
||||
msgid "Let's set up an initial user."
|
||||
msgstr ""
|
||||
|
||||
#: routes.py:34
|
||||
msgid "Full Name"
|
||||
msgstr ""
|
||||
|
||||
#: routes.py:35
|
||||
msgid "Username"
|
||||
msgstr ""
|
||||
|
||||
#: routes.py:36
|
||||
msgid "This username is available"
|
||||
msgstr ""
|
||||
|
||||
#: routes.py:37
|
||||
msgid "This username is not available"
|
||||
msgstr ""
|
||||
|
||||
#: routes.py:38
|
||||
msgid "This username is reserved by the system"
|
||||
msgstr ""
|
||||
|
||||
#: routes.py:39
|
||||
msgid "The username must be one word, lowercase, with no special characters"
|
||||
msgstr ""
|
||||
|
||||
#: routes.py:40
|
||||
msgid "Password"
|
||||
msgstr ""
|
||||
|
||||
#: routes.py:41
|
||||
msgid "Password (confirm)"
|
||||
msgstr ""
|
||||
|
||||
#: routes.py:42
|
||||
msgid "These passwords do now match"
|
||||
msgstr ""
|
||||
|
||||
#: routes.py:43
|
||||
msgid "This password is too short"
|
||||
msgstr ""
|
||||
@@ -25,7 +25,25 @@ def users_root():
|
||||
set_language(current_app.config['CONFIG']['settings']['language'])
|
||||
string_dict = build_stringlist()
|
||||
build_menu()
|
||||
return render_template('users.html', string_dict=string_dict)
|
||||
menu = current_app.config['CONFIG']['settings']['menu_order'].split(" ")
|
||||
next_step_url = menu[menu.index("users")+1]
|
||||
if menu[menu.index("users")] == 1:
|
||||
previous_step_url = False
|
||||
else:
|
||||
previous_step_url = menu[menu.index("users")-1]
|
||||
|
||||
root_button = ' <button class="button is-light"> <img width="16px;" src="/static/icons/emblem-default-symbolic.svg"> Setup root user </button>'
|
||||
ldap_button = ' <button class="button is-light"> <img width="16px;" src="/static/icons/emblem-default-symbolic.svg"> Connect LDAP </button>'
|
||||
ad_button = ' <button class="button is-light"> <img width="16px;" src="/static/icons/emblem-default-symbolic.svg"> Connect AD </button>'
|
||||
csv_button = ' <button class="button is-light"> <img width="16px;" src="/static/icons/emblem-default-symbolic.svg"> Import CSV </button>'
|
||||
bottom_menu = root_button + ldap_button + ad_button + csv_button
|
||||
|
||||
return render_template('users.html', string_dict=string_dict,
|
||||
menu=current_app.config['CONFIG']['settings']['menu'],
|
||||
menu_order=current_app.config['CONFIG']['settings']['menu_order'].split(),
|
||||
previous_step=previous_step_url,
|
||||
next_step=next_step_url,
|
||||
bottom_menu=bottom_menu)
|
||||
|
||||
|
||||
def build_stringlist():
|
||||
@@ -47,6 +65,7 @@ def build_stringlist():
|
||||
string_dict['password_tooshort'] = _("This password is too short")
|
||||
return string_dict
|
||||
|
||||
|
||||
def build_menu():
|
||||
"""
|
||||
Define menu items and paths.
|
||||
@@ -54,3 +73,4 @@ def build_menu():
|
||||
current_app.config['CONFIG']['settings']['menu']['users'] = (build_stringlist()['menu_item'], "/users", 20)
|
||||
print(current_app.config['CONFIG']['settings']['menu'])
|
||||
|
||||
build_menu()
|
||||
|
||||
Reference in New Issue
Block a user