Bugzilla – Attachment 70108 Details for
Bug 19301
Move C4::Reserves::OnShelfHoldsAllowed to the Koha namespace
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 19301: (QA follow-up) Add POD, use statements and correct typo
Bug-19301-QA-follow-up-Add-POD-use-statements-and-.patch (text/plain), 2.39 KB, created by
Marcel de Rooy
on 2017-12-22 09:34:09 UTC
(
hide
)
Description:
Bug 19301: (QA follow-up) Add POD, use statements and correct typo
Filename:
MIME Type:
Creator:
Marcel de Rooy
Created:
2017-12-22 09:34:09 UTC
Size:
2.39 KB
patch
obsolete
>From 0d9187c700f4294bdf4219a96aed5c7be4a4427c Mon Sep 17 00:00:00 2001 >From: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> >Date: Fri, 22 Dec 2017 09:07:50 +0100 >Subject: [PATCH] Bug 19301: (QA follow-up) Add POD, use statements and correct > typo >Content-Type: text/plain; charset=utf-8 > >Add POD for new sub in Koha/IssuingRules.pm. >Adding use Koha::IssuingRules to opac-detail and opac-MARCdetail. >Adding use Koha::Items to opac-detail and opac-MARCdetail. >Correct typo $items => $item in opac-MARCdetail.pl. > >Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> >--- > Koha/IssuingRules.pm | 6 ++++++ > opac/opac-MARCdetail.pl | 4 +++- > opac/opac-detail.pl | 2 ++ > 3 files changed, 11 insertions(+), 1 deletion(-) > >diff --git a/Koha/IssuingRules.pm b/Koha/IssuingRules.pm >index ff40c1c..e0fffd1 100644 >--- a/Koha/IssuingRules.pm >+++ b/Koha/IssuingRules.pm >@@ -100,6 +100,12 @@ sub get_opacitemholds_policy { > return $issuing_rule ? $issuing_rule->opacitemholds : undef; > } > >+=head3 get_onshelfholds_policy >+ >+ my $on_shelf_holds = Koha::IssuingRules->get_onshelfholds_policy({ item => $item, patron => $patron }); >+ >+=cut >+ > sub get_onshelfholds_policy { > my ( $class, $params ) = @_; > my $item = $params->{item}; >diff --git a/opac/opac-MARCdetail.pl b/opac/opac-MARCdetail.pl >index 4c1735c..6969784 100755 >--- a/opac/opac-MARCdetail.pl >+++ b/opac/opac-MARCdetail.pl >@@ -58,6 +58,8 @@ use C4::Acquisition; > use C4::Koha; > use List::MoreUtils qw( any uniq ); > use Koha::Biblios; >+use Koha::IssuingRules; >+use Koha::Items; > use Koha::Patrons; > use Koha::RecordProcessor; > >@@ -132,7 +134,7 @@ if(my $cart_list = $query->cookie("bib_list")){ > my $allow_onshelf_holds; > my $patron = Koha::Patrons->find( $loggedinuser ); > for my $itm (@all_items) { >- my $items = Koha::Items->find( $itm->{itemnumber} ); >+ my $item = Koha::Items->find( $itm->{itemnumber} ); > $allow_onshelf_holds = Koha::IssuingRules->get_onshelfholds_policy( { item => $item, patron => $patron } ); > last if $allow_onshelf_holds; > } >diff --git a/opac/opac-detail.pl b/opac/opac-detail.pl >index 941f125..67c868b 100755 >--- a/opac/opac-detail.pl >+++ b/opac/opac-detail.pl >@@ -52,6 +52,8 @@ use C4::CourseReserves qw(GetItemCourseReservesInfo); > use Koha::Biblios; > use Koha::RecordProcessor; > use Koha::AuthorisedValues; >+use Koha::IssuingRules; >+use Koha::Items; > use Koha::ItemTypes; > use Koha::Acquisition::Orders; > use Koha::Virtualshelves; >-- >2.1.4
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 19301
:
67122
|
67123
|
67420
|
67421
|
69846
|
69847
|
70106
|
70107
| 70108 |
70109