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

(-)a/koha-tmpl/intranet-tmpl/prog/css/addbiblio.css (-15 lines)
Lines 6-27 div#toolbar { Link Here
6
    border: 0;
6
    border: 0;
7
}
7
}
8
8
9
#addbibliotabs .ui-tabs-nav {
10
    display: none;
11
}
12
13
.tab-content {
9
.tab-content {
14
    border: 0;
10
    border: 0;
15
    padding: 0;
11
    padding: 0;
16
}
12
}
17
13
18
.ui-tabs-panel h3,
19
.tab-pane h3 {
14
.tab-pane h3 {
20
    font-size: 140%;
15
    font-size: 140%;
21
    margin: .3em 0;
16
    margin: .3em 0;
22
}
17
}
23
18
24
.ui-tabs-panel ul,
25
.tab-pane ul {
19
.tab-pane ul {
26
    margin-bottom: 0;
20
    margin-bottom: 0;
27
    padding-left: 0;
21
    padding-left: 0;
Lines 276-286 tbody tr.active td { Link Here
276
    width: 15em;
270
    width: 15em;
277
}
271
}
278
272
279
.ui-tabs .ui-tabs-panel {
280
    border: 0;
281
    padding: 0;
282
}
283
284
.toolbar-tabs-container {
273
.toolbar-tabs-container {
285
    margin: 3em -5px -5px -5px;
274
    margin: 3em -5px -5px -5px;
286
}
275
}
Lines 461-467 tbody tr.active td { Link Here
461
    padding: 0;
450
    padding: 0;
462
}
451
}
463
452
464
#authoritiestabs .ui-tabs-nav.ui-widget-header {
465
    border-bottom: 1px solid #b9d8d9;
466
    border-radius: 0;
467
}
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/addbiblio.tt (-195 / +205 lines)
Lines 32-52 Link Here
32
            $("#toolbar").hide();
32
            $("#toolbar").hide();
33
        [% END %]
33
        [% END %]
34
34
35
        var $tabs = $('#addbibliotabs').tabs().bind('show.ui-tabs', function(e, ui) {
35
        $("a[data-toggle='tab']").on("shown.bs.tab", function (e) {
36
            $("#"+ui.panel.id+" input:eq(0)").focus();
36
            $( e.target.hash + " .input_marceditor:visible:eq(0)").focus();
37
        });
37
        });
38
        $( "ul.sortable_field", $tabs ).sortable({
38
39
        /* On page load, check for location.hash in the page URL */
40
        /* If present the location hash will be used to activate the correct tab */
41
        var hash = location.hash;
42
        var hashPieces = hash.split('?');
43
        if( hashPieces[0] !== "" ){
44
            selectTab( hashPieces[0] );
45
            window.scrollTo( 0, 0 );
46
        }
47
48
        $( "ul.sortable_field", "#addbibliotabs" ).sortable({
39
            axis: "y",
49
            axis: "y",
40
            containment: $("#addbibliotabs")
50
            containment: $("#addbibliotabs")
41
        });
51
        });
42
        $( "ul.sortable_subfield", $tabs ).sortable({
52
        $( "ul.sortable_subfield", "#addbibliotabs" ).sortable({
43
            axis: "y",
53
            axis: "y",
44
            containment: "parent"
54
            containment: "parent"
45
        });
55
        });
46
56
47
        [% IF tab %]
57
        [% IF tab %]
48
            link = $("a[href='#[% tab | html %]']");
58
            hash = "#[% tab | html %]";
49
            selectTab( link );
59
            selectTab( hash );
50
        [% END %]
60
        [% END %]
51
61
52
        Sticky = $("#toolbar");
62
        Sticky = $("#toolbar");
Lines 151-157 Link Here
151
161
152
        $(".toolbar-tabs a").on("click",function(e){
162
        $(".toolbar-tabs a").on("click",function(e){
153
            e.preventDefault();
163
            e.preventDefault();
154
            selectTab( $(this ) );
164
            selectTab( this.hash );
155
        });
165
        });
156
166
157
        $(".tag_anchor").on("click", function(e){
167
        $(".tag_anchor").on("click", function(e){
Lines 179-188 Link Here
179
    });
189
    });
180
190
181
    function selectTab( tablink ){
191
    function selectTab( tablink ){
192
        let a = $("a[href='" + tablink + "']");
182
        $(".toolbar-tabs li").removeClass("selected");
193
        $(".toolbar-tabs li").removeClass("selected");
183
        tablink.parent().addClass("selected");
194
        a.tab("show").parent().addClass("selected");
184
        var tabid = tablink.data("tabid");
195
        var tabid = a.data("tabid");
185
        $('#addbibliotabs').selectTabByID("#tab" + tabid + "XX");
186
        $(".tag_anchors").removeClass("tab_selected").hide();
196
        $(".tag_anchors").removeClass("tab_selected").hide();
187
        $(".tag_anchors_" + tabid ).addClass("tab_selected").show();
197
        $(".tag_anchors_" + tabid ).addClass("tab_selected").show();
188
    }
198
    }
Lines 950-963 function PopupMARCFieldDoc(field) { Link Here
950
                    [% END # /UNLESS circborrowernumber %]
960
                    [% END # /UNLESS circborrowernumber %]
951
                    <div class="toolbar-tabs-container">
961
                    <div class="toolbar-tabs-container">
952
                        [% IF ( BIG_LOOP && BIG_LOOP.size > 1 ) %]
962
                        [% IF ( BIG_LOOP && BIG_LOOP.size > 1 ) %]
953
                            <ul class="toolbar-tabs">
963
                            <ul class="toolbar-tabs" role="tablist">
954
                                [%- FOREACH BIG_LOO IN BIG_LOOP -%]
964
                                [%- FOREACH BIG_LOO IN BIG_LOOP -%]
955
                                    [% IF loop.first %]
965
                                    [% IF loop.first %]
956
                                        <li class="selected">
966
                                        <li role="presentation" class="active selected">
957
                                    [% ELSE %]
967
                                    [% ELSE %]
958
                                        <li>
968
                                        <li role="presentation">
959
                                    [% END %]
969
                                    [% END %]
960
                                        <a data-tabid="[% BIG_LOO.number | html %]" href="#tab[% BIG_LOO.number | html %]XX">[% BIG_LOO.number | html %]</a>
970
                                        <a data-tabid="[% BIG_LOO.number | html %]" href="#tab[% BIG_LOO.number | html %]XX" aria-controls="#tab[% BIG_LOO.number | html %]XX" role="tab" data-toggle="tab">[% BIG_LOO.number | html %]</a>
961
                                    </li>
971
                                    </li>
962
                                [%- END -%]
972
                                [%- END -%]
963
                            </ul>
973
                            </ul>
Lines 995-1199 function PopupMARCFieldDoc(field) { Link Here
995
                <input type="hidden" name="changed_framework" value="" />
1005
                <input type="hidden" name="changed_framework" value="" />
996
1006
997
                <div id="addbibliotabs" class="toptabs numbered">
1007
                <div id="addbibliotabs" class="toptabs numbered">
998
                    <ul>
1008
                    <div class="tab-content">
999
                        [% FOREACH BIG_LOO IN BIG_LOOP %]
1000
                            <li><a href="#tab[% BIG_LOO.number | uri %]XX">[% BIG_LOO.number | html %]</a></li>
1001
                        [% END %]
1002
                    </ul>
1003
1004
                    [% FOREACH BIG_LOO IN BIG_LOOP %]
1005
                        <div id="tab[% BIG_LOO.number | html %]XX">
1006
1009
1007
                            [% IF ( BIG_LOOP.size > 1 ) %]
1010
                        [% FOREACH BIG_LOO IN BIG_LOOP %]
1008
                                <h3>Section [% BIG_LOO.number | html %]</h3>
1011
                            [% IF loop.first %]
1012
                                <div id="tab[% BIG_LOO.number | html %]XX" role="tabpanel" class="tab-pane active">
1013
                            [% ELSE %]
1014
                                <div id="tab[% BIG_LOO.number | html %]XX" role="tabpanel" class="tab-pane">
1009
                            [% END %]
1015
                            [% END %]
1010
                            [% previous = "" %]
1016
1011
                            [% FOREACH innerloo IN BIG_LOO.innerloop %]
1017
                                [% IF ( BIG_LOOP.size > 1 ) %]
1012
                                [% IF ( innerloo.tag ) %]
1018
                                    <h3>Section [% BIG_LOO.number | html %]</h3>
1013
                                [% IF innerloo.tag != previous %]
1014
                                    [% IF previous != "" %]
1015
                                        </ul>
1016
                                    [% END %]
1017
                                    [% previous = innerloo.tag %]
1018
                                    [% IF ( innerloo.repeatable ) %]
1019
                                        <ul class="sortable_field">
1020
                                    [% ELSE %]
1021
                                        <ul>
1022
                                    [% END %]
1023
                                [% END %]
1019
                                [% END %]
1024
                                    [% IF ( innerloo.repeatable ) %]
1020
                                [% previous = "" %]
1025
                                        <li class="tag sortable_tag clearfix" id="tag_[% innerloo.tag | html %]_[% innerloo.index | html %][% innerloo.random | html %]">
1021
                                [% FOREACH innerloo IN BIG_LOO.innerloop %]
1026
                                    [% ELSE %]
1022
                                    [% IF ( innerloo.tag ) %]
1027
                                        <li class="tag clearfix" id="tag_[% innerloo.tag | html %]_[% innerloo.index | html %][% innerloo.random | html %]">
1023
                                    [% IF innerloo.tag != previous %]
1024
                                        [% IF previous != "" %]
1025
                                            </ul>
1026
                                        [% END %]
1027
                                        [% previous = innerloo.tag %]
1028
                                        [% IF ( innerloo.repeatable ) %]
1029
                                            <ul class="sortable_field">
1030
                                        [% ELSE %]
1031
                                            <ul>
1032
                                        [% END %]
1028
                                    [% END %]
1033
                                    [% END %]
1029
                                        <div class="tag_title" id="div_indicator_tag_[% innerloo.tag | html %]_[% innerloo.index | html %][% innerloo.random | html %]">
1034
                                        [% IF ( innerloo.repeatable ) %]
1030
                                            [% IF advancedMARCEditor %]
1035
                                            <li class="tag sortable_tag clearfix" id="tag_[% innerloo.tag | html %]_[% innerloo.index | html %][% innerloo.random | html %]">
1031
                                                <a href="#" tabindex="1" class="tagnum" title="[% innerloo.tag_lib | html %] - Click to Expand this Tag" onclick="ExpandField('tag_[% innerloo.tag | html %]_[% innerloo.index | html %][% innerloo.random | html %]'); return false;">[% innerloo.tag | html %]</a>
1036
                                        [% ELSE %]
1032
                                            [% ELSE %]
1037
                                            <li class="tag clearfix" id="tag_[% innerloo.tag | html %]_[% innerloo.index | html %][% innerloo.random | html %]">
1033
                                                <span class="tagnum" title="[% innerloo.tag_lib | html %]">[% innerloo.tag | html %]</span>
1038
                                        [% END %]
1034
                                                <a href="#" class="marcdocs" onclick="PopupMARCFieldDoc('[% innerloo.tag | html %]'); return false;">&nbsp;?</a>
1039
                                            <div class="tag_title" id="div_indicator_tag_[% innerloo.tag | html %]_[% innerloo.index | html %][% innerloo.random | html %]">
1035
                                            [% END %]
1040
                                                [% IF advancedMARCEditor %]
1036
1041
                                                    <a href="#" tabindex="1" class="tagnum" title="[% innerloo.tag_lib | html %] - Click to Expand this Tag" onclick="ExpandField('tag_[% innerloo.tag | html %]_[% innerloo.index | html %][% innerloo.random | html %]'); return false;">[% innerloo.tag | html %]</a>
1037
                                            [% IF ( innerloo.fixedfield ) %]
1042
                                                [% ELSE %]
1038
                                                <input type="text"
1043
                                                    <span class="tagnum" title="[% innerloo.tag_lib | html %]">[% innerloo.tag | html %]</span>
1039
                                                    tabindex="1"
1044
                                                    <a href="#" class="marcdocs" onclick="PopupMARCFieldDoc('[% innerloo.tag | html %]'); return false;">&nbsp;?</a>
1040
                                                    class="indicator flat"
1041
                                                    style="display:none;"
1042
                                                    name="tag_[% innerloo.tag | html %]_indicator1_[% innerloo.index | html %][% innerloo.random | html %]"
1043
                                                    size="1"
1044
                                                    maxlength="1"
1045
                                                    value="[% innerloo.indicator1 | html %]" />
1046
                                                <input type="text"
1047
                                                    tabindex="1"
1048
                                                    class="indicator flat"
1049
                                                    style="display:none;"
1050
                                                    name="tag_[% innerloo.tag | html %]_indicator2_[% innerloo.index | html %][% innerloo.random | html %]"
1051
                                                    size="1"
1052
                                                    maxlength="1"
1053
                                                    value="[% innerloo.indicator2 | html %]" />
1054
                                            [% ELSE %]
1055
                                                <input type="text"
1056
                                                    tabindex="1"
1057
                                                    class="indicator flat"
1058
                                                    name="tag_[% innerloo.tag | html %]_indicator1_[% innerloo.index | html %][% innerloo.random | html %]"
1059
                                                    size="1"
1060
                                                    maxlength="1"
1061
                                                    value="[% innerloo.indicator1 | html %]" />
1062
                                                <input type="text"
1063
                                                    tabindex="1"
1064
                                                    class="indicator flat"
1065
                                                    name="tag_[% innerloo.tag | html %]_indicator2_[% innerloo.index | html %][% innerloo.random | html %]"
1066
                                                    size="1"
1067
                                                    maxlength="1"
1068
                                                    value="[% innerloo.indicator2 | html %]" />
1069
                                            [% END # /IF innerloo.fixedfield %] -
1070
1071
                                            [% UNLESS advancedMARCEditor %]
1072
                                                <a href="#" tabindex="1" class="expandfield" onclick="ExpandField('tag_[% innerloo.tag | html %]_[% innerloo.index | html %][% innerloo.random | html %]'); return false;" title="Click to Expand this Tag">[% innerloo.tag_lib | html %]</a>
1073
                                            [% END %]
1074
1075
                                            <span class="field_controls">
1076
                                                [% IF ( innerloo.repeatable ) %]
1077
                                                    <a href="#" tabindex="1" class="buttonPlus" onclick="CloneField('tag_[% innerloo.tag | html %]_[% innerloo.index | html %][% innerloo.random | html %]','0','[% advancedMARCEditor | html %]'); return false;" title="Repeat this Tag">
1078
                                                        <img src="[% interface | html %]/[% theme | html %]/img/repeat-tag.png" alt="Repeat this Tag" />
1079
                                                    </a>
1080
                                                [% END %]
1045
                                                [% END %]
1081
                                                <a href="#" tabindex="1" class="buttonMinus" onclick="UnCloneField('tag_[% innerloo.tag | html %]_[% innerloo.index | html %][% innerloo.random | html %]'); return false;" title="Delete this Tag">
1046
1082
                                                    <img src="[% interface | html %]/[% theme | html %]/img/delete-tag.png" alt="Delete this Tag" />
1047
                                                [% IF ( innerloo.fixedfield ) %]
1083
                                                </a>
1048
                                                    <input type="text"
1084
                                            </span> <!-- /.field_controls -->
1049
                                                        tabindex="1"
1085
                                        </div> <!-- /div.tag_title -->
1050
                                                        class="indicator flat"
1086
1051
                                                        style="display:none;"
1087
                                        <ul class="sortable_subfield">
1052
                                                        name="tag_[% innerloo.tag | html %]_indicator1_[% innerloo.index | html %][% innerloo.random | html %]"
1088
                                        [% FOREACH subfield_loo IN innerloo.subfield_loop %]
1053
                                                        size="1"
1089
                                            <!--  One line on the marc editor -->
1054
                                                        maxlength="1"
1090
                                            <li class="subfield_line" style="[% subfield_loo.visibility | html %]" id="subfield[% subfield_loo.tag | html %][% subfield_loo.subfield | html %][% subfield_loo.random | html %]">
1055
                                                        value="[% innerloo.indicator1 | html %]" />
1091
                                                <div class="subfieldcode">
1092
                                                    <input type="text"
1056
                                                    <input type="text"
1093
                                                            title="[% subfield_loo.marc_lib | $raw %]"
1057
                                                        tabindex="1"
1094
                                                            style=" [% IF ( subfield_loo.fixedfield ) %]display:none; [% END %]border:0;"
1058
                                                        class="indicator flat"
1095
                                                            name="tag_[% subfield_loo.tag | html %]_code_[% subfield_loo.subfield | html %]_[% subfield_loo.index | html %]_[% subfield_loo.index_subfield | html %]"
1059
                                                        style="display:none;"
1096
                                                            value="[% subfield_loo.subfield | html %]"
1060
                                                        name="tag_[% innerloo.tag | html %]_indicator2_[% innerloo.index | html %][% innerloo.random | html %]"
1097
                                                            size="1"
1061
                                                        size="1"
1098
                                                            maxlength="1"
1062
                                                        maxlength="1"
1099
                                                            class="flat"
1063
                                                        value="[% innerloo.indicator2 | html %]" />
1100
                                                            tabindex="0" />
1064
                                                [% ELSE %]
1101
                                                </div>
1065
                                                    <input type="text"
1066
                                                        tabindex="1"
1067
                                                        class="indicator flat"
1068
                                                        name="tag_[% innerloo.tag | html %]_indicator1_[% innerloo.index | html %][% innerloo.random | html %]"
1069
                                                        size="1"
1070
                                                        maxlength="1"
1071
                                                        value="[% innerloo.indicator1 | html %]" />
1072
                                                    <input type="text"
1073
                                                        tabindex="1"
1074
                                                        class="indicator flat"
1075
                                                        name="tag_[% innerloo.tag | html %]_indicator2_[% innerloo.index | html %][% innerloo.random | html %]"
1076
                                                        size="1"
1077
                                                        maxlength="1"
1078
                                                        value="[% innerloo.indicator2 | html %]" />
1079
                                                [% END # /IF innerloo.fixedfield %] -
1080
1102
                                                [% UNLESS advancedMARCEditor %]
1081
                                                [% UNLESS advancedMARCEditor %]
1103
                                                    [% IF ( subfield_loo.mandatory ) %]
1082
                                                    <a href="#" tabindex="1" class="expandfield" onclick="ExpandField('tag_[% innerloo.tag | html %]_[% innerloo.index | html %][% innerloo.random | html %]'); return false;" title="Click to Expand this Tag">[% innerloo.tag_lib | html %]</a>
1104
                                                        <div class="subfield subfield_mandatory">
1105
                                                    [% ELSIF ( subfield_loo.important ) %]
1106
                                                        <div class="subfield subfield_important">
1107
                                                    [% ELSE %]
1108
                                                        <div class="subfield">
1109
                                                    [% END %]
1110
                                                        [% IF ( subfield_loo.fixedfield ) %]
1111
                                                            <label for="tag_[% subfield_loo.tag | html %]_subfield_[% subfield_loo.subfield | html %]_[% subfield_loo.index | html %]_[% subfield_loo.index_subfield | html %]" style="display:none;" class="labelsubfield">
1112
                                                        [% ELSE %]
1113
                                                            <label for="tag_[% subfield_loo.tag | html %]_subfield_[% subfield_loo.subfield | html %]_[% subfield_loo.index | html %]_[% subfield_loo.index_subfield | html %]" class="labelsubfield">
1114
                                                        [% END %]
1115
                                                        [% subfield_loo.marc_lib | $raw %]
1116
                                                        </label>
1117
                                                    </div>
1118
                                                [% END %]
1083
                                                [% END %]
1119
1084
1120
                                                [% SET mv = subfield_loo.marc_value %]
1085
                                                <span class="field_controls">
1121
                                                <div id="field_marceditor[% subfield_loo.tag | html %][% subfield_loo.subfield | html %][% subfield_loo.random | html %]" class="field_marceditor">
1086
                                                    [% IF ( innerloo.repeatable ) %]
1122
                                                    [% IF ( mv.type == 'text' ) %]
1087
                                                        <a href="#" tabindex="1" class="buttonPlus" onclick="CloneField('tag_[% innerloo.tag | html %]_[% innerloo.index | html %][% innerloo.random | html %]','0','[% advancedMARCEditor | html %]'); return false;" title="Repeat this Tag">
1123
                                                        [% IF ( mv.readonly == 1 ) %]
1088
                                                            <img src="[% interface | html %]/[% theme | html %]/img/repeat-tag.png" alt="Repeat this Tag" />
1124
                                                            <input type="text" id="[%- mv.id | html -%]" name="[%- mv.name | html -%]" value="[%- mv.value | html -%]" class="input_marceditor readonly" tabindex="1" size="[%- mv.size | html -%]" maxlength="[%- mv.maxlength | html -%]" readonly="readonly" />
1089
                                                        </a>
1090
                                                    [% END %]
1091
                                                    <a href="#" tabindex="1" class="buttonMinus" onclick="UnCloneField('tag_[% innerloo.tag | html %]_[% innerloo.index | html %][% innerloo.random | html %]'); return false;" title="Delete this Tag">
1092
                                                        <img src="[% interface | html %]/[% theme | html %]/img/delete-tag.png" alt="Delete this Tag" />
1093
                                                    </a>
1094
                                                </span> <!-- /.field_controls -->
1095
                                            </div> <!-- /div.tag_title -->
1096
1097
                                            <ul class="sortable_subfield">
1098
                                            [% FOREACH subfield_loo IN innerloo.subfield_loop %]
1099
                                                <!--  One line on the marc editor -->
1100
                                                <li class="subfield_line" style="[% subfield_loo.visibility | html %]" id="subfield[% subfield_loo.tag | html %][% subfield_loo.subfield | html %][% subfield_loo.random | html %]">
1101
                                                    <div class="subfieldcode">
1102
                                                        <input type="text"
1103
                                                                title="[% subfield_loo.marc_lib | $raw %]"
1104
                                                                style=" [% IF ( subfield_loo.fixedfield ) %]display:none; [% END %]border:0;"
1105
                                                                name="tag_[% subfield_loo.tag | html %]_code_[% subfield_loo.subfield | html %]_[% subfield_loo.index | html %]_[% subfield_loo.index_subfield | html %]"
1106
                                                                value="[% subfield_loo.subfield | html %]"
1107
                                                                size="1"
1108
                                                                maxlength="1"
1109
                                                                class="flat"
1110
                                                                tabindex="0" />
1111
                                                    </div>
1112
                                                    [% UNLESS advancedMARCEditor %]
1113
                                                        [% IF ( subfield_loo.mandatory ) %]
1114
                                                            <div class="subfield subfield_mandatory">
1115
                                                        [% ELSIF ( subfield_loo.important ) %]
1116
                                                            <div class="subfield subfield_important">
1125
                                                        [% ELSE %]
1117
                                                        [% ELSE %]
1126
                                                            <input type="text" id="[%- mv.id | html -%]" name="[%- mv.name | html -%]" value="[%- mv.value | html -%]" class="input_marceditor" tabindex="1" size="[%- mv.size | html -%]" maxlength="[%- mv.maxlength | html -%]" />
1118
                                                            <div class="subfield">
1127
                                                        [% END %]
1119
                                                        [% END %]
1128
1120
                                                            [% IF ( subfield_loo.fixedfield ) %]
1129
                                                    [% ELSIF ( mv.type == 'text_complex' ) %]
1121
                                                                <label for="tag_[% subfield_loo.tag | html %]_subfield_[% subfield_loo.subfield | html %]_[% subfield_loo.index | html %]_[% subfield_loo.index_subfield | html %]" style="display:none;" class="labelsubfield">
1130
                                                        <input type="text" id="[%- mv.id | html -%]" name="[%- mv.name | html -%]" value="[%- mv.value | html -%]" class="input_marceditor framework_plugin" tabindex="1" size="[%- mv.size | html -%]" maxlength="[%- mv.maxlength | html -%]" />
1122
                                                            [% ELSE %]
1131
                                                        [% mv.javascript | $raw %]
1123
                                                                <label for="tag_[% subfield_loo.tag | html %]_subfield_[% subfield_loo.subfield | html %]_[% subfield_loo.index | html %]_[% subfield_loo.index_subfield | html %]" class="labelsubfield">
1132
                                                    [% ELSIF ( mv.type == 'hidden' ) %]
1124
                                                            [% END %]
1133
                                                        <input tabindex="1" type="hidden" id="[%- mv.id | html -%]" name="[%- mv.name | html -%]" size="[%- mv.size | html -%]" maxlength="[%- mv.maxlength | html -%]" value="[%- mv.value | html -%]" />
1125
                                                            [% subfield_loo.marc_lib | $raw %]
1134
                                                    [% ELSIF ( mv.type == 'textarea' ) %]
1126
                                                            </label>
1135
                                                        <textarea cols="70" rows="4" id="[%- mv.id | html -%]" name="[%- mv.name | html -%]" class="input_marceditor" tabindex="1">[%- mv.value | html -%]</textarea>
1127
                                                        </div>
1136
                                                    [% ELSIF ( mv.type == 'select' ) %]
1137
                                                    [% IF mv.category AND CAN_user_parameters_manage_auth_values %]
1138
                                                        <select name="[%- mv.name | html -%]" tabindex="1" class="input_marceditor" id="[%- mv.id | html -%]" data-category="[% mv.category | html %]">
1139
                                                    [% ELSE %]
1140
                                                        <select name="[%- mv.name | html -%]" tabindex="1" class="input_marceditor select2" id="[%- mv.id | html -%]">
1141
                                                    [% END %]
1128
                                                    [% END %]
1142
                                                        [% FOREACH aval IN mv.values %]
1129
1143
                                                            [% IF aval == mv.default %]
1130
                                                    [% SET mv = subfield_loo.marc_value %]
1144
                                                            <option value="[%- aval | html -%]" selected="selected">[%- mv.labels.$aval | html -%]</option>
1131
                                                    <div id="field_marceditor[% subfield_loo.tag | html %][% subfield_loo.subfield | html %][% subfield_loo.random | html %]" class="field_marceditor">
1132
                                                        [% IF ( mv.type == 'text' ) %]
1133
                                                            [% IF ( mv.readonly == 1 ) %]
1134
                                                                <input type="text" id="[%- mv.id | html -%]" name="[%- mv.name | html -%]" value="[%- mv.value | html -%]" class="input_marceditor readonly" tabindex="1" size="[%- mv.size | html -%]" maxlength="[%- mv.maxlength | html -%]" readonly="readonly" />
1145
                                                            [% ELSE %]
1135
                                                            [% ELSE %]
1146
                                                            <option value="[%- aval | html -%]">[%- mv.labels.$aval | html -%]</option>
1136
                                                                <input type="text" id="[%- mv.id | html -%]" name="[%- mv.name | html -%]" value="[%- mv.value | html -%]" class="input_marceditor" tabindex="1" size="[%- mv.size | html -%]" maxlength="[%- mv.maxlength | html -%]" />
1147
                                                            [% END %]
1137
                                                            [% END %]
1138
1139
                                                        [% ELSIF ( mv.type == 'text_complex' ) %]
1140
                                                            <input type="text" id="[%- mv.id | html -%]" name="[%- mv.name | html -%]" value="[%- mv.value | html -%]" class="input_marceditor framework_plugin" tabindex="1" size="[%- mv.size | html -%]" maxlength="[%- mv.maxlength | html -%]" />
1141
                                                            [% mv.javascript | $raw %]
1142
                                                        [% ELSIF ( mv.type == 'hidden' ) %]
1143
                                                            <input tabindex="1" type="hidden" id="[%- mv.id | html -%]" name="[%- mv.name | html -%]" size="[%- mv.size | html -%]" maxlength="[%- mv.maxlength | html -%]" value="[%- mv.value | html -%]" />
1144
                                                        [% ELSIF ( mv.type == 'textarea' ) %]
1145
                                                            <textarea cols="70" rows="4" id="[%- mv.id | html -%]" name="[%- mv.name | html -%]" class="input_marceditor" tabindex="1">[%- mv.value | html -%]</textarea>
1146
                                                        [% ELSIF ( mv.type == 'select' ) %]
1147
                                                        [% IF mv.category AND CAN_user_parameters_manage_auth_values %]
1148
                                                            <select name="[%- mv.name | html -%]" tabindex="1" class="input_marceditor" id="[%- mv.id | html -%]" data-category="[% mv.category | html %]">
1149
                                                        [% ELSE %]
1150
                                                            <select name="[%- mv.name | html -%]" tabindex="1" class="input_marceditor select2" id="[%- mv.id | html -%]">
1148
                                                        [% END %]
1151
                                                        [% END %]
1149
                                                        </select>
1152
                                                            [% FOREACH aval IN mv.values %]
1150
                                                    [% END  # /IF (mv.type...) %]
1153
                                                                [% IF aval == mv.default %]
1151
                                                </div>
1154
                                                                <option value="[%- aval | html -%]" selected="selected">[%- mv.labels.$aval | html -%]</option>
1152
                                                [% IF ( subfield_loo.mandatory ) %]
1153
                                                    <div class="subfield_loop_mandatory">
1154
                                                        <span class="required">Required</span>
1155
                                                    </div>
1156
                                                [% ELSIF ( subfield_loo.important ) %]
1157
                                                    <div class="subfield_loop_mandatory">
1158
                                                        <span class="important">Important</span>
1159
                                                    </div>
1160
                                                [% END %]
1161
                                                <div class="subfield_controls">
1162
                                                    [% IF ( mv.type == 'text' ) %]
1163
                                                        [% IF ( mv.authtype ) %]
1164
                                                            <a href="#" class="buttonDot tag_editor" onclick="openAuth(this.parentNode.parentNode.getElementsByTagName('input')[1].id,'[%- mv.authtype | html -%]','biblio'); return false;" tabindex="1" title="Tag editor">Tag editor</a>
1165
                                                        [% END %]
1166
                                                    [% ELSIF ( mv.type == 'text_complex' ) %]
1167
                                                            [% IF mv.noclick %]
1168
                                                                <span class="buttonDot tag_editor disabled" tabindex="-1" title="Field autofilled by plugin"></span>
1169
                                                            [% ELSE %]
1170
                                                                [% IF mv.plugin == "upload.pl" %]
1171
                                                                    <a href="#" id="buttonDot_[% mv.id | html %]" class="tag_editor upload framework_plugin" tabindex="1"><i class="fa fa-upload" aria-hidden="true"></i> Upload</a>
1172
                                                                [% ELSE %]
1155
                                                                [% ELSE %]
1173
                                                                    <a href="#" id="buttonDot_[% mv.id | html %]" class="buttonDot tag_editor framework_plugin" tabindex="1" title="Tag editor">Tag editor</a>
1156
                                                                <option value="[%- aval | html -%]">[%- mv.labels.$aval | html -%]</option>
1174
                                                                [% END %]
1157
                                                                [% END %]
1175
                                                            [% END %]
1158
                                                            [% END %]
1176
                                                        </span>
1159
                                                            </select>
1177
                                                    [% END %]
1160
                                                        [% END  # /IF (mv.type...) %]
1178
                                                    [% IF ( subfield_loo.repeatable ) %]
1161
                                                    </div>
1179
                                                        <a href="#" class="buttonPlus" tabindex="1" onclick="CloneSubfield('subfield[% subfield_loo.tag | html %][% subfield_loo.subfield | html %][% subfield_loo.random | html %]','[% advancedMARCEditor | html %]'); return false;">
1162
                                                    [% IF ( subfield_loo.mandatory ) %]
1180
                                                            <img src="[% interface | html %]/[% theme | html %]/img/clone-subfield.png" alt="Clone" title="Clone this subfield" />
1163
                                                        <div class="subfield_loop_mandatory">
1181
                                                        </a>
1164
                                                            <span class="required">Required</span>
1182
                                                        <a href="#" class="buttonMinus" tabindex="1" onclick="UnCloneField('subfield[% subfield_loo.tag | html %][% subfield_loo.subfield | html %][% subfield_loo.random | html %]'); return false;">
1165
                                                        </div>
1183
                                                            <img src="[% interface | html %]/[% theme | html %]/img/delete-subfield.png" alt="Delete" title="Delete this subfield" />
1166
                                                    [% ELSIF ( subfield_loo.important ) %]
1184
                                                        </a>
1167
                                                        <div class="subfield_loop_mandatory">
1168
                                                            <span class="important">Important</span>
1169
                                                        </div>
1185
                                                    [% END %]
1170
                                                    [% END %]
1186
                                                </div>
1171
                                                    <div class="subfield_controls">
1187
                                            </li> <!-- /.subfield_line -->
1172
                                                        [% IF ( mv.type == 'text' ) %]
1188
                                            <!-- End of the line -->
1173
                                                            [% IF ( mv.authtype ) %]
1189
                                        [% END # /FOREACH subfield_loop %]
1174
                                                                <a href="#" class="buttonDot tag_editor" onclick="openAuth(this.parentNode.parentNode.getElementsByTagName('input')[1].id,'[%- mv.authtype | html -%]','biblio'); return false;" tabindex="1" title="Tag editor">Tag editor</a>
1190
                                        </ul> <!--  /.sortable_subfield -->
1175
                                                            [% END %]
1191
                                    </li> <!-- /.tag.clearfix -->
1176
                                                        [% ELSIF ( mv.type == 'text_complex' ) %]
1192
                                [% END %]<!-- if innerloo.tag -->
1177
                                                                [% IF mv.noclick %]
1193
                            [% END # /FOREACH BIG_LOO.innerloop %]
1178
                                                                    <span class="buttonDot tag_editor disabled" tabindex="-1" title="Field autofilled by plugin"></span>
1194
                            </ul> <!--  /.sortable_field -->
1179
                                                                [% ELSE %]
1195
                        </div> <!-- /#tabXXX -->
1180
                                                                    [% IF mv.plugin == "upload.pl" %]
1196
                    [% END # /FOREACH BIG_LOOP %]
1181
                                                                        <a href="#" id="buttonDot_[% mv.id | html %]" class="tag_editor upload framework_plugin" tabindex="1"><i class="fa fa-upload" aria-hidden="true"></i> Upload</a>
1182
                                                                    [% ELSE %]
1183
                                                                        <a href="#" id="buttonDot_[% mv.id | html %]" class="buttonDot tag_editor framework_plugin" tabindex="1" title="Tag editor">Tag editor</a>
1184
                                                                    [% END %]
1185
                                                                [% END %]
1186
                                                            </span>
1187
                                                        [% END %]
1188
                                                        [% IF ( subfield_loo.repeatable ) %]
1189
                                                            <a href="#" class="buttonPlus" tabindex="1" onclick="CloneSubfield('subfield[% subfield_loo.tag | html %][% subfield_loo.subfield | html %][% subfield_loo.random | html %]','[% advancedMARCEditor | html %]'); return false;">
1190
                                                                <img src="[% interface | html %]/[% theme | html %]/img/clone-subfield.png" alt="Clone" title="Clone this subfield" />
1191
                                                            </a>
1192
                                                            <a href="#" class="buttonMinus" tabindex="1" onclick="UnCloneField('subfield[% subfield_loo.tag | html %][% subfield_loo.subfield | html %][% subfield_loo.random | html %]'); return false;">
1193
                                                                <img src="[% interface | html %]/[% theme | html %]/img/delete-subfield.png" alt="Delete" title="Delete this subfield" />
1194
                                                            </a>
1195
                                                        [% END %]
1196
                                                    </div>
1197
                                                </li> <!-- /.subfield_line -->
1198
                                                <!-- End of the line -->
1199
                                            [% END # /FOREACH subfield_loop %]
1200
                                            </ul> <!--  /.sortable_subfield -->
1201
                                        </li> <!-- /.tag.clearfix -->
1202
                                    [% END %]<!-- if innerloo.tag -->
1203
                                [% END # /FOREACH BIG_LOO.innerloop %]
1204
                                </ul> <!--  /.sortable_field -->
1205
                            </div> <!-- /#tabXXX -->
1206
                        [% END # /FOREACH BIG_LOOP %]
1207
                    </div> <!-- /.tab-content -->
1197
                </div><!-- /#addbibliotabs -->
1208
                </div><!-- /#addbibliotabs -->
1198
1209
1199
                [%# Fields for fast cataloging %]
1210
                [%# Fields for fast cataloging %]
1200
- 

Return to bug 31677