@@ -, +, @@
- Repeat test plan from first patch
- Verfiy now the collection descrption shows
- Change column setting in administration
- Verify they work as expected
---
admin/columns_settings.yml | 6 +++---
koha-tmpl/intranet-tmpl/prog/en/includes/checkouts-table.inc | 2 +-
koha-tmpl/intranet-tmpl/prog/js/checkouts.js | 4 ++--
svc/checkouts | 9 +++++++--
4 files changed, 13 insertions(+), 8 deletions(-)
--- a/admin/columns_settings.yml
+++ a/admin/columns_settings.yml
@@ -230,7 +230,7 @@ modules:
-
columnname: item_type
-
- columnname: collection_code
+ columnname: collection
-
columnname: location
-
@@ -344,7 +344,7 @@ modules:
-
columnname: item_type
-
- columnname: collection_code
+ columnname: collection
-
columnname: location
-
@@ -405,7 +405,7 @@ modules:
-
columnname: title
-
- columnname: collection:
+ columnname: collection
-
columnname: document_type
-
--- a/koha-tmpl/intranet-tmpl/prog/en/includes/checkouts-table.inc
+++ a/koha-tmpl/intranet-tmpl/prog/en/includes/checkouts-table.inc
@@ -16,7 +16,7 @@
Due date |
Title |
Item type |
- Collection code |
+ Collection |
Location |
Home library |
Checked out on |
--- a/koha-tmpl/intranet-tmpl/prog/js/checkouts.js
+++ a/koha-tmpl/intranet-tmpl/prog/js/checkouts.js
@@ -291,7 +291,7 @@ $(document).ready(function() {
"sType": "anti-the"
},
{ "mDataProp": "itemtype_description" },
- { "mDataProp": "ccode" },
+ { "mDataProp": "collection" },
{ "mDataProp": "location" },
{ "mDataProp": "homebranch" },
{ "mDataProp": "issuedate_formatted" },
@@ -590,7 +590,7 @@ $(document).ready(function() {
"sType": "anti-the"
},
{ "mDataProp": "itemtype" },
- { "mDataProp": "ccode" },
+ { "mDataProp": "collection" },
{ "mDataProp": "location" },
{ "mDataProp": "issuedate_formatted" },
{ "mDataProp": "branchname" },
--- a/svc/checkouts
+++ a/svc/checkouts
@@ -90,7 +90,7 @@ my $sql = '
items.itype,
biblioitems.itemtype,
- items.ccode,
+ items.ccode AS collection,
borrowernumber,
surname,
@@ -156,6 +156,11 @@ while ( my $c = $sth->fetchrow_hashref() ) {
my $av = Koha::AuthorisedValues->search({ category => 'LOC', authorised_value => $c->{location} });
$location = $av->count ? $av->next->lib : '';
}
+ my $collection;
+ if ( $c->{collection} ) {
+ my $av = Koha::AuthorisedValues->search({ category => 'CCODE', authorised_value => $c->{collection} });
+ $collection = $av->count ? $av->next->lib : '';
+ }
my $lost;
if ( $c->{itemlost} ) {
my $av = Koha::AuthorisedValues->search({ category => 'LOST', authorised_value => $c->{itemlost} });
@@ -173,7 +178,7 @@ while ( my $c = $sth->fetchrow_hashref() ) {
barcode => $c->{barcode},
itemtype => $item_level_itypes ? $c->{itype} : $c->{itemtype},
itemtype_description => $itemtype ? $itemtype->translated_description : q{},
- ccode => $c->{ccode},
+ collection => $collection,
location => $location,
homebranch => $c->{homebranch},
itemnotes => $c->{itemnotes},
--