Bugzilla – Attachment 59421 Details for
Bug 15503
Grab Item Information from Order Files
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 15503 [QA Followup] - Use Koha::AuthorisedValues and fetch notforloan values.
Bug-15503-QA-Followup---Use-KohaAuthorisedValues-a.patch (text/plain), 4.05 KB, created by
Kyle M Hall (khall)
on 2017-01-23 14:05:11 UTC
(
hide
)
Description:
Bug 15503 [QA Followup] - Use Koha::AuthorisedValues and fetch notforloan values.
Filename:
MIME Type:
Creator:
Kyle M Hall (khall)
Created:
2017-01-23 14:05:11 UTC
Size:
4.05 KB
patch
obsolete
>From 8de2ed42f5392f51f1c8655c86bf37134dede5d9 Mon Sep 17 00:00:00 2001 >From: Matthias Meusburger <matthias.meusburger@biblibre.com> >Date: Mon, 12 Dec 2016 16:11:08 +0000 >Subject: [PATCH] Bug 15503 [QA Followup] - Use Koha::AuthorisedValues and > fetch notforloan values. > >--- > acqui/addorderiso2709.pl | 11 ++++++++--- > .../intranet-tmpl/prog/en/modules/acqui/addorderiso2709.tt | 12 +++++++++++- > 2 files changed, 19 insertions(+), 4 deletions(-) > >diff --git a/acqui/addorderiso2709.pl b/acqui/addorderiso2709.pl >index 042258c..ce57113 100755 >--- a/acqui/addorderiso2709.pl >+++ b/acqui/addorderiso2709.pl >@@ -467,8 +467,9 @@ sub import_biblios_list { > my @list = (); > my $item_error = 0; > >- my $ccodes = GetKohaAuthorisedValues("items.ccode"); >- my $locations = GetKohaAuthorisedValues("items.location"); >+ my $ccodes = { map { $_->{authorised_value} => $_->{opac_description} } Koha::AuthorisedValues->get_descriptions_by_koha_field( { frameworkcode => '', kohafield => 'items.ccode' } ) }; >+ my $locations = { map { $_->{authorised_value} => $_->{opac_description} } Koha::AuthorisedValues->get_descriptions_by_koha_field( { frameworkcode => '', kohafield => 'items.location' } ) }; >+ my $notforloans = { map { $_->{authorised_value} => $_->{lib} } Koha::AuthorisedValues->get_descriptions_by_koha_field( { frameworkcode => '', kohafield => 'items.notforloan' } ) }; > # location list > my @locations; > foreach (sort keys %$locations) { >@@ -478,7 +479,10 @@ sub import_biblios_list { > foreach (sort {$ccodes->{$a} cmp $ccodes->{$b}} keys %$ccodes) { > push @ccodes, { code => $_, description => $ccodes->{$_} }; > } >- >+ my @notforloans; >+ foreach (sort {$notforloans->{$a} cmp $notforloans->{$b}} keys %$notforloans) { >+ push @notforloans, { code => $_, description => $notforloans->{$_} }; >+ } > > my $biblio_count = 0; > foreach my $biblio (@$biblios) { >@@ -607,6 +611,7 @@ sub import_biblios_list { > locationloop => \@locations, > itypeloop => \@itypes, > ccodeloop => \@ccodes, >+ notforloanloop => \@notforloans, > ); > batch_info($template, $batch); > } >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 e718028..1a11bdc 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/addorderiso2709.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/addorderiso2709.tt >@@ -370,7 +370,17 @@ > </select> > </li> > >- <li><label for="notforloan_item_[% item.item_id %]">notforloan</label><input type="text" id="notforloan_item_[% item.item_id %]" name="notforloan_[% item.biblio_count %]" value="[% item.notforloan %]"></li> >+ <li> >+ <label for="notforloan_item_[% item.item_id %]">notforloan</label><select id="notforloan_item_[% item.item_id %]" name="notforloan_[% item.biblio_count %]"> >+ [% FOREACH n IN notforloanloop %] >+ [% IF n.code == item.notforloan %] >+ <option value="[% n.code %]" selected="selected">[% n.description %]</option> >+ [% ELSE %] >+ <option value="[% n.code %]">[% n.description %]</option> >+ [% END %] >+ [% END %] >+ </select> >+ </li> > <li><label for="uri_item_[% item.item_id %]">uri</label><input type="text" id="uri_item_[% item.item_id %]" name="uri_[% item.biblio_count %]" value="[% item.uri %]"></li> > <li><label for="copyno_item_[% item.item_id %]">copyno</label><input type="text" id="copyno_item_[% item.item_id %]" name="copyno_[% item.biblio_count %]" value="[% item.copyno %]"></li> > <li><label for="budget_code_item_[% item.item_id %]">budget_code</label><select id="budget_code_item_[% item.item_id %]" name="budget_code_[% item.biblio_count %]"> >-- >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 15503
:
53493
|
54480
|
54660
|
55057
|
55616
|
55617
|
55926
|
55927
|
55928
|
56851
|
56852
|
57123
|
57124
|
57125
|
57715
|
58103
|
58132
|
58164
|
58165
|
58166
|
58376
|
58377
|
59093
|
59097
|
59415
|
59416
|
59417
|
59418
|
59419
|
59420
|
59421
|
59515
|
60025
|
60026
|
60027
|
60028
|
60029
|
60030
|
60031
|
60032
|
60203
|
60204
|
60205
|
60206
|
60207
|
60208
|
60209
|
60210
|
60211