Prevent admin from creating users with empty username (#37)
* Prevent admin from creating users with empty username A error message shows when the admin tries to submit the form if the validation fails. The error message was translated to Czech, Deutsch, English, Spanish and French, which are the currently compatible languages in the website. * Move username validation logic to server side
This commit is contained in:
parent
001b81d6b5
commit
6900c401de
7 changed files with 24 additions and 0 deletions
|
@ -13,6 +13,7 @@ block content
|
|||
h3= lang('ADMIN_SETTINGS_USERS_ADD_HEADER')
|
||||
form(action=`${_CC.config.base}admin-settings/add`, method='POST')
|
||||
.field
|
||||
p.has-text-danger#error-label= add_user_error
|
||||
label.label= lang('ADMIN_SETTINGS_USERS_ADD_USERNAME')
|
||||
.control.has-icons-left
|
||||
input.input(type='text', name='newUserUsername', placeholder=lang('ADMIN_SETTINGS_USERS_ADD_PLACEHOLDER'))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue