Bugzilla – Attachment 37101 Details for
Bug 9468
Add ability to hide itemtypes from purchase suggestions forms
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
[SIGNED-OFF] Bug 9468: [COUNTER-PATCH] define new SUGGEST_FORMAT authorize value
SIGNED-OFF-Bug-9468-COUNTER-PATCH-define-new-SUGGE.patch (text/plain), 2.06 KB, created by
Kyle M Hall (khall)
on 2015-03-23 10:56:00 UTC
(
hide
)
Description:
[SIGNED-OFF] Bug 9468: [COUNTER-PATCH] define new SUGGEST_FORMAT authorize value
Filename:
MIME Type:
Creator:
Kyle M Hall (khall)
Created:
2015-03-23 10:56:00 UTC
Size:
2.06 KB
patch
obsolete
>From 6aa4fa0d3f3363e439c2166a51650bccb8aa6aee Mon Sep 17 00:00:00 2001 >From: Galen Charlton <gmc@esilibrary.com> >Date: Mon, 5 May 2014 00:19:52 +0000 >Subject: [PATCH] [SIGNED-OFF] Bug 9468: [COUNTER-PATCH] define new SUGGEST_FORMAT authorize value > >This patch defines a new authorized called SUGGEST_FORMAT for >populating a list of patron-understandable formats for expressing >how they would prefer suggested items to be purchased. For >database upgrades, it populates it based on the value returned by the >GetSupportList() routine. > >To test >------- >[1] Run the database update. >[2] Verify that there is a new authorised value called SUGGEST_FORMAT > whose codes and descriptions correspond to the list of "item types" > available on the patron suggestion form. > >Signed-off-by: Galen Charlton <gmc@esilibrary.com> > >Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> >--- > installer/data/mysql/updatedatabase.pl | 15 +++++++++++++++ > 1 files changed, 15 insertions(+), 0 deletions(-) > >diff --git a/installer/data/mysql/updatedatabase.pl b/installer/data/mysql/updatedatabase.pl >index aa5bbbf..fc997f5 100755 >--- a/installer/data/mysql/updatedatabase.pl >+++ b/installer/data/mysql/updatedatabase.pl >@@ -37,6 +37,7 @@ use Getopt::Long; > use C4::Context; > use C4::Installer; > use C4::Dates; >+use C4::Koha qw/GetSupportList/; > > use MARC::Record; > use MARC::File::XML ( BinaryEncoding => 'utf8' ); >@@ -9867,6 +9868,20 @@ if(CheckVersion($DBversion)) { > SetVersion($DBversion); > } > >+$DBversion = "3.15.00.XXX"; >+if ( CheckVersion($DBversion) ) { >+ foreach my $format (@{ GetSupportList() }) { >+ $dbh->do( >+ q/INSERT INTO authorised_values (category, authorised_value, lib, lib_opac, imageurl) >+ VALUES (?, ?, ?, ?, ?)/, >+ {}, >+ 'SUGGEST_FORMAT', $format->{itemtype}, $format->{description}, $format->{description}, $format->{imageurl} >+ ); >+ } >+ print "Upgrade to $DBversion done (Bug 9468: create new SUGGEST_FORMAT authorised_value list)\n"; >+ SetVersion($DBversion); >+} >+ > =head1 FUNCTIONS > > =head2 TableExists($table) >-- >1.7.2.5
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 9468
:
14801
|
16647
|
16674
|
19086
|
21759
|
21760
|
22714
|
22715
|
27932
|
27933
|
27934
|
27935
|
37100
|
37101
|
37102
|
37103
|
38097
|
38163
|
38164
|
38165
|
38166
|
38167
|
38168
|
41822
|
41823
|
41824
|
41825
|
41826
|
41827
|
41828
|
41936
|
41937
|
41938
|
41939
|
41940
|
41941
|
41942
|
41943
|
44504
|
44505
|
44506
|
44507
|
44508
|
44509
|
44510