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

(-)a/koha-tmpl/intranet-tmpl/prog/css/preferences.css (-9 / +40 lines)
Lines 47-65 caption { Link Here
47
h3 {
47
h3 {
48
	color : #003366;
48
	color : #003366;
49
	margin : .4em 0;
49
	margin : .4em 0;
50
    width : 40%;
51
}
50
}
52
51
53
h3.expanded {
52
/* https://css-tricks.com/hash-tag-links-padding/#article-header-id-4 */
54
    background: transparent url("../img/collapse.gif") 0 6px no-repeat;
53
h3:target {
55
	cursor : pointer;
54
    margin-top: -12px;
56
	padding-left : 12px;
55
    padding-top: 50px;
57
}
56
}
58
57
58
h3:target::before {
59
    padding: 0 5px;
60
    position: absolute;
61
    top: 25px;
62
}
63
64
h3 i {
65
    color: #336699;
66
}
67
68
h3.expanded,
59
h3.collapsed {
69
h3.collapsed {
60
    background: transparent url("../img/expand.gif") 0 6px no-repeat;
70
    cursor: pointer;
61
	cursor : pointer;
71
}
62
	padding-left : 12px;
72
73
h3.expanded i.fa.fa-caret-down::before {
74
    content: "\f0d7";
75
}
76
77
h3.collapsed i.fa.fa-caret-down::before {
78
    content: "\f0da";
63
}
79
}
64
80
65
.humanMsg strong {
81
.humanMsg strong {
Lines 134-137 span.overridden { Link Here
134
    border: 1px solid #EEE;
150
    border: 1px solid #EEE;
135
    margin: 1em 1em 1em 0;
151
    margin: 1em 1em 1em 0;
136
    resize:  vertical;
152
    resize:  vertical;
137
}
153
}
154
155
#menu ul li.active a.pref_sublink {
156
    background: #FFF none;
157
    border: 0;
158
    color: #004D99;
159
    font-size: 100%;
160
    hyphens:  auto;
161
    margin: 0;
162
    padding: .2em .5em;
163
    text-align: right;
164
}
165
166
#menu ul ul {
167
    padding-left: 0;
168
}
(-)a/koha-tmpl/intranet-tmpl/prog/css/right-to-left.css (-12 lines)
Lines 377-394 p label, { Link Here
377
    float: left;
377
    float: left;
378
}
378
}
379
379
380
/*the arrwos in pref.*/
381
h3.expanded {
382
    background: url("../img/collapse.gif") no-repeat scroll right 6px transparent;
383
    cursor: pointer;
384
    padding-right: 12px;
385
}
386
h3.collapsed {
387
    background: url("../img/expand.gif") no-repeat scroll right 6px transparent;
388
    cursor: pointer;
389
    padding-right: 12px;
390
391
}
392
.dropdown-menu {
380
.dropdown-menu {
393
    position: absolute;
381
    position: absolute;
394
    top: 100%;
382
    top: 100%;
(-)a/koha-tmpl/intranet-tmpl/prog/en/includes/prefs-menu.inc (-19 / +183 lines)
Lines 1-21 Link Here
1
<div id="menu">
1
<div id="menu">
2
<ul>
2
    <ul>
3
[% IF ( accounting ) %]<li class="active">[% ELSE %]<li>[% END %]<a title="Accounting" href="/cgi-bin/koha/admin/preferences.pl?tab=accounting">Accounting</a></li>
3
        [% IF ( accounting ) %]
4
[% IF ( acquisitions ) %]<li class="active">[% ELSE %]<li>[% END %]<a title="Acquisitions" href="/cgi-bin/koha/admin/preferences.pl?tab=acquisitions">Acquisitions</a></li>
4
            <li class="active">
5
[% IF ( admin ) %]<li class="active">[% ELSE %]<li>[% END %]<a title="Administration" href="/cgi-bin/koha/admin/preferences.pl?tab=admin">Administration</a></li>
5
                <a title="Accounting" href="/cgi-bin/koha/admin/preferences.pl?tab=accounting">Accounting</a>
6
[% IF ( authorities ) %]<li class="active">[% ELSE %]<li>[% END %]<a title="Authority Control" href="/cgi-bin/koha/admin/preferences.pl?tab=authorities">Authorities</a></li>
6
                [% PROCESS subtabs  %]
7
[% IF ( cataloguing ) %]<li class="active">[% ELSE %]<li>[% END %]<a title="Cataloging" href="/cgi-bin/koha/admin/preferences.pl?tab=cataloguing">Cataloging</a></li>
7
        [% ELSE %]
8
[% IF ( circulation ) %]<li class="active">[% ELSE %]<li>[% END %]<a title="Circulation" href="/cgi-bin/koha/admin/preferences.pl?tab=circulation">Circulation</a></li>
8
            <li>
9
[% IF ( enhanced_content ) %]<li class="active">[% ELSE %]<li>[% END %]<a title="Enhanced content settings" href="/cgi-bin/koha/admin/preferences.pl?tab=enhanced_content">Enhanced content</a></li>
9
                <a title="Accounting" href="/cgi-bin/koha/admin/preferences.pl?tab=accounting">Accounting</a>
10
[% IF ( i18n_l10n ) %]<li class="active">[% ELSE %]<li>[% END %]<a title="Internationalization and localization" href="/cgi-bin/koha/admin/preferences.pl?tab=i18n_l10n">I18N/L10N</a></li>
10
        [% END %]
11
[% IF ( local_use ) %]<li class="active">[% ELSE %]<li>[% END %]<a href="/cgi-bin/koha/admin/systempreferences.pl">Local use</a></li>
11
        [% IF ( acquisitions ) %]
12
[% IF ( logs ) %]<li class="active">[% ELSE %]<li>[% END %]<a title="Transaction logs" href="/cgi-bin/koha/admin/preferences.pl?tab=logs">Logs</a></li>
12
            <li class="active">
13
[% IF ( opac ) %]<li class="active">[% ELSE %]<li>[% END %]<a title="Online Public Access Catalog" href="/cgi-bin/koha/admin/preferences.pl?tab=opac">OPAC</a></li>
13
                <a title="Acquisitions" href="/cgi-bin/koha/admin/preferences.pl?tab=acquisitions">Acquisitions</a>
14
[% IF ( patrons ) %]<li class="active">[% ELSE %]<li>[% END %]<a title="Patrons" href="/cgi-bin/koha/admin/preferences.pl?tab=patrons">Patrons</a></li>
14
                [% PROCESS subtabs  %]
15
[% IF ( searching ) %]<li class="active">[% ELSE %]<li>[% END %]<a title="Searching" href="/cgi-bin/koha/admin/preferences.pl?tab=searching">Searching</a></li>
15
        [% ELSE %]
16
[% IF ( serials ) %]<li class="active">[% ELSE %]<li>[% END %]<a title="Serials" href="/cgi-bin/koha/admin/preferences.pl?tab=serials">Serials</a></li>
16
            <li>
17
[% IF ( staff_client ) %]<li class="active">[% ELSE %]<li>[% END %]<a title="Staff client" href="/cgi-bin/koha/admin/preferences.pl?tab=staff_client">Staff client</a></li>
17
                <a title="Acquisitions" href="/cgi-bin/koha/admin/preferences.pl?tab=acquisitions">Acquisitions</a>
18
[% IF ( tools ) %]<li class="active">[% ELSE %]<li>[% END %]<a title="Tools" href="/cgi-bin/koha/admin/preferences.pl?tab=tools">Tools</a></li>
18
        [% END %]
19
[% IF ( web_services ) %]<li class="active">[% ELSE %]<li>[% END %]<a title="Web services" href="/cgi-bin/koha/admin/preferences.pl?tab=web_services">Web services</a></li>
19
        </li>
20
</ul>
20
21
        [% IF ( admin ) %]
22
            <li class="active">
23
                <a title="Administration" href="/cgi-bin/koha/admin/preferences.pl?tab=admin">Administration</a>
24
                [% PROCESS subtabs  %]
25
        [% ELSE %]
26
            <li>
27
                <a title="Administration" href="/cgi-bin/koha/admin/preferences.pl?tab=admin">Administration</a>
28
        [% END %]
29
        </li>
30
31
        [% IF ( authorities ) %]
32
            <li class="active">
33
                <a title="Authority Control" href="/cgi-bin/koha/admin/preferences.pl?tab=authorities">Authorities</a>
34
                [% PROCESS subtabs  %]
35
        [% ELSE %]
36
            <li>
37
                <a title="Authority Control" href="/cgi-bin/koha/admin/preferences.pl?tab=authorities">Authorities</a>
38
        [% END %]
39
        </li>
40
41
        [% IF ( cataloguing ) %]
42
            <li class="active">
43
                <a title="Cataloging" href="/cgi-bin/koha/admin/preferences.pl?tab=cataloguing">Cataloging</a>
44
                [% PROCESS subtabs  %]
45
        [% ELSE %]
46
            <li>
47
                <a title="Cataloging" href="/cgi-bin/koha/admin/preferences.pl?tab=cataloguing">Cataloging</a>
48
        [% END %]
49
        </li>
50
51
        [% IF ( circulation ) %]
52
            <li class="active">
53
                <a title="Circulation" href="/cgi-bin/koha/admin/preferences.pl?tab=circulation">Circulation</a>
54
                [% PROCESS subtabs  %]
55
        [% ELSE %]
56
            <li>
57
                <a title="Circulation" href="/cgi-bin/koha/admin/preferences.pl?tab=circulation">Circulation</a>
58
        [% END %]
59
        </li>
60
61
        [% IF ( enhanced_content ) %]
62
            <li class="active">
63
                <a title="Enhanced content settings" href="/cgi-bin/koha/admin/preferences.pl?tab=enhanced_content">Enhanced content</a>
64
                [% PROCESS subtabs  %]
65
        [% ELSE %]
66
            <li>
67
                <a title="Enhanced content settings" href="/cgi-bin/koha/admin/preferences.pl?tab=enhanced_content">Enhanced content</a>
68
        [% END %]
69
        </li>
70
71
        [% IF ( i18n_l10n ) %]
72
            <li class="active">
73
                <a title="Internationalization and localization" href="/cgi-bin/koha/admin/preferences.pl?tab=i18n_l10n">I18N/L10N</a>
74
                [% PROCESS subtabs  %]
75
        [% ELSE %]
76
            <li>
77
                <a title="Internationalization and localization" href="/cgi-bin/koha/admin/preferences.pl?tab=i18n_l10n">I18N/L10N</a>
78
        [% END %]
79
        </li>
80
81
        [% IF ( local_use ) %]
82
            <li class="active">
83
                <a href="/cgi-bin/koha/admin/systempreferences.pl">Local use</a>
84
                [% PROCESS subtabs  %]
85
        [% ELSE %]
86
            <li>
87
            <a href="/cgi-bin/koha/admin/systempreferences.pl">Local use</a>
88
        [% END %]
89
        </li>
90
91
        [% IF ( logs ) %]
92
            <li class="active">
93
                <a title="Transaction logs" href="/cgi-bin/koha/admin/preferences.pl?tab=logs">Logs</a>
94
                [% PROCESS subtabs  %]
95
        [% ELSE %]
96
            <li>
97
                <a title="Transaction logs" href="/cgi-bin/koha/admin/preferences.pl?tab=logs">Logs</a>
98
        [% END %]
99
        </li>
100
101
        [% IF ( opac ) %]
102
            <li class="active">
103
                <a title="Online Public Access Catalog" href="/cgi-bin/koha/admin/preferences.pl?tab=opac">OPAC</a>
104
                [% PROCESS subtabs  %]
105
        [% ELSE %]
106
            <li>
107
                <a title="Online Public Access Catalog" href="/cgi-bin/koha/admin/preferences.pl?tab=opac">OPAC</a>
108
        [% END %]
109
        </li>
110
111
        [% IF ( patrons ) %]
112
            <li class="active">
113
                <a title="Patrons" href="/cgi-bin/koha/admin/preferences.pl?tab=patrons">Patrons</a>
114
                [% PROCESS subtabs  %]
115
        [% ELSE %]
116
            <li>
117
                <a title="Patrons" href="/cgi-bin/koha/admin/preferences.pl?tab=patrons">Patrons</a>
118
        [% END %]
119
        </li>
120
121
        [% IF ( searching ) %]
122
            <li class="active">
123
                <a title="Searching" href="/cgi-bin/koha/admin/preferences.pl?tab=searching">Searching</a>
124
                [% PROCESS subtabs  %]
125
        [% ELSE %]
126
            <li>
127
                <a title="Searching" href="/cgi-bin/koha/admin/preferences.pl?tab=searching">Searching</a>
128
        [% END %]
129
        </li>
130
131
        [% IF ( serials ) %]
132
            <li class="active">
133
                <a title="Serials" href="/cgi-bin/koha/admin/preferences.pl?tab=serials">Serials</a>
134
                [% PROCESS subtabs  %]
135
        [% ELSE %]
136
            <li>
137
                <a title="Serials" href="/cgi-bin/koha/admin/preferences.pl?tab=serials">Serials</a>
138
        [% END %]
139
        </li>
140
141
        [% IF ( staff_client ) %]
142
            <li class="active">
143
                <a title="Staff client" href="/cgi-bin/koha/admin/preferences.pl?tab=staff_client">Staff client</a>
144
                [% PROCESS subtabs  %]
145
        [% ELSE %]
146
            <li>
147
                <a title="Staff client" href="/cgi-bin/koha/admin/preferences.pl?tab=staff_client">Staff client</a>
148
        [% END %]
149
        </li>
150
151
        [% IF ( tools ) %]
152
            <li class="active">
153
                <a title="Tools" href="/cgi-bin/koha/admin/preferences.pl?tab=tools">Tools</a>
154
                [% PROCESS subtabs  %]
155
        [% ELSE %]
156
            <li>
157
                <a title="Tools" href="/cgi-bin/koha/admin/preferences.pl?tab=tools">Tools</a>
158
        [% END %]
159
        </li>
160
161
        [% IF ( web_services ) %]
162
            <li class="active">
163
                <a title="Web services" href="/cgi-bin/koha/admin/preferences.pl?tab=web_services">Web services</a>
164
                [% PROCESS subtabs  %]
165
        [% ELSE %]
166
            <li>
167
                <a title="Web services" href="/cgi-bin/koha/admin/preferences.pl?tab=web_services">Web services</a>
168
        [% END %]
169
        </li>
170
    </ul>
21
</div>
171
</div>
172
173
[% BLOCK subtabs %]
174
    [% UNLESS ( searchfield ) %]
175
        [% FOREACH TAB IN TABS %]
176
            <ul>
177
                [% FOREACH LINE IN TAB.LINES %]
178
                    [% IF ( LINE.is_group_title ) %]
179
                        <li><a class="pref_sublink" href="#[% LINE.title | replace('\s+', '_') | uri %]">[% LINE.title | html %]</a></li>
180
                    [% END %]
181
                [% END %]
182
            </ul>
183
        [% END %]
184
    [% END %]
185
[% END %]
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences.tt (-2 / +12 lines)
Lines 47-54 Link Here
47
            [% FOREACH LINE IN TAB.LINES %]
47
            [% FOREACH LINE IN TAB.LINES %]
48
            [% IF ( LINE.is_group_title ) %]
48
            [% IF ( LINE.is_group_title ) %]
49
            [% UNLESS ( loop.first ) %]</tbody></table>[% END %]
49
            [% UNLESS ( loop.first ) %]</tbody></table>[% END %]
50
            <h3>[% LINE.title | html %]</h3>
50
            <div class="row">
51
            <table class="preferences">
51
                <div class="col-sm-6">
52
                    <h3 id="[% LINE.title | replace('\s+', '_') | html %]"><i class="fa fa-caret-down"></i> [% LINE.title | html %]</h3>
53
                </div>
54
                <div class="col-sm-6">
55
                    [% IF ( searchfield ) %]
56
                        <div class="pull-right"><a class="btn btn-link" href="/cgi-bin/koha/admin/preferences.pl?tab=[% TAB.tab_id | html %]#[% LINE.title | replace('\s+', '_') | html %]"><i class="fa fa-list-ul"></i> View all [% LINE.title | html %] preferences</a></div>
57
                    [% END %]
58
                </div>
59
            </div>
60
61
            <table class="preferences" id="collapse_[% LINE.title | replace('\s+', '_') | html %]">
52
            <thead><tr><th>Preference</th><th>Value</th></tr></thead>
62
            <thead><tr><th>Preference</th><th>Value</th></tr></thead>
53
            [% UNLESS ( loop.last ) %]<tbody>[% END %]
63
            [% UNLESS ( loop.last ) %]<tbody>[% END %]
54
            [% ELSE %]
64
            [% ELSE %]
(-)a/koha-tmpl/intranet-tmpl/prog/js/pages/preferences.js (-2 / +14 lines)
Lines 150-156 $( document ).ready( function () { Link Here
150
    var collapsible = $(".collapsed,.expanded");
150
    var collapsible = $(".collapsed,.expanded");
151
151
152
    $(collapsible).on("click",function(){
152
    $(collapsible).on("click",function(){
153
        var panel = $(this).next("div");
153
        var h3Id = $(this).attr("id");
154
        var panel = $("#collapse_" + h3Id);
154
        if(panel.is(":visible")){
155
        if(panel.is(":visible")){
155
            $(this).addClass("collapsed").removeClass("expanded").attr("title",MSG_CLICK_TO_EXPAND);
156
            $(this).addClass("collapsed").removeClass("expanded").attr("title",MSG_CLICK_TO_EXPAND);
156
            panel.hide();
157
            panel.hide();
Lines 160-165 $( document ).ready( function () { Link Here
160
        }
161
        }
161
    });
162
    });
162
163
164
    $(".pref_sublink").on("click", function(){
165
        /* If the user clicks a sub-menu link in the sidebar,
166
           check to see if it is collapsed. If so, expand it */
167
        var href = $(this).attr("href");
168
        href = href.replace("#","");
169
        var panel = $("#collapse_" + href );
170
        if( panel.is(":hidden") ){
171
            $("#" + href ).addClass("expanded").removeClass("collapsed").attr("title",MSG_CLICK_TO_COLLAPSE);
172
            panel.show();
173
        }
174
    });
175
163
    if ( to_highlight ) {
176
    if ( to_highlight ) {
164
        var words = to_highlight.split( ' ' );
177
        var words = to_highlight.split( ' ' );
165
        $( '.prefs-tab table' ).find( 'td, th' ).not( '.name-cell' ).each( function ( i, td ) {
178
        $( '.prefs-tab table' ).find( 'td, th' ).not( '.name-cell' ).each( function ( i, td ) {
166
- 

Return to bug 23410