Bugzilla – Attachment 135553 Details for
Bug 30878
Canceling holds from 'Holds awaiting pickup' should not reset the selected tab
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 30878: Avoid resetting waiting reserves tab
Bug-30878-Avoid-resetting-waiting-reserves-tab.patch (text/plain), 1.86 KB, created by
Lari Taskula
on 2022-06-01 15:17:24 UTC
(
hide
)
Description:
Bug 30878: Avoid resetting waiting reserves tab
Filename:
MIME Type:
Creator:
Lari Taskula
Created:
2022-06-01 15:17:24 UTC
Size:
1.86 KB
patch
obsolete
>From 2d66798b4aa2781304d612a1a6367c9b399f6a4d Mon Sep 17 00:00:00 2001 >From: Lari Taskula <lari.taskula@hypernova.fi> >Date: Wed, 1 Jun 2022 15:06:52 +0000 >Subject: [PATCH] Bug 30878: Avoid resetting waiting reserves tab > >When canceling holds waiting over X days in "Holds awaiting pickup" >view, form submission resets the selected tab to "Holds waiting". This >tab reset may cause confusion for the user and lead to unwanted >actions. Instead, the user should be returned to the same tab that they >began with. > >To test: >1. Apply patch >2. Navigate to /cgi-bin/koha/circ/waitingreserves.pl >3. Select "Holds waiting over X days" tab >4. Refresh page >5. Observe "Holds waiting over X days" is still selected >6. Have some holds waiting over X days >7. Select one of them and press "Cancel selected (1)" and confirm >8. Observe "Holds waiting over X days" is still selected after form > submission >--- > .../prog/en/modules/circ/waitingreserves.tt | 9 +++++++++ > 1 file changed, 9 insertions(+) > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/waitingreserves.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/circ/waitingreserves.tt >index b6e06f7bc9..c2fefee4ee 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/waitingreserves.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/circ/waitingreserves.tt >@@ -261,6 +261,15 @@ > }); > }); > >+ var activeTab = localStorage.getItem("waitingreserves_activetab"); >+ if( activeTab ){ >+ $("div#resultlist li:eq(" + activeTab + ") a").tab("show"); >+ } >+ $("div#resultlist a[data-toggle='tab']").on("shown.bs.tab", function (e) { >+ var thisTab = $(e.target).parent(); >+ var activeTab = thisTab.index(); >+ localStorage.setItem("waitingreserves_activetab", activeTab ); >+ }); > > }); > </script> >-- >2.25.1
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 30878
:
135553
|
136333
|
138054