Bug 16938

Summary: Remove the use of "onclick" from batch patrons modification template
Product: Koha Reporter: Owen Leonard <oleonard>
Component: TemplatesAssignee: Owen Leonard <oleonard>
Status: CLOSED FIXED QA Contact: Testopia <testopia>
Severity: enhancement    
Priority: P5 - low CC: hector.hecaxmmx, katrin.fischer, kyle, testopia
Version: Main   
Hardware: All   
OS: All   
URL: /cgi-bin/koha/tools/modborrowers.pl
Change sponsored?: --- Patch complexity: Small patch
Documentation contact: Documentation submission:
Text to go in the release notes:
Version(s) released in:
Attachments: Bug 16938 - Remove the use of "onclick" from batch patrons modification template
[SIGNED-OFF]Bug 16938: Remove the use of "onclick" from batch patrons modification template
Bug 16938: Remove the use of "onclick" from batch patrons modification template
Bug 16938: Remove the use of "onclick" from batch patrons modification template

Description Owen Leonard 2016-07-18 18:39:53 UTC
There are several instances of "onclick" in modborrowers.tt which can be removed in favor of defining events in the JavaScript.
Comment 1 Owen Leonard 2016-07-18 19:04:52 UTC Comment hidden (obsolete)
Comment 2 Héctor Eduardo Castro Avalos 2016-07-19 15:59:27 UTC Comment hidden (obsolete)
Comment 3 Jonathan Druart 2016-07-25 12:53:11 UTC Comment hidden (obsolete)
Comment 4 Owen Leonard 2016-09-09 14:41:25 UTC
Created attachment 55440 [details] [review]
Bug 16938: Remove the use of "onclick" from batch patrons modification template

This patch revises the batch patrons modification template, removing
"onclick" attributes from the markup and defining those events in the
script.

To test you should have at least one extended patron attribute
configured.

- Apply the patch and go to Tools -> Batch patron modification.
- Submit a batch of patrons for modification.
- Confirm that the checkbox next to any required field is disabled.
- Select a date in the registration date and expiry date fields. Confirm
  that the "Clear" link next to each empties the correct field.
- Click "New" next to a patron attibute. A copy of the patron attribute
  line should be created.
- Click "Delete" next to a cloned patron attribute. The correct line
  should be removed.

Signed-off-by: Hector Castro <hector.hecaxmmx@gmail.com>
Works as advertised

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Comment 5 Kyle M Hall 2016-09-09 14:53:53 UTC
Pushed to master for 16.11, thanks Owen!