@@ -, +, @@ - Log in to Koha as a user who has permission to modify holds priority - Test on a record that has multiple holds, including one which is waiting and one which is in transit. - Holds which can be re-ordered should have a "drag handle" styled table cell in the first column. - Your mouse should show the "move" cursor when you hover over it. - Clicking and dragging from this table cell should reorder the table rows. - The priority numbers should be automatically updated when you "drop" the row. - It should not be possible to move a hold which is waiting or in transit. - It should not be possible to move a hold before a waiting or in transit hold. - Toggle lowest priority on a hold. The row should become unsortable, and it should be impossible to sort a hold below that hold. - Test again as a user who doesn't have permission to modify holds priority. --- .../intranet-tmpl/prog/css/src/staff-global.scss | 36 +++++++++++++++++++++- .../intranet-tmpl/prog/en/includes/holds_table.inc | 29 ++++++++++++++--- .../prog/en/modules/reserve/request.tt | 13 ++++++++ 3 files changed, 72 insertions(+), 6 deletions(-) --- a/koha-tmpl/intranet-tmpl/prog/css/src/staff-global.scss +++ a/koha-tmpl/intranet-tmpl/prog/css/src/staff-global.scss @@ -4078,10 +4078,44 @@ div#makechart ol li { list-style: none; } -@media (min-width: 200px) { +/* Sortable table styling */ +.handle { + background: #FCFCFC url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAA4AAAAMAQMAAABoTh6ZAAAABlBMVEVMaXHExMQ/ZYtiAAAAAXRSTlMAQObYZgAAABNJREFUeNpjYGBgMDYAIQjAxgYAKfECU0ml038AAAAASUVORK5CYII=") repeat-y; + cursor: move; + padding: 0 1em; } +tr { + &.ui-sortable-helper { + td { + border-bottom: 2px solid #85CA11; + border-top: 2px solid #85CA11; + + &:first-child { + border-left: 2px solid #85CA11; + } + + &:last-child { + border-right: 2px solid #85CA11; + } + } + } +} + +.table-sort-placeholder { + height: 2.5em; + width: 100%; + + td { + background-color: #FFC; + border-color: #85CA11; + min-width: 3em; + } +} + +/* End sortable table styling */ + @media (max-width: 767px) { .header-menu-link { display: inline-block; --- a/koha-tmpl/intranet-tmpl/prog/en/includes/holds_table.inc +++ a/koha-tmpl/intranet-tmpl/prog/en/includes/holds_table.inc @@ -1,7 +1,9 @@ [% USE Koha %] -
Priority | [% ELSE %] @@ -19,22 +21,38 @@ | [% IF SuspendHoldsIntranet %] | [% END %] | |
---|---|---|---|---|
+ [% ELSE %] + [% IF ( hold.lowestPriority ) %] + | ||||
+ [% ELSE %] + | ||||
+ [% END %] + [% END %] + [% ELSE %] + | ||||
[% IF Koha.Preference('HoldsSplitQueue') == "nothing" && !hold.found %] - |