http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14620

Lari Taskula <la...@student.uef.fi> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
  Attachment #41472|0                           |1
        is obsolete|                            |

--- Comment #9 from Lari Taskula <la...@student.uef.fi> ---
Created attachment 41527
  -->
http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=41527&action=edit
Bug 14620 - Whitespace fix for validations

This fix trims emails and phone numbers just before form is sent.

Fixes the invalid syntax used in JQuery's .on() functions' argument.

Removes the trimming for click events as change event should be enough.

Test plan:
1. Apply the patches (and run updatedatabase.pl).
2. Set system preferences ValidateEmailAddress to "Enable" and
ValidatePhoneNumber to "International Phone Numbers".
3. Make sure JavaScript is enabled.
4. Navigate to edit user contact informations in Staff client and OPAC.
5. Clear email and phone fields.
6. Insert whitespaces to email and phone fields and submit the form.
7. Edit patron.
8. Observe that there are no longer whitespaces in email and phone fields.
9. Insert invalid email (e.g. "invalid") and invalid phone number
("+123invalid") and send the form.
10. Confirm that form will not be submitted and errors will be given.
11. Disable JavaScript.
12. Insert invalid email and invalid phone number
13. Try sending the form again.
14. Confirm that form will be submitted but errors will be given on top of the
form.
15. Observe that none of the changes are accepted.
16. Set system preferences ValidateEmailAddress to "Disable" and
ValidatePhoneNumber to "none".
17. Repeat step 3-9 but observe that errors will not be given and changes will
be submitted and saved.

-- 
You are receiving this mail because:
You are watching all bug changes.
_______________________________________________
Koha-bugs mailing list
Koha-bugs@lists.koha-community.org
http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

Reply via email to