Bug 14180 - Make "Always show checkouts immediately" a global setting
Summary: Make "Always show checkouts immediately" a global setting
Status: Needs documenting
Alias: None
Product: Koha
Classification: Unclassified
Component: Circulation (show other bugs)
Version: Main
Hardware: All All
: P5 - low enhancement
Assignee: Lucas Gass (lukeg)
QA Contact: Tomás Cohen Arazi (tcohen)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-05-11 12:32 UTC by Katrin Fischer
Modified: 2024-11-18 13:50 UTC (History)
23 users (show)

See Also:
Change sponsored?: ---
Patch complexity: Small patch
Documentation contact:
Documentation submission:
Text to go in the release notes:
This enhancement adds the ability for libraries to have checkouts always show immediately. To turn on this new feature, set the new system preference 'AlwaysLoadCheckoutsTable' to 'do. If you find that checkouts are slow do load, you can add a delay to the table so the rest of the page can load and checkouts can proceed using the new system preference 'LoadCheckoutsTableDelay'. **Sponsored by** *ByWater Solutions*
Version(s) released in:
24.11.00
Circulation function:


Attachments
Bug 14180: Perltidy (2.14 KB, patch)
2024-01-26 17:44 UTC, Lucas Gass (lukeg)
Details | Diff | Splinter Review
Bug 14180: Add AlwaysLoadCheckoutsTable system preference (2.37 KB, patch)
2024-01-26 17:45 UTC, Lucas Gass (lukeg)
Details | Diff | Splinter Review
Bug 14180: Add option to always load the issues table (7.96 KB, patch)
2024-01-26 17:45 UTC, Lucas Gass (lukeg)
Details | Diff | Splinter Review
Bug 14180: Perltidy (2.14 KB, patch)
2024-01-26 17:45 UTC, Lucas Gass (lukeg)
Details | Diff | Splinter Review
Bug 14180: Add AlwaysLoadCheckoutsTable system preference (2.42 KB, patch)
2024-01-26 18:23 UTC, ByWater Sandboxes
Details | Diff | Splinter Review
Bug 14180: Add option to always load the issues table (8.01 KB, patch)
2024-01-26 18:23 UTC, ByWater Sandboxes
Details | Diff | Splinter Review
Bug 14180: Perltidy (2.19 KB, patch)
2024-01-26 18:23 UTC, ByWater Sandboxes
Details | Diff | Splinter Review
Bug 14180: Add AlwaysLoadCheckoutsTable system preference (2.46 KB, patch)
2024-08-06 13:13 UTC, Nick Clemens (kidclamp)
Details | Diff | Splinter Review
Bug 14180: Add option to always load the issues table (8.63 KB, patch)
2024-08-06 13:13 UTC, Nick Clemens (kidclamp)
Details | Diff | Splinter Review
Bug 14180: Add AlwaysLoadCheckoutsTable system preference (2.46 KB, patch)
2024-08-06 13:14 UTC, Nick Clemens (kidclamp)
Details | Diff | Splinter Review
Bug 14180: Add option to always load the issues table (9.56 KB, patch)
2024-08-06 13:15 UTC, Nick Clemens (kidclamp)
Details | Diff | Splinter Review
Bug 14180: Add AlwaysLoadCheckoutsTable system preference (2.51 KB, patch)
2024-10-25 14:56 UTC, Tomás Cohen Arazi (tcohen)
Details | Diff | Splinter Review
Bug 14180: Add option to always load the issues table (9.61 KB, patch)
2024-10-25 14:56 UTC, Tomás Cohen Arazi (tcohen)
Details | Diff | Splinter Review
Bug 14180: (QA follow-up) Re-arrange sysprefs to fix QA warnings (3.53 KB, patch)
2024-10-25 14:56 UTC, Tomás Cohen Arazi (tcohen)
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Katrin Fischer 2015-05-11 12:32:06 UTC
Right now the checkbox is unchecked by default and your setting will be kept during the session. 

Several libraries have asked to check the checkbox permanently, as it's annoying to redo the checkbox every morning or even several times during the day. 

One of the librarians reporting this is relying on a screen reader and braille line - which makes the task of rechecking the checkbox in order to be able to read the checkouts even more tedious.
Comment 1 Owen Leonard 2015-05-11 12:56:26 UTC
(In reply to Katrin Fischer from comment #0)

> Several libraries have asked to check the checkbox permanently, as it's
> annoying to redo the checkbox every morning or even several times during the
> day. 

I thought Bug 13196 fixed this?
Comment 2 Katrin Fischer 2015-05-11 13:01:30 UTC
Hi Owen, thx for the comment! I have left a comment on the other bug - it's not in 3.18.x and marking ths see also for now to see if it fixes the problem for the library.
Comment 3 Katrin Fischer 2015-05-13 08:50:31 UTC
I realized that the patch Owen pointed to is already in 3.18, but this is still a problem to the library - maybe because of restrictive cookie settings? In general it would be nice if there was an option to just always load and get rid of the checkbox for some libraires.
Comment 4 Agnes Rivers-Moore 2015-08-19 18:07:39 UTC
I would like a global preference to turn "always show checkouts" on or off.
It is not something we would want to select daily or per session or per staff person.

There is also an extra row below "specify due date" in checkout that reports the barcode that was last checked out.
If "always show" is turned on - this is no longer needed, as the information is displayed twice.

I would wish to have that associated with the "Always show" function so that it only appears if "always show" is turned off.
It uses up screen space we would rather use to see the last several items we checked out - and there is already room for only one or two rows to show unless the screen resolution is dialed up.
Comment 5 vimal kumar 2016-02-05 04:42:58 UTC
"Always show checkouts immediately" is an annoying feature for library professionals in circulation desk. This feature is against the "Five Laws of Library Science" Save the Time of the reader!!
Comment 6 Owen Leonard 2016-02-05 13:16:27 UTC
Which reader do you want to save time for? The reader who wants to see the list of checkouts  right away or the reader who wants to have the page load quickly when there are hundreds of checkouts? The point of this bug is to make a new preference so you can have it either leave things the way they are now or return them to the way things were before the changes made by Bug 12550. A preference is the only way to give options to the various needs different librarians have expressed.
Comment 7 vimal kumar 2016-02-05 16:34:59 UTC
(In reply to Owen Leonard from comment #6)
> Which reader do you want to save time for? The reader who wants to see the
> list of checkouts  right away or the reader who wants to have the page load
> quickly when there are hundreds of checkouts? The point of this bug is to
> make a new preference so you can have it either leave things the way they
> are now or return them to the way things were before the changes made by Bug
> 12550. A preference is the only way to give options to the various needs
> different librarians have expressed.

After check out, library professionals have the tendency to check the list of books checked out. If the list hide , they have to click on the checkbox of ("Always show checkouts immediately").

when the library professional open Check out of a particular user, he has to click on "Always show checkouts immediately" option. this process is time consuming when good number of reader in que to check out the books.
Comment 8 Owen Leonard 2016-02-05 16:46:17 UTC
(In reply to vimal kumar from comment #7)

> when the library professional open Check out of a particular user, he has to
> click on "Always show checkouts immediately" option. this process is time
> consuming

It sounds to me like this bug is exactly what you want: A way to make it so that "Always show checkouts immediately" is globally enabled without a checkbox.
Comment 9 Galen Charlton 2016-06-13 13:55:58 UTC
(In reply to Agnes Rivers-Moore from comment #4)
> I would wish to have that associated with the "Always show" function so that
> it only appears if "always show" is turned off.
> It uses up screen space we would rather use to see the last several items we
> checked out - and there is already room for only one or two rows to show
> unless the screen resolution is dialed up.

A patch implementing this can be found at http://git.esilibrary.com/?p=koha-equinox.git;a=commitdiff;h=6d63573393b911444db599b1b2e2d5c680ee5a15. Perhaps this should be spun off into a separate bug?
Comment 10 Séverine Queune 2017-11-06 17:42:39 UTC
We added this code on 'IntranetUserJS' syspref and it works perfectly for us :)
(Found on Biblibre's documentation)


$(document).ready(function() {
 
if ( typeof script !== 'undefined' && ! $.cookie("issues-table-load-immediately-" + script) ) {
    $.cookie("issues-table-load-immediately-" + script, true, { expires: 365 });
}
 
});
Comment 11 Katrin Fischer 2020-01-07 21:34:26 UTC
(In reply to Séverine Queune from comment #10)
> We added this code on 'IntranetUserJS' syspref and it works perfectly for us
> :)
> (Found on Biblibre's documentation)
> 
> 
> $(document).ready(function() {
>  
> if ( typeof script !== 'undefined' && !
> $.cookie("issues-table-load-immediately-" + script) ) {
>     $.cookie("issues-table-load-immediately-" + script, true, { expires: 365
> });
> }
>  
> });

Using Severine's workaround - marking WONTFIX.
Comment 12 Kelly McElligott 2020-02-04 13:23:08 UTC
I want to open this back up, please. I believe that this is worth talking about again.  A system preference would be optimal to allow libraries to turn on/off.
Comment 13 Marie-Luce Laflamme 2022-10-03 15:42:45 UTC
The IntranetUserJS syspref work around isn't working in Koha 22.05+ version.
Comment 14 Katrin Fischer 2022-10-24 21:31:41 UTC
(In reply to Marie-Luce Laflamme from comment #13)
> The IntranetUserJS syspref work around isn't working in Koha 22.05+ version.

The handling for cookies has changed, this appears to work on master:

$(document).ready(function() {
 
if (typeof script !== 'undefined' && Cookies.get("issues-table-load-immediately-" + script) !== "true") {
    Cookies.set("issues-table-load-immediately-" + script, true, { expires: 365, sameSite: 'Lax'  });
}
 
});
Comment 15 Marie-Luce Laflamme 2022-10-25 20:33:46 UTC
(In reply to Katrin Fischer from comment #14)
> (In reply to Marie-Luce Laflamme from comment #13)
> > The IntranetUserJS syspref work around isn't working in Koha 22.05+ version.
> 
> The handling for cookies has changed, this appears to work on master:
> 
> $(document).ready(function() {
>  
> if (typeof script !== 'undefined' &&
> Cookies.get("issues-table-load-immediately-" + script) !== "true") {
>     Cookies.set("issues-table-load-immediately-" + script, true, { expires:
> 365, sameSite: 'Lax'  });
> }
>  
> });


Your quick fix works well in 22.05 and the latest master version.

Thanks Kathrin
Comment 16 Katrin Fischer 2022-10-25 20:52:16 UTC
(In reply to Marie-Luce Laflamme from comment #15)
> (In reply to Katrin Fischer from comment #14)
> > (In reply to Marie-Luce Laflamme from comment #13)
> > > The IntranetUserJS syspref work around isn't working in Koha 22.05+ version.
> > 
> > The handling for cookies has changed, this appears to work on master:
> > 
> > $(document).ready(function() {
> >  
> > if (typeof script !== 'undefined' &&
> > Cookies.get("issues-table-load-immediately-" + script) !== "true") {
> >     Cookies.set("issues-table-load-immediately-" + script, true, { expires:
> > 365, sameSite: 'Lax'  });
> > }
> >  
> > });
> 
> 
> Your quick fix works well in 22.05 and the latest master version.
> 
> Thanks Kathrin

Thx for the feedback, happy it helped!
Comment 17 Donna 2023-02-17 18:57:14 UTC
While it's great to have the js, it would be awesome if this could be a system preference.
Comment 18 Kristi 2023-07-14 19:01:52 UTC
Agreed on this. It would be nice if showing checkouts automatically would be a system preference.
Comment 19 Agnes Rivers-Moore 2023-10-10 17:28:58 UTC
+1 for making it a syspref the library can control, and that persists! We just had an upgrade and lost this work around again. For our library this is essential customer service - when staff check out we look for anything that's due soon and needs renewing. Also helps in self-checkout, that red overdue items show immediately. Thanks!
Comment 20 Marie-Luce Laflamme 2023-10-18 20:33:30 UTC
I agree, it would be a huge plus to have a system preference instead of using JS code.
Comment 21 Laura O'Neil 2023-11-13 19:05:44 UTC
This is a big request from our partner libraries; turning this into a system preference would be lovely. The JS is good to have on hand, but sometimes stops working after major releases.
Comment 22 Lucas Gass (lukeg) 2024-01-26 17:44:25 UTC
Created attachment 161548 [details] [review]
Bug 14180: Perltidy

To test:
1. APPLY PATCH, updatedatebase, restart_all
2. Search for the system preference 'AlwaysLoadCheckoutsTable' and set it to 'Do'.
3. Go to 'circ/circulation.pl?borrowernumber=X' for a patron with checkouts. ( Check out tab ).
4. The table should load right away.
5. Go to 'members/moremember.pl?borrowernumber=X' for a patron with checkouts. ( Details tab ).
6. The table should load right way.
7. Set a value in the 'LoadCheckoutsTableDelay' system preference.
8. Back on 'circ/circulation.pl?borrowernumber=X', make sure the delay is honored. You should see a message like "Checkouts table will automatically load in X seconds".
9. The delay should NOT be honored on'members/moremember.pl?borrowernumber=X', that table should load right away/
10. Turn off 'AlwaysLoadCheckoutsTable' and make sure the table does not load, or loads according to the cookie set when checking the 'Always show checkouts automatically' checkbox.
Comment 23 Lucas Gass (lukeg) 2024-01-26 17:45:01 UTC
Created attachment 161549 [details] [review]
Bug 14180: Add AlwaysLoadCheckoutsTable system preference
Comment 24 Lucas Gass (lukeg) 2024-01-26 17:45:04 UTC
Created attachment 161550 [details] [review]
Bug 14180: Add option to always load the issues table
Comment 25 Lucas Gass (lukeg) 2024-01-26 17:45:07 UTC
Created attachment 161551 [details] [review]
Bug 14180: Perltidy

To test:
1. APPLY PATCH, updatedatebase, restart_all
2. Search for the system preference 'AlwaysLoadCheckoutsTable' and set it to 'Do'.
3. Go to 'circ/circulation.pl?borrowernumber=X' for a patron with checkouts. ( Check out tab ).
4. The table should load right away.
5. Go to 'members/moremember.pl?borrowernumber=X' for a patron with checkouts. ( Details tab ).
6. The table should load right way.
7. Set a value in the 'LoadCheckoutsTableDelay' system preference.
8. Back on 'circ/circulation.pl?borrowernumber=X', make sure the delay is honored. You should see a message like "Checkouts table will automatically load in X seconds".
9. The delay should NOT be honored on'members/moremember.pl?borrowernumber=X', that table should load right away/
10. Turn off 'AlwaysLoadCheckoutsTable' and make sure the table does not load, or loads according to the cookie set when checking the 'Always show checkouts automatically' checkbox.
Comment 26 ByWater Sandboxes 2024-01-26 18:23:24 UTC
Created attachment 161554 [details] [review]
Bug 14180: Add AlwaysLoadCheckoutsTable system preference

Signed-off-by: Kelly <kelly@bywatersolutions.com>
Comment 27 ByWater Sandboxes 2024-01-26 18:23:27 UTC
Created attachment 161555 [details] [review]
Bug 14180: Add option to always load the issues table

Signed-off-by: Kelly <kelly@bywatersolutions.com>
Comment 28 ByWater Sandboxes 2024-01-26 18:23:30 UTC
Created attachment 161556 [details] [review]
Bug 14180: Perltidy

To test:
1. APPLY PATCH, updatedatebase, restart_all
2. Search for the system preference 'AlwaysLoadCheckoutsTable' and set it to 'Do'.
3. Go to 'circ/circulation.pl?borrowernumber=X' for a patron with checkouts. ( Check out tab ).
4. The table should load right away.
5. Go to 'members/moremember.pl?borrowernumber=X' for a patron with checkouts. ( Details tab ).
6. The table should load right way.
7. Set a value in the 'LoadCheckoutsTableDelay' system preference.
8. Back on 'circ/circulation.pl?borrowernumber=X', make sure the delay is honored. You should see a message like "Checkouts table will automatically load in X seconds".
9. The delay should NOT be honored on'members/moremember.pl?borrowernumber=X', that table should load right away/
10. Turn off 'AlwaysLoadCheckoutsTable' and make sure the table does not load, or loads according to the cookie set when checking the 'Always show checkouts automatically' checkbox.

Signed-off-by: Kelly <kelly@bywatersolutions.com>
Comment 29 Andrew Fuerste-Henry 2024-02-02 20:38:12 UTC
This looks like maybe it should have been set to Signed Off when Kelly tested it 1/26. As of today, the patch doesn't apply.
Comment 30 Lucas Gass (lukeg) 2024-02-05 21:37:17 UTC
(In reply to Andrew Fuerste-Henry from comment #29)
> This looks like maybe it should have been set to Signed Off when Kelly
> tested it 1/26. As of today, the patch doesn't apply.

Due to patches from Bug 35506 being pushed to master.
Comment 31 Nick Clemens (kidclamp) 2024-08-06 13:13:44 UTC
Created attachment 170095 [details] [review]
Bug 14180: Add AlwaysLoadCheckoutsTable system preference

Signed-off-by: Kelly <kelly@bywatersolutions.com>
Comment 32 Nick Clemens (kidclamp) 2024-08-06 13:13:47 UTC
Created attachment 170096 [details] [review]
Bug 14180: Add option to always load the issues table

Signed-off-by: Kelly <kelly@bywatersolutions.com>
Comment 33 Nick Clemens (kidclamp) 2024-08-06 13:14:58 UTC
Created attachment 170097 [details] [review]
Bug 14180: Add AlwaysLoadCheckoutsTable system preference

Signed-off-by: Kelly <kelly@bywatersolutions.com>
Comment 34 Nick Clemens (kidclamp) 2024-08-06 13:15:02 UTC
Created attachment 170098 [details] [review]
Bug 14180: Add option to always load the issues table

To test:
 1. APPLY PATCH, updatedatebase, restart_all
 2. Search for the system preference 'AlwaysLoadCheckoutsTable' and set it to 'Do'.
 3. Go to 'circ/circulation.pl?borrowernumber=X' for a patron with checkouts. ( Check out tab ).
 4. The table should load right away.
 5. Go to 'members/moremember.pl?borrowernumber=X' for a patron with checkouts. ( Details tab ).
 6. The table should load right way.
 7. Set a value in the 'LoadCheckoutsTableDelay' system preference.
 8. Back on 'circ/circulation.pl?borrowernumber=X', make sure the delay is honored. You should see a message like "Checkouts table will automatically load in X seconds".
 9. The delay should NOT be honored on'members/moremember.pl?borrowernumber=X', that table should load right away/
10. Turn off 'AlwaysLoadCheckoutsTable' and make sure the table does not load, or loads according to the cookie set when checking the 'Always show checkouts automatically' checkbox.

Signed-off-by: Kelly <kelly@bywatersolutions.com>
Comment 35 Liz Rea 2024-10-04 22:00:09 UTC
Hi,
Can we get a QA for this please? It's very silly that we have to use jquery - this is a feature a lot of libraries need.
Comment 36 Laura O'Neil 2024-10-08 17:18:01 UTC
Yes please, this would be enormously helpful.
Comment 37 Tomás Cohen Arazi (tcohen) 2024-10-25 14:56:29 UTC
Created attachment 173382 [details] [review]
Bug 14180: Add AlwaysLoadCheckoutsTable system preference

Signed-off-by: Kelly <kelly@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Comment 38 Tomás Cohen Arazi (tcohen) 2024-10-25 14:56:33 UTC
Created attachment 173383 [details] [review]
Bug 14180: Add option to always load the issues table

To test:
 1. APPLY PATCH, updatedatebase, restart_all
 2. Search for the system preference 'AlwaysLoadCheckoutsTable' and set it to 'Do'.
 3. Go to 'circ/circulation.pl?borrowernumber=X' for a patron with checkouts. ( Check out tab ).
 4. The table should load right away.
 5. Go to 'members/moremember.pl?borrowernumber=X' for a patron with checkouts. ( Details tab ).
 6. The table should load right way.
 7. Set a value in the 'LoadCheckoutsTableDelay' system preference.
 8. Back on 'circ/circulation.pl?borrowernumber=X', make sure the delay is honored. You should see a message like "Checkouts table will automatically load in X seconds".
 9. The delay should NOT be honored on'members/moremember.pl?borrowernumber=X', that table should load right away/
10. Turn off 'AlwaysLoadCheckoutsTable' and make sure the table does not load, or loads according to the cookie set when checking the 'Always show checkouts automatically' checkbox.

Signed-off-by: Kelly <kelly@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Comment 39 Tomás Cohen Arazi (tcohen) 2024-10-25 14:56:37 UTC
Created attachment 173384 [details] [review]
Bug 14180: (QA follow-up) Re-arrange sysprefs to fix QA warnings

Not strictly related to this patchset, but showed up here.

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Comment 40 Katrin Fischer 2024-10-30 06:28:15 UTC
1) Database update

Please don't leave out the success line of the database update:

        say_success( $out, "Added new system preference 'AlwaysLoadCheckoutsTable'" );

Fixed on push.

2) System preferences

checksouts > checkouts 

Fixed in follow-up.
Comment 41 Katrin Fischer 2024-10-30 06:48:27 UTC
Pushed for 24.11!

Well done everyone, thank you!
Comment 42 Lucas Gass (lukeg) 2024-11-05 15:58:29 UTC
Enhancement. No 24.05.x backport.