Bugzilla – Attachment 100108 Details for
Bug 23112
Add circulation process to inter-library loans
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 23112: (QA follow-up) Fix database update, add filters, remove tabs
Bug-23112-QA-follow-up-Fix-database-update-add-fil.patch (text/plain), 10.25 KB, created by
Nick Clemens (kidclamp)
on 2020-03-04 12:11:37 UTC
(
hide
)
Description:
Bug 23112: (QA follow-up) Fix database update, add filters, remove tabs
Filename:
MIME Type:
Creator:
Nick Clemens (kidclamp)
Created:
2020-03-04 12:11:37 UTC
Size:
10.25 KB
patch
obsolete
>From 90495431e477db799ac92d4ab807d327bb7f4026 Mon Sep 17 00:00:00 2001 >From: Nick Clemens <nick@bywatersolutions.com> >Date: Wed, 4 Mar 2020 11:52:11 +0000 >Subject: [PATCH] Bug 23112: (QA follow-up) Fix database update, add filters, > remove tabs > >Looks like the atomicupdate and sysprefs.sql changes were lost at some point. > >Don't forget to run QA tools on your patches before submitting >--- > C4/Circulation.pm | 16 ++++++++-------- > Koha/Illrequest.pm | 18 +++++++++--------- > .../bug_23112_add_CirculateILL_syspref.perl | 6 ++++++ > installer/data/mysql/sysprefs.sql | 1 + > .../prog/en/modules/admin/preferences/circulation.pref | 14 +++++++------- > .../intranet-tmpl/prog/en/modules/ill/ill-requests.tt | 14 +++++++------- > 6 files changed, 38 insertions(+), 31 deletions(-) > create mode 100644 installer/data/mysql/atomicupdate/bug_23112_add_CirculateILL_syspref.perl > >diff --git a/C4/Circulation.pm b/C4/Circulation.pm >index ee6c420158..3f70b236f6 100644 >--- a/C4/Circulation.pm >+++ b/C4/Circulation.pm >@@ -2131,14 +2131,14 @@ sub AddReturn { > DelUniqueDebarment({ borrowernumber => $borrowernumber, type => 'OVERDUES' }); > } > >- # Check if this item belongs to a biblio record that is attached to an >- # ILL request, if it is we need to update the ILL request's status >- if (C4::Context->preference('CirculateILL')) { >- my $request = Koha::Illrequests->find( >- { biblio_id => $item->biblio->biblionumber } >- ); >- $request->status('RET') if $request; >- } >+ # Check if this item belongs to a biblio record that is attached to an >+ # ILL request, if it is we need to update the ILL request's status >+ if (C4::Context->preference('CirculateILL')) { >+ my $request = Koha::Illrequests->find( >+ { biblio_id => $item->biblio->biblionumber } >+ ); >+ $request->status('RET') if $request; >+ } > > # Transfer to returnbranch if Automatic transfer set or append message NeedsTransfer > if (!$is_in_rotating_collection && ($doreturn or $messages->{'NotIssued'}) and !$resfound and ($branch ne $returnbranch) and not $messages->{'WrongTransfer'}){ >diff --git a/Koha/Illrequest.pm b/Koha/Illrequest.pm >index e81997f8ce..c6280d2057 100644 >--- a/Koha/Illrequest.pm >+++ b/Koha/Illrequest.pm >@@ -499,15 +499,15 @@ sub _core_status_graph { > next_actions => [ ], > ui_method_icon => 'fa-upload', > }, >- RET => { >- prev_actions => [ 'CHK' ], >- id => 'RET', >- name => 'Returned to library', >- ui_method_name => 'Check in', >- method => 'check_in', >- next_actions => [ 'COMP' ], >- ui_method_icon => 'fa-download', >- } >+ RET => { >+ prev_actions => [ 'CHK' ], >+ id => 'RET', >+ name => 'Returned to library', >+ ui_method_name => 'Check in', >+ method => 'check_in', >+ next_actions => [ 'COMP' ], >+ ui_method_icon => 'fa-download', >+ } > }; > } > >diff --git a/installer/data/mysql/atomicupdate/bug_23112_add_CirculateILL_syspref.perl b/installer/data/mysql/atomicupdate/bug_23112_add_CirculateILL_syspref.perl >new file mode 100644 >index 0000000000..075e9142d2 >--- /dev/null >+++ b/installer/data/mysql/atomicupdate/bug_23112_add_CirculateILL_syspref.perl >@@ -0,0 +1,6 @@ >+$DBversion = 'XXX'; # will be replaced by the RM >+if( CheckVersion( $DBversion ) ) { >+ $dbh->do( q| INSERT IGNORE INTO systempreferences (variable, value, explanation, options, type) VALUES ('CirculateILL', '0', 'If enabled, it is possible to circulate ILL requested items from within ILL', '', 'YesNo'); | ); >+ SetVersion( $DBversion ); >+ print "Upgrade to $DBversion done (Bug 23112 - Add CirculateILL syspref)\n"; >+} >diff --git a/installer/data/mysql/sysprefs.sql b/installer/data/mysql/sysprefs.sql >index 40f7a4740f..401420ba20 100644 >--- a/installer/data/mysql/sysprefs.sql >+++ b/installer/data/mysql/sysprefs.sql >@@ -119,6 +119,7 @@ INSERT INTO systempreferences ( `variable`, `value`, `options`, `explanation`, ` > ('CircAutoPrintQuickSlip','qslip',NULL,'Choose what should happen when an empty barcode field is submitted in circulation: Display a print quick slip window, Display a print slip window or Clear the screen.','Choice'), > ('CircControl','ItemHomeLibrary','PickupLibrary|PatronLibrary|ItemHomeLibrary','Specify the agency that controls the circulation and fines policy','Choice'), > ('CircSidebar','0',NULL,'Activate or deactivate the navigation sidebar on all Circulation pages','YesNo'), >+('CirculateILL','0','','If enabled, it is possible to circulate ILL items from within ILL','YesNo'), > ('ClaimsBccCopy','0','','Bcc the ClaimAcquisition and ClaimIssues alerts','YesNo'), > ('ClaimReturnedChargeFee', 'ask', 'ask|charge|no_charge', 'Controls whether or not a lost item fee is charged for return claims', 'Choice'), > ('ClaimReturnedLostValue', '', '', 'Sets the LOST AV value that represents "Claims returned" as a lost value', 'Free'), >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/circulation.pref b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/circulation.pref >index 7f5335a6f7..4da08f7976 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/circulation.pref >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/circulation.pref >@@ -841,13 +841,13 @@ Circulation: > yes: Enable > no: Disable > - unmediated Interlibrary loan requests. If enabled and the ILL backend supports it, the newly created requests are immediately requested by backend. >- - >- - pref: CirculateILL >- default: 0 >- choices: >- yes: Enable >- no: Disable >- - the circulation of ILL requested items >+ - >+ - pref: CirculateILL >+ default: 0 >+ choices: >+ yes: Enable >+ no: Disable >+ - the circulation of ILL requested items > Fines Policy: > - > - pref: finesCalendar >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/ill/ill-requests.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/ill/ill-requests.tt >index b6d736e127..413e4a190a 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/ill/ill-requests.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/ill/ill-requests.tt >@@ -133,7 +133,7 @@ > </div> > [% ELSE %] > <div class="alert"> >- There was a problem checking this item out, please check for problems with the <a href="/cgi-bin/koha/members/moremember.pl?borrowernumber=[% whole.value.patron.borrowernumber %]">patron's account</a> >+ There was a problem checking this item out, please check for problems with the <a href="/cgi-bin/koha/members/moremember.pl?borrowernumber=[% whole.value.patron.borrowernumber | uri %]">patron's account</a> > </div> > [% END %] > [% END %] >@@ -154,9 +154,9 @@ > <option value=""></option> > [% FOREACH stat IN whole.value.statistical %] > [% IF stat.borrowernumber == params.inhouse %] >- <option value="[% stat.cardnumber %]" selected>[% stat.firstname %] [% stat.surname %]</option> >+ <option value="[% stat.cardnumber | html %]" selected>[% INCLUDE 'patron-title.inc' patron = stat %]</option> > [% ELSE %] >- <option value="[% stat.cardnumber %]">[% stat.firstname %] [% stat.surname %]</option> >+ <option value="[% stat.cardnumber | html %]">[% INCLUDE 'patron-title.inc' patron = stat %]</option> > [% END %] > [% END %] > </select> >@@ -193,7 +193,7 @@ > [% IF items.size == 1 %] > <li> > <label for="barcode" class="ill_checkout_barcode_label">Item barcode:</label> >- [% items.0.barcode %] >+ [% items.0.barcode | html %] > </li> > [% END %] > <li class="ill_checkout_branchcode"> >@@ -206,7 +206,7 @@ > [% ELSE %] > [% FOREACH branch IN whole.value.libraries.unblessed %] > [% IF branch.branchcode == branchcode %] >- [% branch.branchname %] >+ [% branch.branchname | html %] > [% END %] > [% END %] > [% END %] >@@ -225,8 +225,8 @@ > <input type="hidden" value="check_out" name="method"> > <input type="hidden" value="form" name="stage"> > [% IF items.size == 1 %] >- <input name="branchcode" type="hidden" value="[% branchcode %]"> >- <input name="item_type" type="hidden" value="[% items.0.itype %]"> >+ <input name="branchcode" type="hidden" value="[% branchcode | html %]"> >+ <input name="item_type" type="hidden" value="[% items.0.itype | html %]"> > [% END %] > <input type="hidden" value="[% request.illrequest_id | html %]" name="illrequest_id"> > <input type="submit" value="Submit"> >-- >2.11.0
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 23112
:
91987
|
91988
|
91989
|
91990
|
91991
|
92000
|
92001
|
92002
|
92003
|
92004
|
93530
|
93531
|
93532
|
93533
|
93534
|
93958
|
94264
|
94265
|
94266
|
94267
|
94268
|
94269
|
95565
|
95566
|
95567
|
95568
|
95569
|
95570
|
96834
|
96870
|
99910
|
99911
|
99912
|
99913
|
99914
|
99915
|
99916
|
99917
|
100100
|
100101
|
100102
|
100103
|
100104
|
100105
|
100106
|
100107
|
100108
|
100169
|
100224
|
100225
|
100252
|
100253
|
100254
|
100255
|
100256
|
100257
|
100258
|
100259
|
100260
|
100261
|
100262
|
100263