Bug 22209 - Move stock rotation stage and item forms into modals
Summary: Move stock rotation stage and item forms into modals
Status: CLOSED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: Templates (show other bugs)
Version: master
Hardware: All All
: P5 - low enhancement (vote)
Assignee: Owen Leonard
QA Contact: Testopia
URL:
Keywords:
Depends on: 11897
Blocks:
  Show dependency treegraph
 
Reported: 2019-01-25 16:16 UTC by Owen Leonard
Modified: 2020-06-04 20:32 UTC (History)
3 users (show)

See Also:
Change sponsored?: ---
Patch complexity: Small patch
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:
19.11.00


Attachments
Bug 22209: Move stock rotation stage and item forms into modals (19.86 KB, patch)
2019-07-08 18:46 UTC, Owen Leonard
Details | Diff | Splinter Review
Bug 22209: Move stock rotation stage and item forms into modals (19.90 KB, patch)
2019-07-12 20:53 UTC, Maryse Simard
Details | Diff | Splinter Review
Bug 22209: Move stock rotation stage and item forms into modals (19.97 KB, patch)
2019-08-08 14:40 UTC, Katrin Fischer
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Owen Leonard 2019-01-25 16:16:21 UTC
I propose to put "Add stage" and "Add items" buttons in the stock rotation toolbar which trigger modals with the corresponding forms in them.
Comment 1 Owen Leonard 2019-07-08 18:46:13 UTC Comment hidden (obsolete)
Comment 2 Maryse Simard 2019-07-12 20:53:03 UTC Comment hidden (obsolete)
Comment 3 Katrin Fischer 2019-08-08 14:40:47 UTC
Created attachment 92079 [details] [review]
Bug 22209: Move stock rotation stage and item forms into modals

This patch makes a number of interface changes to the Stock Rotation
management interface:

 - "Add stage" and "Add items" forms are now triggered by clicking new
   buttons in the toolbar.
 - "Manage stages" and "Manage items" menu items have been added to a
   sidebar menu to be displayed when stages or items are being managed.
 - JavaScript has been added to move focus to the first form field in
   the modal when it is displayed. The "autofocus" attribute is not
   sufficent here because the modal is hidden by default.
 - Add messages to be shown when there are no items or stages to be
   displayed.
 - Correct "selected" attributes to use XHTML-style: selected="selected"
  (https://wiki.koha-community.org/wiki/Coding_Guidelines#HTML_Templates)

To test, apply the patch and go to Tools -> Stock rotation.

 - Create a rota if you don't already have one.
   - Manage stages for your rota.
     - If your rota has no stages you should see a message along with an
       "Add stage" button. The button should trigger the "Add stage"
       modal.
     - Test the "Add stage" button in the toolbar. It should trigger a
       modal dialog containing the form for adding a new stage. The
       cursor focus should automatically be on the "library" field.
     - Submitting the form should correctly add the stage.
     - Verify that there is a new menu in the sidebar, "Manage stages"
       and "Manage items."
   - Manage items for your rota.
     - If your rota has no items you should see a message along with an
       "Add items" button. The button should trigger the "Add items"
       modal.
     - Test the "Add items" button in the toolbar. It should trigger a
       modal dialog containing the form for adding new items. The cursor
       focus should automatically be on the "barcode" field.
     - Submitting either a barcode or a file of barcodes should work
       correctly.
     - Verify that the new menu items are shown in the sidebar.

Signed-off-by: Maryse Simard <maryse.simard@inlibro.com>

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Comment 4 Martin Renvoize 2019-08-08 15:09:15 UTC
Nice work!

Pushed to master for 19.11.00
Comment 5 Fridolin Somers 2019-08-09 14:11:32 UTC
Enhancement not pushed to 19.05.x