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

(-)a/cataloguing/addbiblio.pl (+1 lines)
Lines 982-987 if ( $record ne '-1' ) { Link Here
982
    $template->param( title => $title );
982
    $template->param( title => $title );
983
}
983
}
984
$template->param(
984
$template->param(
985
    marcfielddocurl => C4::Context->preference("MarcFieldDocURL"),
985
    popup => $mode,
986
    popup => $mode,
986
    frameworkcode => $frameworkcode,
987
    frameworkcode => $frameworkcode,
987
    itemtype => $frameworkcode,
988
    itemtype => $frameworkcode,
(-)a/installer/data/mysql/sysprefs.sql (+1 lines)
Lines 201-206 INSERT INTO systempreferences ( `variable`, `value`, `options`, `explanation`, ` Link Here
201
('MARCAuthorityControlField008','|| aca||aabn           | a|a     d',NULL,'Define the contents of MARC21 authority control field 008 position 06-39','Textarea'),
201
('MARCAuthorityControlField008','|| aca||aabn           | a|a     d',NULL,'Define the contents of MARC21 authority control field 008 position 06-39','Textarea'),
202
('MarcFieldsToOrder','',NULL,'Set the mapping values for a new order line created from a MARC record in a staged file. In a YAML format.','textarea'),
202
('MarcFieldsToOrder','',NULL,'Set the mapping values for a new order line created from a MARC record in a staged file. In a YAML format.','textarea'),
203
('MARCOrgCode','OSt','','Define MARC Organization Code for MARC21 records - http://www.loc.gov/marc/organizations/orgshome.html','free'),
203
('MARCOrgCode','OSt','','Define MARC Organization Code for MARC21 records - http://www.loc.gov/marc/organizations/orgshome.html','free'),
204
('MarcFieldDocURL', NULL, NULL, 'URL used for MARC field documentation. Following substitutions are available: {MARC} = marc flavour, eg. "MARC21" or "UNIMARC". {FIELD} = field number, eg. "000" or "048". {LANG} = user language, eg. "en" or "fi-FI"', 'free'),
204
('MaxFine',NULL,'','Maximum fine a patron can have for all late returns at one moment. Single item caps are specified in the circulation rules matrix.','Integer'),
205
('MaxFine',NULL,'','Maximum fine a patron can have for all late returns at one moment. Single item caps are specified in the circulation rules matrix.','Integer'),
205
('MaxItemsForBatch','1000',NULL,'Max number of items record to process in a batch (modification or deletion)','Integer'),
206
('MaxItemsForBatch','1000',NULL,'Max number of items record to process in a batch (modification or deletion)','Integer'),
206
('maxItemsInSearchResults','20',NULL,'Specify the maximum number of items to display for each result on a page of results','free'),
207
('maxItemsInSearchResults','20',NULL,'Specify the maximum number of items to display for each result on a page of results','free'),
(-)a/installer/data/mysql/updatedatabase.pl (+12 lines)
Lines 10628-10633 foreach my $file ( sort readdir $dirh ) { Link Here
10628
    }
10628
    }
10629
}
10629
}
10630
10630
10631
10632
$DBversion = "3.21.00.XXX";
10633
if ( CheckVersion($DBversion) ) {
10634
   $dbh->do("
10635
       INSERT INTO systempreferences (variable,value,options,explanation,type)
10636
       VALUES ('MarcFieldDocURL', NULL, NULL, 'URL used for MARC field documentation. Following substitutions are available: {MARC} = marc flavour, eg. \"MARC21\" or \"UNIMARC\". {FIELD} = field number, eg. \"000\" or \"048\". {LANG} = user language, eg. \"en\" or \"fi-FI\"', 'free');
10637
    ");
10638
   print "Upgrade to $DBversion done (Bug 11674: Configuration for MARC field doc URLs)\n";
10639
   SetVersion ($DBversion);
10640
}
10641
10642
10631
=head1 FUNCTIONS
10643
=head1 FUNCTIONS
10632
10644
10633
=head2 TableExists($table)
10645
=head2 TableExists($table)
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/cataloguing.pref (+7 lines)
Lines 142-147 Cataloging: Link Here
142
                  no: "Don't use"
142
                  no: "Don't use"
143
            - record control number ($w subfields) and control number (001) for linking of bibliographic records.
143
            - record control number ($w subfields) and control number (001) for linking of bibliographic records.
144
        -
144
        -
145
            - Use
146
            - pref: MarcFieldDocURL
147
            - as the URL for MARC field documentation.
148
            - Possible substitutions are <tt>{MARC}</tt> (marc flavour, eg. "MARC21" or "UNIMARC"), <tt>{FIELD}</tt> (field number, eg. "000" or "048"), <tt>{LANG}</tt> (user language, eg. "en" or "fi-FI").
149
            - If left empty, the format documentation on http://loc.gov (MARC21) or http://archive.ifla.org (UNIMARC) is used.
150
            - For example <tt>http://fielddoc.example.com/?marc={MARC}&field={FIELD}&language={LANG}</tt>
151
        -
145
            - pref: hide_marc
152
            - pref: hide_marc
146
              choices:
153
              choices:
147
                  yes: "Don't display"
154
                  yes: "Don't display"
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/addbiblio.tt (-2 / +7 lines)
Lines 140-146 function PopupZ3950() { Link Here
140
}
140
}
141
141
142
function PopupMARCFieldDoc(field) {
142
function PopupMARCFieldDoc(field) {
143
    [% IF ( marcflavour == 'MARC21' ) %]
143
    [% IF (marcfielddocurl) %]
144
        var docurl = "[% marcfielddocurl.replace('"','&quot;') %]";
145
        docurl = docurl.replace("{MARC}", "[% marcflavour %]");
146
        docurl = docurl.replace("{FIELD}", ""+field);
147
        docurl = docurl.replace("{LANG}", "[% lang %]");
148
        window.open(docurl);
149
    [% ELSIF ( marcflavour == 'MARC21' ) %]
144
        _MARC21FieldDoc(field);
150
        _MARC21FieldDoc(field);
145
    [% ELSIF ( marcflavour == 'UNIMARC' ) %]
151
    [% ELSIF ( marcflavour == 'UNIMARC' ) %]
146
        _UNIMARCFieldDoc(field);
152
        _UNIMARCFieldDoc(field);
147
- 

Return to bug 11674