When creating a patron category or editing an existing one, there is no validation for the "Password expiration" field. If letters or other characters are entered, there is no error message and if not a number whatever is entered is not saved. To replicate: 1. Go to Administration > Patrons and circulation > Patron categories. 2. Add a new patron category (or edit an existing category). 3. For the "Password expiration" field, enter letters or characters such as L$%. 4. For the "Age required" field, enter letters or characters. 5. Note that for the "Age required" field you are prompted to "Please enter only digits", but for "Password expiration" there is no validation error message. 6. If you save with letters or other characters in the "Password expiration" field, it is shown as a "-" on the patron categories list and is blank when you edit the category.
Created attachment 135539 [details] [review] Bug 30864: Add validation to password_expiry_days When creating a patron category or editing an existing one, there is no validation for the "Password expiration" field. If letters or other characters are entered, there is no error message and if not a number whatever is entered is not saved. To test: 1. Go to Administration > Patrons and circulation > Patron categories. 2. Add a new patron category (or edit an existing category). 3. For the "Password expiration" field, enter letters or characters such as L$%. => Note that you are prompted to "Please enter only digits"
Created attachment 135555 [details] [review] Bug 30864: Add validation to password_expiry_days When creating a patron category or editing an existing one, there is no validation for the "Password expiration" field. If letters or other characters are entered, there is no error message and if not a number whatever is entered is not saved. To test: 1. Go to Administration > Patrons and circulation > Patron categories. 2. Add a new patron category (or edit an existing category). 3. For the "Password expiration" field, enter letters or characters such as L$%. => Note that you are prompted to "Please enter only digits" Signed-off-by: David Nind <david@davidnind.com>
Created attachment 135676 [details] [review] Bug 30864: Add validation to password_expiry_days When creating a patron category or editing an existing one, there is no validation for the "Password expiration" field. If letters or other characters are entered, there is no error message and if not a number whatever is entered is not saved. To test: 1. Go to Administration > Patrons and circulation > Patron categories. 2. Add a new patron category (or edit an existing category). 3. For the "Password expiration" field, enter letters or characters such as L$%. => Note that you are prompted to "Please enter only digits" Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Pushed to master for 22.11. Nice work everyone, thanks!
Backported to 22.05.x for 22.05.03