Bug 30270 - Use numeric inputs instead of dropdowns for hold priority
Summary: Use numeric inputs instead of dropdowns for hold priority
Status: BLOCKED
Alias: None
Product: Koha
Classification: Unclassified
Component: Hold requests (show other bugs)
Version: master
Hardware: All All
: P5 - low normal (vote)
Assignee: Nick Clemens
QA Contact: Testopia
URL:
Keywords:
Depends on: 30269
Blocks:
  Show dependency treegraph
 
Reported: 2022-03-10 15:48 UTC by Nick Clemens
Modified: 2022-05-04 18:22 UTC (History)
3 users (show)

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


Attachments
Bug 30270: Use numeric inputs for holds priority (8.98 KB, patch)
2022-03-10 16:15 UTC, Nick Clemens
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Nick Clemens 2022-03-10 15:48:55 UTC
Currently we load a dropdown menu with the range of priority optins when listing holds on request.pl

For a record with many holds (100+) this dropdown is large, and difficult to use

The page size when loading this many dropdowns is also large

We can reduce the problem by using numeric inputs and allowing the user to type new numbers, rather than selecting
Comment 1 Nick Clemens 2022-03-10 16:15:33 UTC
Created attachment 131574 [details] [review]
Bug 30270: Use numeric inputs for holds priority

This patch removes the code to generate dropdowns for holds priority
and adjusts it to use numeric inputs

This does remove the option to set priority to 'del' and use 'Update holds' button
to delete, however, we have a checkbox and 'Cancel selected' which perform the same function
as well as a cancel button for each individual hold

This patch increases performance of the page by reducing the size of the page

To test:
1 - Place many holds on a record
2 - View the holds page and verify functionlity when using:
    HoldsSplitQueue
    HoldsSplitQueueNumbering
3 - Apply patch
4 - Confirm dropdowns are gone
5 - Confirm priorities correctly numbered virtually or actually according to HoldsSplitQueueNumbering
6 - Confirm with all values of HoldsSplitQueue
7 - Confirm cancellation works using checkboxes or button
8 - Confirm hold priority buttons work as before
Comment 2 Andrew Fuerste-Henry 2022-05-03 15:40:37 UTC
Great start, Nick! Sadly, there was an error when setting HoldsSplitQueue to "pickup library and itemtype."

Template process failed: undef error - The method Koha::Hold->object is not covered by tests!

Trace begun at /kohadevbox/koha/Koha/Object.pm line 875
Koha::Object::AUTOLOAD('Koha::Hold=HASH(0x55f3aa7bafe0)') called at /kohadevbox/koha/koha-tmpl/intranet-tmpl/prog/en/modules/reserve/request.tt line 1052
eval {...} at /kohadevbox/koha/koha-tmpl/intranet-tmpl/prog/en/modules/reserve/request.tt line 1052
eval {...} at /kohadevbox/koha/koha-tmpl/intranet-tmpl/prog/en/modules/reserve/request.tt line 1057
Comment 3 Nick Clemens 2022-05-03 15:46:07 UTC
(In reply to Andrew Fuerste-Henry from comment #2)
> Great start, Nick! Sadly, there was an error when setting HoldsSplitQueue to
> "pickup library and itemtype."
> 
> Template process failed: undef error - The method Koha::Hold->object is not
> covered by tests!
> 
> Trace begun at /kohadevbox/koha/Koha/Object.pm line 875
> Koha::Object::AUTOLOAD('Koha::Hold=HASH(0x55f3aa7bafe0)') called at
> /kohadevbox/koha/koha-tmpl/intranet-tmpl/prog/en/modules/reserve/request.tt
> line 1052
> eval {...} at
> /kohadevbox/koha/koha-tmpl/intranet-tmpl/prog/en/modules/reserve/request.tt
> line 1052
> eval {...} at
> /kohadevbox/koha/koha-tmpl/intranet-tmpl/prog/en/modules/reserve/request.tt
> line 1057

Add a new patch to the dependency