From edc3331c47384faf8b680b2f1f0c5d1b87098515 Mon Sep 17 00:00:00 2001 From: Meenakshi.R Date: Fri, 1 Jun 2012 14:00:45 +0530 Subject: [PATCH] Bug 7570 - Add Item availability status to cart Added item availability Status to cart in OPAC interface. Changes: -C4/Items.pm to get the items status in GetItemsLocationInfo. -koha-tmpl/opac-tmpl/prog/en/modules/opac-basket.tt to show status. To Test: Add some of the records in t into cart and click on cart. It will display Status along with Title,Author,Location. --- C4/Items.pm | 2 +- koha-tmpl/opac-tmpl/prog/en/modules/opac-basket.tt | 2 ++ 2 files changed, 3 insertions(+), 1 deletions(-) diff --git a/C4/Items.pm b/C4/Items.pm index a6d5a22..6b7d0d1 100644 --- a/C4/Items.pm +++ b/C4/Items.pm @@ -1389,7 +1389,7 @@ sub GetItemsLocationInfo { my @results; my $dbh = C4::Context->dbh; - my $query = "SELECT a.branchname as homebranch, b.branchname as holdingbranch, + my $query = "SELECT items.*,a.branchname as homebranch, b.branchname as holdingbranch, location, itemcallnumber, cn_sort FROM items, branches as a, branches as b WHERE homebranch = a.branchcode AND holdingbranch = b.branchcode diff --git a/koha-tmpl/opac-tmpl/prog/en/modules/opac-basket.tt b/koha-tmpl/opac-tmpl/prog/en/modules/opac-basket.tt index c4d40ed..ec7760c 100644 --- a/koha-tmpl/opac-tmpl/prog/en/modules/opac-basket.tt +++ b/koha-tmpl/opac-tmpl/prog/en/modules/opac-basket.tt @@ -354,6 +354,7 @@ function enableCheckboxActions(){ Author Year Location + Status [% FOREACH BIBLIO_RESULT IN BIBLIO_RESULTS %] @@ -390,6 +391,7 @@ function enableCheckboxActions(){ [% END %] [% END %][% ELSE %]This record has no items.[% END %] + [% INCLUDE 'item-status.inc' item = ITEM_RESULT %] [% END %] -- 1.7.1