Bugzilla – Attachment 184934 Details for
Bug 40567
Correct eslint errors in recalls.js
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 40567: Correct eslint errors in recalls.js
Bug-40567-Correct-eslint-errors-in-recallsjs.patch (text/plain), 4.17 KB, created by
Owen Leonard
on 2025-07-31 15:54:19 UTC
(
hide
)
Description:
Bug 40567: Correct eslint errors in recalls.js
Filename:
MIME Type:
Creator:
Owen Leonard
Created:
2025-07-31 15:54:19 UTC
Size:
4.17 KB
patch
obsolete
>From ffdf535fc82acafcfccf959c60e921cf76702b9d Mon Sep 17 00:00:00 2001 >From: Owen Leonard <oleonard@myacpl.org> >Date: Thu, 31 Jul 2025 15:21:04 +0000 >Subject: [PATCH] Bug 40567: Correct eslint errors in recalls.js > >This patch corrects a few minor errors in recalls.js. There should be no >change to how the pages work. > >The following functions have been changed: > >- Cancel a recall from the recalls tab on a patron record >- Expire a recall or revert the waiting status of a recall from the > "Recalls awaiting pickup" page. >- Cancel a recall which has been transferred from the "Recalls queue" > page. >- Mark a recall "Overdue" from the "Recalls queue" page. >- Cancel selected recalls on the "Recalls queue" page. > >Sponsored-by: Athens County Public Libraries >--- > koha-tmpl/intranet-tmpl/prog/js/recalls.js | 18 ++++++++++++------ > 1 file changed, 12 insertions(+), 6 deletions(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/js/recalls.js b/koha-tmpl/intranet-tmpl/prog/js/recalls.js >index 1da935810a9..bb543333ae2 100644 >--- a/koha-tmpl/intranet-tmpl/prog/js/recalls.js >+++ b/koha-tmpl/intranet-tmpl/prog/js/recalls.js >@@ -1,10 +1,12 @@ >+/* global APIClient __ confirmDelete */ > $(document).ready(function () { > const client = APIClient.recall; > >- $(".cancel_recall").click(function (e) { >+ $(".cancel_recall").click(function () { > if (confirmDelete(__("Are you sure you want to remove this recall?"))) { > let td_node = $(this).parents("td"); > let recall_id = $(this).data("id"); >+ let message; > client.recalls.cancel(recall_id).then( > success => { > if (success.success == 0) { >@@ -23,10 +25,11 @@ $(document).ready(function () { > } > }); > >- $(".expire_recall").click(function (e) { >+ $(".expire_recall").click(function () { > if (confirmDelete(__("Are you sure you want to expire this recall?"))) { > let td_node = $(this).parents("td"); > let recall_id = $(this).data("id"); >+ let message; > client.recalls.expire(recall_id).then( > success => { > if (success.success == 0) { >@@ -45,7 +48,7 @@ $(document).ready(function () { > } > }); > >- $(".revert_recall").click(function (e) { >+ $(".revert_recall").click(function () { > if ( > confirmDelete( > __( >@@ -55,6 +58,7 @@ $(document).ready(function () { > ) { > let td_node = $(this).parents("td"); > let recall_id = $(this).data("id"); >+ let message; > client.recalls.revert(recall_id).then( > success => { > if (success.success == 0) { >@@ -73,7 +77,7 @@ $(document).ready(function () { > } > }); > >- $(".overdue_recall").click(function (e) { >+ $(".overdue_recall").click(function () { > if ( > confirmDelete( > __("Are you sure you want to mark this recall as overdue?") >@@ -81,6 +85,7 @@ $(document).ready(function () { > ) { > let td_node = $(this).parents("td"); > let recall_id = $(this).data("id"); >+ let message; > client.recalls.overdue(recall_id).then( > success => { > if (success.success == 0) { >@@ -99,7 +104,7 @@ $(document).ready(function () { > } > }); > >- $(".transit_recall").click(function (e) { >+ $(".transit_recall").click(function () { > if ( > confirmDelete( > __( >@@ -109,6 +114,7 @@ $(document).ready(function () { > ) { > let td_node = $(this).parents("td"); > let recall_id = $(this).data("id"); >+ let message; > client.recalls.transit(recall_id).then( > success => { > if (success.success == 0) { >@@ -133,7 +139,7 @@ $(document).ready(function () { > pagingType: "full_numbers", > }); > >- $("#cancel_selected").click(function (e) { >+ $("#cancel_selected").click(function () { > if ($("input[name='recall_ids']:checked").length > 0) { > return confirmDelete( > __("Are you sure you want to remove the selected recall(s)?") >-- >2.39.5
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 40567
: 184934