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

(-)a/installer/data/mysql/atomicupdate/bug_21280.perl (+12 lines)
Line 0 Link Here
1
2
$DBversion = 'XXX'; # will be replaced by the RM
3
if( CheckVersion( $DBversion ) ) {
4
    $dbh->do(q|
5
        INSERT IGNORE INTO systempreferences (`variable`, `value`, `options`, `explanation`, `type`) VALUES
6
            ('AuthorityMarcFieldDocURL', NULL, NULL, 'URL used for MARC authority record 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')
7
    |);
8
9
    # Always end with this (adjust the bug info)
10
    SetVersion( $DBversion );
11
    print "Upgrade to $DBversion done (Bug 21280 - Add AuthorityMarcFieldDocURL pref)\n";
12
}
(-)a/installer/data/mysql/sysprefs.sql (+1 lines)
Lines 59-64 INSERT INTO systempreferences ( `variable`, `value`, `options`, `explanation`, ` Link Here
59
('AuthDisplayHierarchy','0','','Display authority hierarchies','YesNo'),
59
('AuthDisplayHierarchy','0','','Display authority hierarchies','YesNo'),
60
('AuthoritiesLog','1',NULL,'If ON, log edit/create/delete actions on authorities.','YesNo'),
60
('AuthoritiesLog','1',NULL,'If ON, log edit/create/delete actions on authorities.','YesNo'),
61
('AuthorityControlledIndicators','# PERSO_NAME  100 600 696 700 796 800 896\nmarc21, 100, ind1:auth1\nmarc21, 600, ind1:auth1, ind2:thesaurus\nmarc21, 696, ind1:auth1\nmarc21, 700, ind1:auth1\nmarc21, 796, ind1:auth1\nmarc21, 800, ind1:auth1\nmarc21, 896, ind1:auth1\n# CORPO_NAME  110 610 697 710 797 810 897\nmarc21, 110, ind1:auth1\nmarc21, 610, ind1:auth1, ind2:thesaurus\nmarc21, 697, ind1:auth1\nmarc21, 710, ind1:auth1\nmarc21, 797, ind1:auth1\nmarc21, 810, ind1:auth1\nmarc21, 897, ind1:auth1\n# MEETI_NAME    111 611 698 711 798 811 898\nmarc21, 111, ind1:auth1\nmarc21, 611, ind1:auth1, ind2:thesaurus\nmarc21, 698, ind1:auth1\nmarc21, 711, ind1:auth1\nmarc21, 798, ind1:auth1\nmarc21, 811, ind1:auth1\nmarc21, 898, ind1:auth1\n# UNIF_TITLE        130 440 630 699 730 799 830 899\nmarc21, 130, ind1:auth2\nmarc21, 240, , ind2:auth2\nmarc21, 440, , ind2:auth2\nmarc21, 630, ind1:auth2, ind2:thesaurus\nmarc21, 699, ind1:auth2\nmarc21, 730, ind1:auth2\nmarc21, 799, ind1:auth2\nmarc21, 830, , ind2:auth2\nmarc21, 899, ind1:auth2\n# CHRON_TERM    648 \nmarc21, 648, , ind2:thesaurus\n# TOPIC_TERM      650 654 656 657 658 690\nmarc21, 650, , ind2:thesaurus\n# GEOGR_NAME   651 662 691\nmarc21, 651, , ind2:thesaurus\n# GENRE/FORM    655 \nmarc21, 655, , ind2:thesaurus\n\n# UNIMARC: Always copy the indicators from the authority\nunimarc, *, ind1:auth1, ind2:auth2',NULL,'Authority controlled indicators per biblio field','Free'),
61
('AuthorityControlledIndicators','# PERSO_NAME  100 600 696 700 796 800 896\nmarc21, 100, ind1:auth1\nmarc21, 600, ind1:auth1, ind2:thesaurus\nmarc21, 696, ind1:auth1\nmarc21, 700, ind1:auth1\nmarc21, 796, ind1:auth1\nmarc21, 800, ind1:auth1\nmarc21, 896, ind1:auth1\n# CORPO_NAME  110 610 697 710 797 810 897\nmarc21, 110, ind1:auth1\nmarc21, 610, ind1:auth1, ind2:thesaurus\nmarc21, 697, ind1:auth1\nmarc21, 710, ind1:auth1\nmarc21, 797, ind1:auth1\nmarc21, 810, ind1:auth1\nmarc21, 897, ind1:auth1\n# MEETI_NAME    111 611 698 711 798 811 898\nmarc21, 111, ind1:auth1\nmarc21, 611, ind1:auth1, ind2:thesaurus\nmarc21, 698, ind1:auth1\nmarc21, 711, ind1:auth1\nmarc21, 798, ind1:auth1\nmarc21, 811, ind1:auth1\nmarc21, 898, ind1:auth1\n# UNIF_TITLE        130 440 630 699 730 799 830 899\nmarc21, 130, ind1:auth2\nmarc21, 240, , ind2:auth2\nmarc21, 440, , ind2:auth2\nmarc21, 630, ind1:auth2, ind2:thesaurus\nmarc21, 699, ind1:auth2\nmarc21, 730, ind1:auth2\nmarc21, 799, ind1:auth2\nmarc21, 830, , ind2:auth2\nmarc21, 899, ind1:auth2\n# CHRON_TERM    648 \nmarc21, 648, , ind2:thesaurus\n# TOPIC_TERM      650 654 656 657 658 690\nmarc21, 650, , ind2:thesaurus\n# GEOGR_NAME   651 662 691\nmarc21, 651, , ind2:thesaurus\n# GENRE/FORM    655 \nmarc21, 655, , ind2:thesaurus\n\n# UNIMARC: Always copy the indicators from the authority\nunimarc, *, ind1:auth1, ind2:auth2',NULL,'Authority controlled indicators per biblio field','Free'),
62
('AuthorityMarcFieldDocURL', NULL, NULL, 'URL used for MARC authority record 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'),
62
('AuthorityMergeLimit','50',NULL,'Maximum number of biblio records updated immediately when an authority record has been modified.','integer'),
63
('AuthorityMergeLimit','50',NULL,'Maximum number of biblio records updated immediately when an authority record has been modified.','integer'),
63
('AuthorityMergeMode','loose','loose|strict','Authority merge mode','Choice'),
64
('AuthorityMergeMode','loose','loose|strict','Authority merge mode','Choice'),
64
('AuthoritySeparator','--','10','Used to separate a list of authorities in a display. Usually --','free'),
65
('AuthoritySeparator','--','10','Used to separate a list of authorities in a display. Usually --','free'),
(-)a/koha-tmpl/intranet-tmpl/prog/en/includes/marc_editor.inc (-2 / +2 lines)
Lines 42-49 $(document).ready(function() { Link Here
42
});
42
});
43
43
44
function PopupMARCFieldDoc(field) {
44
function PopupMARCFieldDoc(field) {
45
    [% IF Koha.Preference('marcfielddocurl') %]
45
    [% IF Koha.Preference(doc_url_pref) %]
46
        var docurl = "[% Koha.Preference('marcfielddocurl').replace('"','"') | html %]";
46
        var docurl = "[% Koha.Preference(doc_url_pref).replace('"','"') | html %]";
47
        docurl = docurl.replace("{MARC}", "[% marcflavour | html %]");
47
        docurl = docurl.replace("{MARC}", "[% marcflavour | html %]");
48
        docurl = docurl.replace("{FIELD}", ""+field);
48
        docurl = docurl.replace("{FIELD}", ""+field);
49
        docurl = docurl.replace("{LANG}", "[% lang | html %]");
49
        docurl = docurl.replace("{LANG}", "[% lang | html %]");
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/authorities.pref (+8 lines)
Lines 63-68 Authorities: Link Here
63
                  "loose": loose
63
                  "loose": loose
64
                  "strict": strict
64
                  "strict": strict
65
            - mode. In strict mode subfields that are not found in the authority record, are deleted. Loose mode will keep them. Loose mode is the historical behavior and still the default.
65
            - mode. In strict mode subfields that are not found in the authority record, are deleted. Loose mode will keep them. Loose mode is the historical behavior and still the default.
66
        -
67
            - Use
68
            - pref: AuthorityMarcFieldDocURL
69
              class: url
70
            - as the URL for MARC authority record field documentation.
71
            - 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").
72
            - If left empty, the format documentation on http://loc.gov (MARC21) or http://archive.ifla.org (UNIMARC) is used.
73
            - For example <tt>http://fielddoc.example.com/?marc={MARC}&field={FIELD}&language={LANG}</tt>
66
74
67
    Linker:
75
    Linker:
68
        -
76
        -
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/authorities/authorities.tt (-1 / +1 lines)
Lines 159-165 function confirmnotdup(redirect){ Link Here
159
        </div>
159
        </div>
160
    </div>
160
    </div>
161
161
162
    [% INCLUDE 'marc_editor.inc' maindiv='authoritytabs' marc21_doc_base='http://www.loc.gov/marc/authority/ad' unimarc_doc_base='https://www.ifla.org/publications/unimarc-authorities--3rd-edition--updates' %]
162
    [% INCLUDE 'marc_editor.inc' maindiv='authoritytabs' marc21_doc_base='http://www.loc.gov/marc/authority/ad' unimarc_doc_base='https://www.ifla.org/publications/unimarc-authorities--3rd-edition--updates' doc_url_pref='AuthorityMarcFieldDocURL' %]
163
163
164
[% IF ( oldauthnumtagfield ) %]
164
[% IF ( oldauthnumtagfield ) %]
165
    <input type="hidden" name="tag" value="[% oldauthnumtagfield | html %]" />
165
    <input type="hidden" name="tag" value="[% oldauthnumtagfield | html %]" />
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/addbiblio.tt (-2 / +1 lines)
Lines 336-342 function Changefwk() { Link Here
336
        <input type="hidden" name="breedingid" value="[% breedingid | html %]" />
336
        <input type="hidden" name="breedingid" value="[% breedingid | html %]" />
337
        <input type="hidden" name="changed_framework" value="" />
337
        <input type="hidden" name="changed_framework" value="" />
338
338
339
    [% INCLUDE 'marc_editor.inc' maindiv='addbibliotabs' marc21_doc_base='http://www.loc.gov/marc/bibliographic/bd' unimarc_doc_base='https://www.ifla.org/publications/unimarc-bibliographic--3rd-edition--updates-2012-and-updates-2016' %]
339
    [% INCLUDE 'marc_editor.inc' maindiv='addbibliotabs' marc21_doc_base='http://www.loc.gov/marc/bibliographic/bd' unimarc_doc_base='https://www.ifla.org/publications/unimarc-bibliographic--3rd-edition--updates-2012-and-updates-2016' doc_url_pref='MarcFieldDocURL' %]
340
340
341
[%# Fields for fast cataloging %]
341
[%# Fields for fast cataloging %]
342
<input type="hidden" name="barcode" value="[% barcode | html %]" />
342
<input type="hidden" name="barcode" value="[% barcode | html %]" />
343
- 

Return to bug 21280