Bugzilla – Attachment 158792 Details for
Bug 35068
Split 'Renew or check in selected items' button in issues table into separate buttons
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 35068: (follow-up): Make sure renew/checkin selections get retained on reload
Bug-35068-follow-up-Make-sure-renewcheckin-selecti.patch (text/plain), 2.50 KB, created by
Marcel de Rooy
on 2023-11-10 08:56:53 UTC
(
hide
)
Description:
Bug 35068: (follow-up): Make sure renew/checkin selections get retained on reload
Filename:
MIME Type:
Creator:
Marcel de Rooy
Created:
2023-11-10 08:56:53 UTC
Size:
2.50 KB
patch
obsolete
>From edfe388f51580ac4b41bf80ca518507246b84cca Mon Sep 17 00:00:00 2001 >From: Lucas Gass <lucas@bywatersolutions.com> >Date: Fri, 3 Nov 2023 15:24:49 +0000 >Subject: [PATCH] Bug 35068: (follow-up): Make sure renew/checkin selections > get retained on reload >Content-Type: text/plain; charset=utf-8 > >To test: >1. Have two checkouts. Click one for Renew and one for Checkin. Click on Check in selected items. >2. When the table reloads the 'renew' selections should be retained >3. Have two checkouts. Click one for Renew and one for Checkin. Click on Renew selected items. >4. When the table reloads the 'check in' selections should be retained > >Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net> > >Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> >--- > koha-tmpl/intranet-tmpl/prog/js/checkouts.js | 23 ++++++++++++++++++-- > 1 file changed, 21 insertions(+), 2 deletions(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/js/checkouts.js b/koha-tmpl/intranet-tmpl/prog/js/checkouts.js >index 22f1f1a2b4..7fb8e89d73 100644 >--- a/koha-tmpl/intranet-tmpl/prog/js/checkouts.js >+++ b/koha-tmpl/intranet-tmpl/prog/js/checkouts.js >@@ -249,7 +249,6 @@ $(document).ready(function() { > if ( refresh_table ) { > RefreshIssuesTable(); > } >- $('#RenewChecked, #CheckinChecked').prop('disabled' , true ); > // Prevent form submit > return false; > }); >@@ -297,7 +296,27 @@ $(document).ready(function() { > > function RefreshIssuesTable() { > var table = $('#issues-table').DataTable(); >- table.ajax.reload(); >+ var renewchecked = $('input[name=renew]:checked').map(function(){ >+ return this.value; >+ }).get(); >+ var checkinchecked = $('input[name=checkin]:checked').map(function(){ >+ return this.value; >+ }).get(); >+ table.ajax.reload( function() { >+ $('#RenewChecked, #CheckinChecked').prop('disabled' , true ); >+ if ( renewchecked.length ) { >+ $('#RenewChecked').prop('disabled' , false ); >+ renewchecked.forEach( function(checked) { >+ $('.renew[value="'+checked+'"]').prop('checked' , true ); >+ }); >+ } >+ if ( checkinchecked.length ) { >+ $('#CheckinChecked').prop('disabled' , false ); >+ checkinchecked.forEach( function(checked) { >+ $('.checkin[value="'+checked+'"]').prop('checked' , true ); >+ }); >+ } >+ }); > } > > function LoadIssuesTable() { >-- >2.30.2
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 35068
:
157218
|
157254
|
157357
|
157465
|
157466
|
157467
|
157468
|
157523
|
157524
|
157525
|
157526
|
157552
|
158343
|
158476
|
158477
|
158478
|
158479
|
158480
|
158481
|
158482
|
158483
|
158484
|
158485
|
158788
|
158789
|
158790
|
158791
| 158792