Bugzilla – Attachment 134951 Details for
Bug 30388
Fix some errors in the template for ordering from a MARC file
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 30388: Fix some errors in the template for ordering from a MARC file
Bug-30388-Fix-some-errors-in-the-template-for-orde.patch (text/plain), 13.63 KB, created by
Katrin Fischer
on 2022-05-13 08:10:02 UTC
(
hide
)
Description:
Bug 30388: Fix some errors in the template for ordering from a MARC file
Filename:
MIME Type:
Creator:
Katrin Fischer
Created:
2022-05-13 08:10:02 UTC
Size:
13.63 KB
patch
obsolete
>From fbdd1f2927be5350700bb1d678403f9a0019d69f Mon Sep 17 00:00:00 2001 >From: Owen Leonard <oleonard@myacpl.org> >Date: Mon, 28 Mar 2022 17:28:50 +0000 >Subject: [PATCH] Bug 30388: Fix some errors in the template for ordering from > a MARC file > >This patch fixes a few markup errors in the addorder2709 template. The >modal dialog markup is corrected and moved out of the loop of records so >that it doesn't create repeating id attributes. Obsolete CSS is removed, >fixing the width of the MARC preview modal. > >The calendar include is added, fixing a Flatpickr error in the console. > >Double ID attributes are removed from the Statistics 1 and Statistics 2 >fields. > >To test, apply the patch and test the process of adding an order to a >basket from a staged MARC file. Test in particular: > > - The MARC and Card previews > - The "Date acquired" field under the "Item information" tab should > trigger a Flatpickr widget. > >Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz> > >Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de> >--- > .../prog/en/modules/acqui/addorderiso2709.tt | 100 +++++++++--------- > 1 file changed, 51 insertions(+), 49 deletions(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/addorderiso2709.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/addorderiso2709.tt >index 4baf5ff52e..44eb33ae7a 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/addorderiso2709.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/addorderiso2709.tt >@@ -10,7 +10,7 @@ > Batch list > [% END %] › Order staged MARC records › Acquisitions › Koha > </title> >-<style>#dataPreview { width : 80%; } @media (max-width: 767px) { #dataPreview { margin: 0; width : auto; } }</style> >+<style>@media (max-width: 767px) { #dataPreview { margin: 0; width : auto; } }</style> > [% INCLUDE 'doc-head-close.inc' %] > [%# As long as cataloging plugins rely on 'script' tags added inline, JS must be in the header %] > [% Asset.js("js/acquisitions-menu.js") | $raw %] >@@ -18,6 +18,7 @@ > [% Asset.js("js/acq.js") | $raw %] > [% Asset.js("js/funds_sorts.js") | $raw %] > [% Asset.js("js/addorderiso2709.js") | $raw %] >+[% INCLUDE 'calendar.inc' %] > </head> > > <body id="acq_addorderiso2709" class="acq"> >@@ -180,11 +181,11 @@ > </li> > <li class="sort1"> > <label for="sort1_record_[% biblio.import_record_id | html %]">Statistic 1: </label> >- <input id="sort1_record_[% biblio.import_record_id | html %]" type="text" id="sort1" size="20" name="sort1" value="[% biblio.sort1 | html %]" /> >+ <input id="sort1_record_[% biblio.import_record_id | html %]" type="text" size="20" name="sort1" value="[% biblio.sort1 | html %]" /> > </li> > <li class="sort2"> > <label for="sort2_record_[% biblio.import_record_id | html %]">Statistic 2: </label> >- <input id="sort2_record_[% biblio.import_record_id | html %]" type="text" id="sort2" size="20" name="sort2" value="[% biblio.sort2 | html %]" /> >+ <input id="sort2_record_[% biblio.import_record_id | html %]" type="text" size="20" name="sort2" value="[% biblio.sort2 | html %]" /> > </li> > </ol> > </div> >@@ -319,23 +320,24 @@ > </div> > </fieldset> <!-- .biblio.unselected.rows --> > >- <div id="dataPreview" class="modal fade" tabindex="-1" role="dialog" aria-labelledby="dataPreviewLabel" aria-hidden="true"> >- <div class="modal-dialog"> >- <div class="modal-content"> >- <div class="modal-header"> >- <button type="button" class="closebtn" data-dismiss="modal" aria-hidden="true">Ã</button> >- <h3 id="dataPreviewLabel">MARC preview</h3> >- </div> >- <div class="modal-body"> >- <div id="loading"> <img src="[% interface | html %]/[% theme | html %]/img/spinner-small.gif" alt="" /> Loading </div> >- </div> >- <div class="modal-footer"> >- <button class="btn btn-default" data-dismiss="modal" aria-hidden="true">Close</button> >- </div> >- </div> <!-- /.modal-content --> >- </div> <!-- /modal-dialog --> >- </div> <!-- /#dataPreview --> > [% END # /FOREACH biblio %] >+ <div class="modal" id="dataPreview" tabindex="-1" role="dialog" aria-labelledby="dataPreviewLabel"> >+ <div class="modal-dialog modal-lg" role="document"> >+ <div class="modal-content"> >+ <div class="modal-header"> >+ <button type="button" class="closebtn" data-dismiss="modal" aria-label="Close"><span >+ aria-hidden="true">×</span></button> >+ <h4 id="dataPreviewLabel">MARC preview</h4> >+ </div> >+ <div class="modal-body"> >+ <div id="loading"> <img src="[% interface | html %]/[% theme | html %]/img/spinner-small.gif" alt="" /> Loading </div> >+ </div> >+ <div class="modal-footer"> >+ <button class="btn btn-default" data-dismiss="modal" aria-hidden="true">Close</button> >+ </div> >+ </div> <!-- /.modal-content --> >+ </div> <!-- /.modal-dialog --> >+ </div> <!-- /#dataPreview --> > </div> <!-- /#records_to_import --> > > <div id="items_info"> >@@ -402,40 +404,40 @@ > <!-- origquantityrec only here for javascript compatibility (additem.js needs it, useless here, useful when receiveing an order --> > <input id="origquantityrec" readonly="readonly" type="hidden" name="origquantityrec" value="1" /> > </li> >- <li> >- [% IF ( close ) %] >+ [% IF ( close ) %] >+ <li> > <span class="label">Fund: </span> > <input type="hidden" size="20" name="budget_id" id="budget_id" value="[% budget_id | html %]" />[% Budget_name | html %] >- [% ELSE %] >- <li> >- <label for="all_currency">Currency:</label> >- <select name="all_currency" id="all_currency"> >- [% FOREACH currency IN currencies %] >- [% IF currency.currency == bookseller.listprice %] >- <option value="[% currency.currency | html %]" selected="selected">[% currency.currency | html %]</option> >- [% ELSIF not currency.archived %] >- <option value="[% currency.currency | html %]">[% currency.currency | html %]</option> >- [% END %] >+ </li> >+ [% ELSE %] >+ <li> >+ <label for="all_currency">Currency:</label> >+ <select name="all_currency" id="all_currency"> >+ [% FOREACH currency IN currencies %] >+ [% IF currency.currency == bookseller.listprice %] >+ <option value="[% currency.currency | html %]" selected="selected">[% currency.currency | html %]</option> >+ [% ELSIF not currency.archived %] >+ <option value="[% currency.currency | html %]">[% currency.currency | html %]</option> > [% END %] >- </select> >- </li> >- <li> >- <label for="all_budget_id">Fund: </label> >- <select id="all_budget_id" name="all_budget_id"> >- <option value="">Select a fund (will populate orders/items if set)</option> >- [% FOREACH budget_loo IN budget_loop %] >- [% IF ( budget_loo.b_active ) %] >- <option value="[% budget_loo.b_id | html %]" data-sort1-authcat="[% budget_loo.b_sort1_authcat | html %]" data-sort2-authcat="[% budget_loo.b_sort2_authcat | html %]">[% budget_loo.b_txt | html %]</option> >- [% ELSE %] >- <option value="[% budget_loo.b_id | html %]" class="b_inactive" data-sort1-authcat="[% budget_loo.b_sort1_authcat | html %]" data-sort2-authcat="[% budget_loo.b_sort2_authcat | html %]">[% budget_loo.b_txt | html %] (inactive)</option> >- [% END %] >+ [% END %] >+ </select> >+ </li> >+ <li> >+ <label for="all_budget_id">Fund: </label> >+ <select id="all_budget_id" name="all_budget_id"> >+ <option value="">Select a fund (will populate orders/items if set)</option> >+ [% FOREACH budget_loo IN budget_loop %] >+ [% IF ( budget_loo.b_active ) %] >+ <option value="[% budget_loo.b_id | html %]" data-sort1-authcat="[% budget_loo.b_sort1_authcat | html %]" data-sort2-authcat="[% budget_loo.b_sort2_authcat | html %]">[% budget_loo.b_txt | html %]</option> >+ [% ELSE %] >+ <option value="[% budget_loo.b_id | html %]" class="b_inactive" data-sort1-authcat="[% budget_loo.b_sort1_authcat | html %]" data-sort2-authcat="[% budget_loo.b_sort2_authcat | html %]">[% budget_loo.b_txt | html %] (inactive)</option> > [% END %] >- </select> >- <label for="all_showallbudgets" style="float:none;width:auto;"> Show inactive:</label> >- <input type="checkbox" id="all_showallbudgets" /> >- </li> >- [% END #/IF close %] >- </li> >+ [% END %] >+ </select> >+ <label for="all_showallbudgets" style="float:none;width:auto;"> Show inactive:</label> >+ <input type="checkbox" id="all_showallbudgets" /> >+ </li> >+ [% END #/IF close %] > <li> > <label for="all_order_internalnote">Internal note: </label> > <textarea id="all_order_internalnote" cols="30" rows="3" name="all_order_internalnote"></textarea> >-- >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 30388
:
132358
|
134660
| 134951