Koha/koha-tmpl/intranet-tmpl/prog/en/includes/onboarding_messages.inc
Alex Buckley 48bf229cc8 Bug 19514: Implement password restrictions into onboarding tool
Test plan:
1. Drop and recreate your database
2. Restart memcached
3. Go through the web installer
4. In the onboarding tool create a patron with a password of only 2 characters in length
5. Notice the patron is successfully created and no warning message is
displayed
6. Repeat step 1,2,3 and create a patron with a password of 3 characters
none of which are a uppercase letter or number and notice the patron is
successfully created and no warning message is displayed
7. Apply patch
8. Repeat steps 1,2,3 and create a patron with a password consisting of
2 characters, notice that after submitting the form the same form is
loaded again and there is a warning message at the top of the page
informing you the patron wasn't created
9. Repeat steps 1,2,3 and create a patron with a password consisting of
3 characters (all lower case) and submit the form, notice the same form
is reloaded and a warning message at the top of the page informs you
that the patron wasn't created because the password was weak
10. Repeat steps 1,2,3 and create a patron with a password consisting of
3 characters (one lower case letter, one upper case letter and one
number) and submit the form and notice this time the next form in the onboarding is displayed with the message at the top of the screen informing you that the patron was successfully created

Sponsored-By: Catalyst IT

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>

Signed-off-by: David Bourgault <david.bourgault@inlibro.com>

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
2017-12-14 16:57:56 -03:00

37 lines
2.3 KiB
HTML

[% FOR m IN messages %]
[% SWITCH m.code %]
[% CASE 'success_on_insert_library' %]
<div class="alert alert-success">Library created!</div>
[% CASE 'error_on_insert_library' %]
<div class="alert alert-danger">Library already exists and cannot be modified!</div>
[% CASE 'success_on_insert_category' %]
<div class="alert alert-success">Patron category created!</div>
[% CASE 'error_on_insert_category' %]
<div class="alert alert-danger">Patron category already exists and cannot be modified!</div>
[% CASE 'success_on_insert_patron' %]
<div class="alert alert-success">Administrator account created!</div>
[% CASE 'error_on_insert_patron' %]
<div class="alert alert-danger">The patron has not been created! Cardnumber or Userid may already exist.</div>
[% CASE 'ERROR_cardnumber_already_exists' %]
<div class="alert alert-danger">Card number already in use.</div>
[% CASE 'ERROR_cardnumber_length' %]
<div class="alert alert-danger">Card number length is incorrect.</div>
[% CASE 'ERROR_password_mismatch' %]
<div class="alert alert-danger">Passwords do not match.</div>
[% CASE 'success_on_insert_itemtype' %]
<div class="alert alert-success">New item type created!</div>
[% CASE 'error_on_insert_itemtype' %]
<div class="alert alert-danger">Item type already exists!</div>
[% CASE 'success_on_insert_circ_rule' %]
<div class="alert alert-success">Circulation rule created!</div>
[% CASE 'error_on_insert_circ_rule' %]
<div class="alert alert-danger">Circulation rule not created!</div>
[% CASE 'ERROR_password_too_short' %]
<div class="alert alert-danger">The patron has not been created the entered password was too short</div>
[% CASE 'ERROR_password_too_weak' %]
<div class="alert alert-danger">The patron has not been created the entered password was too weak, must contain at least one uppercase, and lower case letter and one number</div>
[% CASE 'ERROR_password_has_whitespaces' %]
<div class="alert alert-danger">The patron has not been created the entered password contained whitespaces</div>
[% CASE %][% message %]
[% END %]
[% END %]