Bug 19654

Summary: Move tools templates JavaScript to the footer: Batch MARC tools
Product: Koha Reporter: Owen Leonard <oleonard>
Component: TemplatesAssignee: Owen Leonard <oleonard>
Status: CLOSED FIXED QA Contact: Josef Moravec <josef.moravec>
Severity: enhancement    
Priority: P5 - low CC: claire_gravely, dominic.pichette, jonathan.druart, josef.moravec, nick, simon.pouchol, testopia
Version: master   
Hardware: All   
OS: All   
Change sponsored?: --- Patch complexity: Small patch
Documentation contact: Documentation submission:
Text to go in the release notes:
Version(s) released in:
Bug Depends on: 19647    
Bug Blocks: 17858    
Attachments: Bug 19654: Move tools templates JavaScript to the footer: Batch MARC tools
Bug 19654: Move tools templates JavaScript to the footer: Batch MARC tools
Bug 19654: Move tools templates JavaScript to the footer: Batch MARC tools
Bug 19654: Move tools templates JavaScript to the footer: Batch MARC tools

Description Owen Leonard 2017-11-20 16:02:31 UTC
In order to conform to best practices for performance staff client template javascript should be in the footer instead of the header.

This patch will do so for the batch MARC tools templates.
Comment 1 Owen Leonard 2017-11-20 16:12:35 UTC Comment hidden (obsolete)
Comment 2 Claire Gravely 2017-12-01 13:41:38 UTC
When testing the Batch item modification, after entering barcodes and continuing I get:

ReferenceError: $ is not defined. Batchmod.pl:861:1
Comment 3 Owen Leonard 2017-12-12 15:25:45 UTC
Created attachment 69740 [details] [review]
Bug 19654: Move tools templates JavaScript to the footer: Batch MARC tools

This patch modifies the staff client patron lists templates so that
JavaScript is included in the footer instead of the header.

To test, apply the patch and test the JavaScript-driven features of
each modified template: All button controls, DataTables functionality,
form validation, etc.

Revised: My original patch included changes to batchMod-edit.tt but
didn't take into account the MARC plugins which are loaded in the item
edit form. I have discarded those changes for now.

Tools -> Batch record modification
  - Page highlighting in the sidebar
  - Patron autocomplete in the "Check out" tab
  - Submit records for deletion
    - Page highlighting in the sidebar
    - Checkbox selection links
    - Warning when no records selected
    - Patron autocomplete in the "Check out" tab
Tools -> Batch item modification
  - Page highlighting in the sidebar
  - Patron autocomplete in the "Check out" tab
Tools -> Batch item deletion
  - Page highlighting in the sidebar
  - Patron autocomplete in the "Check out" tab
  - Submit items for deletion
    - Patron autocomplete in the "Check out" tab
    - Checkbox selection links
    - Column-hiding checkboxes
    - Datatables
Tools -> Batch record modification
  - Page highlighting in the sidebar
  - Patron autocomplete in the "Check out" tab
  - Submit records for modification
      - Page highlighting in the sidebar
      - Patron autocomplete in the "Check out" tab
      - Checkbox selection links
      - Datatables
      - MARC preview
      - Warning when no records selected
      - Progress bar after submitting items for modification
Comment 4 Claire Gravely 2017-12-13 10:29:35 UTC
Created attachment 69770 [details] [review]
Bug 19654: Move tools templates JavaScript to the footer: Batch MARC tools

This patch modifies the staff client patron lists templates so that
JavaScript is included in the footer instead of the header.

To test, apply the patch and test the JavaScript-driven features of
each modified template: All button controls, DataTables functionality,
form validation, etc.

Revised: My original patch included changes to batchMod-edit.tt but
didn't take into account the MARC plugins which are loaded in the item
edit form. I have discarded those changes for now.

Tools -> Batch record modification
  - Page highlighting in the sidebar
  - Patron autocomplete in the "Check out" tab
  - Submit records for deletion
    - Page highlighting in the sidebar
    - Checkbox selection links
    - Warning when no records selected
    - Patron autocomplete in the "Check out" tab
Tools -> Batch item modification
  - Page highlighting in the sidebar
  - Patron autocomplete in the "Check out" tab
Tools -> Batch item deletion
  - Page highlighting in the sidebar
  - Patron autocomplete in the "Check out" tab
  - Submit items for deletion
    - Patron autocomplete in the "Check out" tab
    - Checkbox selection links
    - Column-hiding checkboxes
    - Datatables
Tools -> Batch record modification
  - Page highlighting in the sidebar
  - Patron autocomplete in the "Check out" tab
  - Submit records for modification
      - Page highlighting in the sidebar
      - Patron autocomplete in the "Check out" tab
      - Checkbox selection links
      - Datatables
      - MARC preview
      - Warning when no records selected
      - Progress bar after submitting items for modification

Signed-off-by: Claire Gravely <claire.gravely@bsz-bw.de>
Comment 5 Josef Moravec 2017-12-13 11:40:36 UTC
Created attachment 69774 [details] [review]
Bug 19654: Move tools templates JavaScript to the footer: Batch MARC tools

This patch modifies the staff client patron lists templates so that
JavaScript is included in the footer instead of the header.

To test, apply the patch and test the JavaScript-driven features of
each modified template: All button controls, DataTables functionality,
form validation, etc.

Revised: My original patch included changes to batchMod-edit.tt but
didn't take into account the MARC plugins which are loaded in the item
edit form. I have discarded those changes for now.

Tools -> Batch record modification
  - Page highlighting in the sidebar
  - Patron autocomplete in the "Check out" tab
  - Submit records for deletion
    - Page highlighting in the sidebar
    - Checkbox selection links
    - Warning when no records selected
    - Patron autocomplete in the "Check out" tab
Tools -> Batch item modification
  - Page highlighting in the sidebar
  - Patron autocomplete in the "Check out" tab
Tools -> Batch item deletion
  - Page highlighting in the sidebar
  - Patron autocomplete in the "Check out" tab
  - Submit items for deletion
    - Patron autocomplete in the "Check out" tab
    - Checkbox selection links
    - Column-hiding checkboxes
    - Datatables
Tools -> Batch record modification
  - Page highlighting in the sidebar
  - Patron autocomplete in the "Check out" tab
  - Submit records for modification
      - Page highlighting in the sidebar
      - Patron autocomplete in the "Check out" tab
      - Checkbox selection links
      - Datatables
      - MARC preview
      - Warning when no records selected
      - Progress bar after submitting items for modification

Signed-off-by: Claire Gravely <claire.gravely@bsz-bw.de>

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Comment 6 Jonathan Druart 2017-12-18 15:19:10 UTC
Pushed to master for 18.05, thanks to everybody involved!
Comment 7 Nick Clemens 2017-12-20 12:03:26 UTC
Awesome work all! Enhancement, not backporting for 17.11