View | Details | Raw Unified | Return to bug 15494
Collapse All | Expand All

(-)a/installer/data/mysql/atomicupdate/bug_15494.perl (+16 lines)
Line 0 Link Here
1
$DBversion = 'XXX';  # will be replaced by the RM
2
if( CheckVersion( $DBversion ) ) {
3
    # you can use $dbh here like:
4
    # $dbh->do( "ALTER TABLE biblio ADD COLUMN badtaste int" );
5
6
    $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')" );
7
8
    # or perform some test and warn
9
    # if( !column_exists( 'biblio', 'biblionumber' ) ) {
10
    #    warn "There is something wrong";
11
    # }
12
13
    # Always end with this (adjust the bug info)
14
    SetVersion( $DBversion );
15
    print "Upgrade to $DBversion done (Bug 15494 - Block renewals by arbitrary item values)\n";
16
}
(-)a/installer/data/mysql/sysprefs.sql (+1 lines)
Lines 236-241 INSERT INTO systempreferences ( `variable`, `value`, `options`, `explanation`, ` Link Here
236
('itemBarcodeFallbackSearch','',NULL,'If set, uses scanned item barcodes as a catalogue search if not found as barcodes','YesNo'),
236
('itemBarcodeFallbackSearch','',NULL,'If set, uses scanned item barcodes as a catalogue search if not found as barcodes','YesNo'),
237
('itemBarcodeInputFilter','','whitespace|T-prefix|cuecat|libsuite8|EAN13','If set, allows specification of a item barcode input filter','Choice'),
237
('itemBarcodeInputFilter','','whitespace|T-prefix|cuecat|libsuite8|EAN13','If set, allows specification of a item barcode input filter','Choice'),
238
('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'),
238
('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'),
239
('ItemsDeniedRenewal','','','This syspref allows to define custom rules for denying renewal of specific items.','Textarea'),
239
('KohaAdminEmailAddress','root@localhost','','Define the email address where patron modification requests are sent','free'),
240
('KohaAdminEmailAddress','root@localhost','','Define the email address where patron modification requests are sent','free'),
240
('LabelMARCView','standard','standard|economical','Define how a MARC record will display','Choice'),
241
('LabelMARCView','standard','standard|economical','Define how a MARC record will display','Choice'),
241
('language','en',NULL,'Set the default language in the staff client.','Languages'),
242
('language','en',NULL,'Set the default language in the staff client.','Languages'),
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/circulation.pref (-1 / +11 lines)
Lines 465-470 Circulation: Link Here
465
                  yes: Block
465
                  yes: Block
466
                  no: Allow
466
                  no: Allow
467
            - his/her auto renewals.
467
            - his/her auto renewals.
468
        -
469
            - pref: ItemsDeniedRenewal
470
              type: textarea
471
              class: code
472
            - Define custom rules to deny specific items from renewal.
473
            - "<br />Can name any field in the items table followed by a colon then a space then"
474
            - "a bracketed list of values separated by commas."
475
            - "e.g."
476
            - "<br />ccode: [NEWFIC,NULL,DVD]"
477
            - "<br />itype: [NEWBK,\"\"]"
478
            - "<br /> Note: the word 'NULL' can be used to block renewal on undefined fields, while an empty string \"\" will block on an empty (but defined) field."
468
    Checkin Policy:
479
    Checkin Policy:
469
        -
480
        -
470
            - pref: BlockReturnOfWithdrawnItems
481
            - pref: BlockReturnOfWithdrawnItems
471
- 

Return to bug 15494