Bugzilla – Attachment 63703 Details for
Bug 15494
Block renewals by arbitrary item values
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 15494 - Add syspref
Bug-15494---Add-syspref.patch (text/plain), 3.60 KB, created by
Nick Clemens (kidclamp)
on 2017-05-24 14:46:25 UTC
(
hide
)
Description:
Bug 15494 - Add syspref
Filename:
MIME Type:
Creator:
Nick Clemens (kidclamp)
Created:
2017-05-24 14:46:25 UTC
Size:
3.60 KB
patch
obsolete
>From f1a4b788c008e9b67ea8a1bb27efe035e10abb5f Mon Sep 17 00:00:00 2001 >From: Nick Clemens <nick@bywatersolutions.com> >Date: Wed, 24 May 2017 09:47:34 -0400 >Subject: [PATCH] Bug 15494 - Add syspref > >--- > installer/data/mysql/atomicupdate/bug_15494.perl | 16 ++++++++++++++++ > installer/data/mysql/sysprefs.sql | 1 + > .../prog/en/modules/admin/preferences/circulation.pref | 6 ++++++ > 3 files changed, 23 insertions(+) > create mode 100644 installer/data/mysql/atomicupdate/bug_15494.perl > >diff --git a/installer/data/mysql/atomicupdate/bug_15494.perl b/installer/data/mysql/atomicupdate/bug_15494.perl >new file mode 100644 >index 0000000..fbc7f3c >--- /dev/null >+++ b/installer/data/mysql/atomicupdate/bug_15494.perl >@@ -0,0 +1,16 @@ >+$DBversion = 'XXX'; # will be replaced by the RM >+if( CheckVersion( $DBversion ) ) { >+ # you can use $dbh here like: >+ # $dbh->do( "ALTER TABLE biblio ADD COLUMN badtaste int" ); >+ >+ $dbh->do( "INSERT IGNORE INTO systempreferences (variable,value,options,explanation,type) VALUES ('ItemsDeniedRenewal','','','This syspref allows to define custom rules for denying renewal of specific items.','Textarea')" ); >+ >+ # or perform some test and warn >+ # if( !column_exists( 'biblio', 'biblionumber' ) ) { >+ # warn "There is something wrong"; >+ # } >+ >+ # Always end with this (adjust the bug info) >+ SetVersion( $DBversion ); >+ print "Upgrade to $DBversion done (Bug 15494 - Block renewals by arbitrary item values)\n"; >+} >diff --git a/installer/data/mysql/sysprefs.sql b/installer/data/mysql/sysprefs.sql >index 0bd8cac..a200388 100644 >--- a/installer/data/mysql/sysprefs.sql >+++ b/installer/data/mysql/sysprefs.sql >@@ -229,6 +229,7 @@ INSERT INTO systempreferences ( `variable`, `value`, `options`, `explanation`, ` > ('itemBarcodeFallbackSearch','',NULL,'If set, uses scanned item barcodes as a catalogue search if not found as barcodes','YesNo'), > ('itemBarcodeInputFilter','','whitespace|T-prefix|cuecat|libsuite8|EAN13','If set, allows specification of a item barcode input filter','Choice'), > ('itemcallnumber','082ab',NULL,'The MARC field/subfield that is used to calculate the itemcallnumber (Dewey would be 082ab or 092ab; LOC would be 050ab or 090ab) could be 852hi from an item record','free'), >+('ItemsDeniedRenewal','','','This syspref allows to define custom rules for denying renewal of specific items.','Textarea'), > ('KohaAdminEmailAddress','root@localhost','','Define the email address where patron modification requests are sent','free'), > ('LabelMARCView','standard','standard|economical','Define how a MARC record will display','Choice'), > ('language','en',NULL,'Set the default language in the staff client.','Languages'), >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/circulation.pref b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/circulation.pref >index 90b2844..3aa7926 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/circulation.pref >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/circulation.pref >@@ -459,6 +459,12 @@ Circulation: > yes: Block > no: Allow > - his/her auto renewals. >+ - >+ - pref: ItemsDeniedRenewal >+ type: textarea >+ class: code >+ - Define custom rules to deny specific items from renewal. Uses same syntax as OpacHiddenItems. >+ - How to write these rules is documented on the <a href="http://wiki.koha-community.org/wiki/OpacHiddenItems" target="_blank">Koha wiki</a>. > Checkin Policy: > - > - pref: BlockReturnOfWithdrawnItems >-- >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 15494
:
63700
|
63701
|
63702
|
63703
|
67886
|
67887
|
67888
|
67889
|
68146
|
68147
|
68148
|
68149
|
70295
|
70629
|
70630
|
70631
|
70632
|
71129
|
71130
|
71131
|
71132
|
71133
|
71134
|
71135
|
71136
|
71137
|
71138
|
79249
|
79250
|
79251
|
79252
|
79253
|
79254
|
79293
|
80327
|
80328
|
80329
|
80330
|
80331
|
80332
|
80333
|
81411
|
81412
|
81413
|
81414
|
81415
|
81416
|
81417