Bugzilla – Attachment 184404 Details for
Bug 40395
Allow selecting multiple holds in patron detail page to perform actions on
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 40395: Refactor: Move suspend modal to its own tt BLOCK
Bug-40395-Refactor-Move-suspend-modal-to-its-own-t.patch (text/plain), 5.45 KB, created by
Andrew Fuerste-Henry
on 2025-07-18 16:38:35 UTC
(
hide
)
Description:
Bug 40395: Refactor: Move suspend modal to its own tt BLOCK
Filename:
MIME Type:
Creator:
Andrew Fuerste-Henry
Created:
2025-07-18 16:38:35 UTC
Size:
5.45 KB
patch
obsolete
>From d65401cdde409789b09b65f3eddabbd4bdbfa68f Mon Sep 17 00:00:00 2001 >From: Pedro Amorim <pedro.amorim@openfifth.co.uk> >Date: Tue, 15 Jul 2025 13:12:03 +0000 >Subject: [PATCH] Bug 40395: Refactor: Move suspend modal to its own tt BLOCK > >Signed-off-by: Andrew Fuerste Henry <andrew@bywatersolutions.com> >--- > .../en/includes/modals/holds_table_modals.inc | 34 ++++++++++++++- > .../prog/en/includes/patron-detail-tabs.inc | 1 + > koha-tmpl/intranet-tmpl/prog/js/holds.js | 42 ------------------- > 3 files changed, 34 insertions(+), 43 deletions(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/includes/modals/holds_table_modals.inc b/koha-tmpl/intranet-tmpl/prog/en/includes/modals/holds_table_modals.inc >index 13276930439..7beb583dff1 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/includes/modals/holds_table_modals.inc >+++ b/koha-tmpl/intranet-tmpl/prog/en/includes/modals/holds_table_modals.inc >@@ -41,4 +41,36 @@ > </div> > </div> > </div> >-[% END %] >\ No newline at end of file >+[% END %] >+ >+[% BLOCK 'suspend-hold-modal' %] >+ <div id="suspend-modal" class="modal" role="dialog" aria-hidden="true"> >+ <div class="modal-dialog"> >+ <div class="modal-content"> >+ <form id="suspend-modal-form" class="form-inline"> >+ <div class="modal-header"> >+ <h1 class="modal-title" id="suspend-modal-label"> >+ Suspend hold on >+ <span id="suspend-modal-title"></span >+ ></h1> >+ <button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button> >+ </div> >+ <div class="modal-body"> >+ [% IF Koha.Preference('AutoResumeSuspendedHolds') %] >+ <label for="suspend-modal-until">Suspend until: </label> >+ <input name="suspend_until" id="suspend-modal-until" class="suspend-until flatpickr" data-flatpickr-futuredate="true" size="10" /> >+ >+ <p><a class="btn btn-link" id="suspend-modal-clear-date">Clear date to suspend indefinitely</a></p> >+ [% ELSE %] >+ <p>Are you sure you want to suspend indefinitely?</p> >+ [% END %] >+ </div> >+ <div class="modal-footer"> >+ <button id="suspend-modal-submit" class="btn btn-primary" type="submit" name="submit">Suspend</button> >+ <button type="button" class="btn btn-default" data-bs-dismiss="modal">Cancel </button> >+ </div> >+ </form> >+ </div> >+ </div> >+ </div> >+[% END %] >diff --git a/koha-tmpl/intranet-tmpl/prog/en/includes/patron-detail-tabs.inc b/koha-tmpl/intranet-tmpl/prog/en/includes/patron-detail-tabs.inc >index ef6865313fa..0322d532061 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/includes/patron-detail-tabs.inc >+++ b/koha-tmpl/intranet-tmpl/prog/en/includes/patron-detail-tabs.inc >@@ -171,6 +171,7 @@ > </form> > > [% PROCESS 'cancel-hold-modal' form_action = '/cgi-bin/koha/reserve/modrequest.pl' from_param = patronpage %] >+ [% PROCESS 'suspend-hold-modal' %] > > [% IF Koha.Preference('SuspendHoldsIntranet') %] > <fieldset class="action"> >diff --git a/koha-tmpl/intranet-tmpl/prog/js/holds.js b/koha-tmpl/intranet-tmpl/prog/js/holds.js >index a1833400a2f..b6e9d988380 100644 >--- a/koha-tmpl/intranet-tmpl/prog/js/holds.js >+++ b/koha-tmpl/intranet-tmpl/prog/js/holds.js >@@ -570,48 +570,6 @@ $(document).ready(function () { > } > } > >- $("body").append( >- "\ >- <div id='suspend-modal' class='modal' role='dialog' aria-hidden='true'>\ >- <div class='modal-dialog'>\ >- <div class='modal-content'>\ >- <form id='suspend-modal-form' class='form-inline'>\ >- <div class='modal-header'>\ >- <h1 class='modal-title' id='suspend-modal-label'>" + >- __("Suspend hold on") + >- " <i><span id='suspend-modal-title'></span></i></h1>\ >- <button type='button' class='btn-close' data-bs-dismiss='modal' aria-label='Close'></button>\ >- </div>\ >-\ >- <div class='modal-body'>\ >-\ >- <label for='suspend-modal-until'>" + >- __("Suspend until:") + >- "</label>\ >- <input name='suspend_until' id='suspend-modal-until' class='suspend-until flatpickr' data-flatpickr-futuredate='true' size='10' />\ >-\ >- <p><a class='btn btn-link' id='suspend-modal-clear-date' >" + >- __("Clear date to suspend indefinitely") + >- "</a></p>\ >-\ >- </div>\ >-\ >- <div class='modal-footer'>\ >- <button id='suspend-modal-submit' class='btn btn-primary' type='submit' name='submit'>" + >- __("Suspend") + >- "</button>\ >- <button type='button' class='btn btn-default' data-bs-dismiss='modal'>" + >- __("Cancel") + >- "</button>\ >- </div>\ >- <div id='suspend-selected-container'></div>\ >- </form>\ >- </div>\ >- </div>\ >- </div>\ >- " >- ); >- > $("#suspend-modal-clear-date").on("click", function () { > $("#suspend-modal-until").flatpickr().clear(); > }); >-- >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 40395
:
184109
|
184110
|
184111
|
184112
|
184113
|
184114
|
184115
|
184116
|
184134
|
184135
|
184136
|
184137
|
184138
|
184139
|
184140
|
184141
|
184398
|
184399
|
184400
|
184401
|
184402
|
184403
|
184404
|
184405
|
184434
|
184435
|
184437
|
184470
|
184471
|
184472
|
184473
|
184474
|
184475
|
184476
|
184477
|
184478
|
184479