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

(-)a/C4/Auth.pm (+4 lines)
Lines 402-407 sub get_template_and_user { Link Here
402
            OpacShowRecentComments    => C4::Context->preference("OpacShowRecentComments"),
402
            OpacShowRecentComments    => C4::Context->preference("OpacShowRecentComments"),
403
            OPACURLOpenInNewWindow    => "" . C4::Context->preference("OPACURLOpenInNewWindow"),
403
            OPACURLOpenInNewWindow    => "" . C4::Context->preference("OPACURLOpenInNewWindow"),
404
            OPACUserCSS               => "". C4::Context->preference("OPACUserCSS"),
404
            OPACUserCSS               => "". C4::Context->preference("OPACUserCSS"),
405
            OPACMobileUserCSS         => "". C4::Context->preference("OPACMobileUserCSS"),
405
            OPACViewOthersSuggestions => "" . C4::Context->preference("OPACViewOthersSuggestions"),
406
            OPACViewOthersSuggestions => "" . C4::Context->preference("OPACViewOthersSuggestions"),
406
            OpacAuthorities           => C4::Context->preference("OpacAuthorities"),
407
            OpacAuthorities           => C4::Context->preference("OpacAuthorities"),
407
            OPACBaseURL               => ($in->{'query'}->https() ? "https://" : "http://") . $ENV{'SERVER_NAME'} .
408
            OPACBaseURL               => ($in->{'query'}->https() ? "https://" : "http://") . $ENV{'SERVER_NAME'} .
Lines 413-418 sub get_template_and_user { Link Here
413
            OpacCloud                 => C4::Context->preference("OpacCloud"),
414
            OpacCloud                 => C4::Context->preference("OpacCloud"),
414
            OpacKohaUrl               => C4::Context->preference("OpacKohaUrl"),
415
            OpacKohaUrl               => C4::Context->preference("OpacKohaUrl"),
415
            OpacMainUserBlock         => "" . C4::Context->preference("OpacMainUserBlock"),
416
            OpacMainUserBlock         => "" . C4::Context->preference("OpacMainUserBlock"),
417
            OpacMainUserBlockMobile   => "" . C4::Context->preference("OpacMainUserBlockMobile"),
418
            OpacShowFiltersPulldownMobile => C4::Context->preference("OpacShowFiltersPulldownMobile"),
419
            OpacShowLibrariesPulldownMobile => C4::Context->preference("OpacShowLibrariesPulldownMobile"),
416
            OpacNav                   => "" . C4::Context->preference("OpacNav"),
420
            OpacNav                   => "" . C4::Context->preference("OpacNav"),
417
            OpacNavRight              => "" . C4::Context->preference("OpacNavRight"),
421
            OpacNavRight              => "" . C4::Context->preference("OpacNavRight"),
418
            OpacNavBottom             => "" . C4::Context->preference("OpacNavBottom"),
422
            OpacNavBottom             => "" . C4::Context->preference("OpacNavBottom"),
(-)a/installer/data/mysql/sysprefs.sql (+4 lines)
Lines 371-373 INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES(' Link Here
371
INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES ('SubfieldsToUseWhenPrefill','','Define a list of subfields to use when prefilling items (separated by space)','','Free');
371
INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES ('SubfieldsToUseWhenPrefill','','Define a list of subfields to use when prefilling items (separated by space)','','Free');
372
INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('AgeRestrictionMarker','','Markers for age restriction indication, e.g. FSK|PEGI|Age|',NULL,'free');
372
INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('AgeRestrictionMarker','','Markers for age restriction indication, e.g. FSK|PEGI|Age|',NULL,'free');
373
INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('AgeRestrictionOverride',0,'Allow staff to check out an item with age restriction.',NULL,'YesNo');
373
INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('AgeRestrictionOverride',0,'Allow staff to check out an item with age restriction.',NULL,'YesNo');
374
INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('OPACMobileUserCSS','','Include the following CSS for the mobile view on all pages in the OPAC:',NULL,'free');
375
INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('OpacMainUserBlockMobile','','Show the following HTML in its own column on the main page of the OPAC (mobile version):',NULL,'free');
376
INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('OpacShowLibrariesPulldownMobile','1','Show the libraries pulldown on the mobile version of the OPAC.',NULL,'YesNo');
377
INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('OpacShowFiltersPulldownMobile','1','Show the search filters pulldown on the mobile version of the OPAC.',NULL,'YesNo');
(-)a/installer/data/mysql/updatedatabase.pl (+11 lines)
Lines 5681-5686 if ( C4::Context->preference("Version") < TransformToNum($DBversion) ) { Link Here
5681
    "INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES ('SubfieldsToUseWhenPrefill','','Define a list of subfields to use when prefilling items (separated by space)','','Free');
5681
    "INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES ('SubfieldsToUseWhenPrefill','','Define a list of subfields to use when prefilling items (separated by space)','','Free');
5682
    ");
5682
    ");
5683
    print "Upgrade to $DBversion done (Adding PrefillItem and SubfieldsToUseWhenPrefill sysprefs)\n";
5683
    print "Upgrade to $DBversion done (Adding PrefillItem and SubfieldsToUseWhenPrefill sysprefs)\n";
5684
    SetVersion ($DBversion);
5684
}
5685
}
5685
5686
5686
$DBversion = "3.09.00.036";
5687
$DBversion = "3.09.00.036";
Lines 5693-5698 if (C4::Context->preference("Version") < TransformToNum($DBversion)) { Link Here
5693
    $dbh->do("INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('AgeRestrictionOverride',0,'Allow staff to check out an item with age restriction.',NULL,'YesNo')");
5694
    $dbh->do("INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('AgeRestrictionOverride',0,'Allow staff to check out an item with age restriction.',NULL,'YesNo')");
5694
5695
5695
    print "Upgrade to $DBversion done (Add colum agerestriction to biblioitems and deletedbiblioitems, add system preferences AgeRestrictionMarker and AgeRestrictionOverride)\n";
5696
    print "Upgrade to $DBversion done (Add colum agerestriction to biblioitems and deletedbiblioitems, add system preferences AgeRestrictionMarker and AgeRestrictionOverride)\n";
5697
   SetVersion ($DBversion);
5698
}
5699
5700
$DBversion ="XXX";
5701
if(C4::Context->preference("Version") < TransformToNum($DBversion) ) {
5702
    $dbh->do("INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('OPACMobileUserCSS','','Include the following CSS for the mobile view on all pages in the OPAC:',NULL,'free');");
5703
    $dbh->do("INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('OpacMainUserBlockMobile','','Show the following HTML in its own column on the main page of the OPAC (mobile version):',NULL,'free');");
5704
    $dbh->do("INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('OpacShowLibrariesPulldownMobile','1','Show the libraries pulldown on the mobile version of the OPAC.',NULL,'YesNo');");
5705
    $dbh->do("INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('OpacShowFiltersPulldownMobile','1','Show the search filters pulldown on the mobile version of the OPAC.',NULL,'YesNo');");
5706
    print "Upgrade to $DBversion done (Add OPACMobileUserCSS, OpacMainUserBlockMobile, OpacShowLibrariesPulldownMobile and OpacShowFiltersPulldownMobile sysprefs)\n";
5696
    SetVersion($DBversion);
5707
    SetVersion($DBversion);
5697
}
5708
}
5698
5709
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/opac.pref (+22 lines)
Lines 163-173 OPAC: Link Here
163
              type: textarea
163
              type: textarea
164
              class: code
164
              class: code
165
        -
165
        -
166
            - "Include the following CSS for the mobile view on all pages in the OPAC:"
167
            - pref: OPACMobileUserCSS
168
              type: textarea
169
              class: code
170
        -
166
            - "Show the following HTML in its own column on the main page of the OPAC:"
171
            - "Show the following HTML in its own column on the main page of the OPAC:"
167
            - pref: OpacMainUserBlock
172
            - pref: OpacMainUserBlock
168
              type: textarea
173
              type: textarea
169
              class: code
174
              class: code
170
        -
175
        -
176
            - "Show the following HTML in its own column on the main page of the OPAC (mobile version):"
177
            - pref: OpacMainUserBlockMobile
178
              type: textarea
179
              class: code
180
        -
181
            - pref: OpacShowLibrariesPulldownMobile
182
              choices:
183
                  yes: Show
184
                  no: "Don't show"
185
            - the libraries pulldown on the mobile version of the OPAC.
186
        -
187
            - pref: OpacShowFiltersPulldownMobile
188
              choices:
189
                  yes: Show
190
                  no: "Don't show"
191
            - the search filters pulldown on the mobile version of the OPAC.
192
        -
171
            - "Show the following HTML on the left hand column of the main page and patron account on the OPAC (generally navigation links):"
193
            - "Show the following HTML on the left hand column of the main page and patron account on the OPAC (generally navigation links):"
172
            - pref: OpacNav
194
            - pref: OpacNav
173
              type: textarea
195
              type: textarea
(-)a/koha-tmpl/opac-tmpl/ccsr/en/css/mobile.css (-14 / +16 lines)
Lines 5-13 Link Here
5
5
6
/* Hidden elements */
6
/* Hidden elements */
7
7
8
.mobile-hidden,
8
body#opac-main #login,
9
body#opac-main #login,
9
body#opac-main #login~div,
10
body#opac-main #login~div,
10
body#opac-main #opacnav,
11
body#opac-main #opacnav,
12
body#opac-main #opacmainuserblock,
11
body#opac-main #news,
13
body#opac-main #news,
12
body#results #facetcontainer,
14
body#results #facetcontainer,
13
body#opac-detail #ulactioncontainer>:not(#action),
15
body#opac-detail #ulactioncontainer>:not(#action),
Lines 99-112 body#results #breadcrumbs>*{ Link Here
99
101
100
/* Main */
102
/* Main */
101
103
102
body#opac-main #opacmainuserblock {
103
    padding: 0
104
}
105
106
body#opac-main #container #ctn_lt{
104
body#opac-main #container #ctn_lt{
107
    padding: 15px;
105
    padding: 15px;
108
}
106
}
109
107
108
body#opac-main #opacmainuserblockmobile {
109
    display: block;
110
}
111
112
110
113
111
/* Results */
114
/* Results */
112
115
Lines 257-286 form#searchform { Link Here
257
    padding-top: 50px;
260
    padding-top: 50px;
258
}
261
}
259
262
260
form.single-library #filters .jqTransformSelectWrapper {
263
form#searchform #filters .jqTransformSelectWrapper,
264
form#searchform #libraries .jqTransformSelectWrapper {
261
    position: relative;
265
    position: relative;
262
    width: 100% !important;
263
    left: 0;
266
    left: 0;
264
    top: 0;
267
    top: 0;
265
    border-radius: 3px;
268
    border-radius: 3px;
266
}
269
}
267
270
268
form.multi-libraries #filters .jqTransformSelectWrapper{
271
form.multi-libraries #filters .jqTransformSelectWrapper{
269
    position: relative;
270
    width: 49% !important;
272
    width: 49% !important;
271
    float: left;
273
    float: left;
272
    top: 0px;
273
    left: 0px;
274
    border-radius: 3px;
275
}
274
}
276
275
277
form.multi-libraries #libraries .jqTransformSelectWrapper{
276
form.multi-libraries #libraries .jqTransformSelectWrapper{
278
    position: relative;
279
    width: 49% !important;
277
    width: 49% !important;
280
    float: right;
278
    float: right;
281
    top: 0px;
279
}
282
    left: 0px;
280
283
    border-radius: 3px;
281
form.single-library #filters .jqTransformSelectWrapper,
282
form.multi-libraries.single-field-mobile #filters .jqTransformSelectWrapper,
283
form.multi-libraries.single-field-mobile #libraries .jqTransformSelectWrapper{
284
    width: 100% !important;
285
    float:left;
284
}
286
}
285
287
286
form.multi-libraries .input-wrapper{
288
form.multi-libraries .input-wrapper{
(-)a/koha-tmpl/opac-tmpl/ccsr/en/css/opac.css (+4 lines)
Lines 2620-2625 ul.ui-tabs-nav li { Link Here
2620
    box-shadow: 1px 1px 3px 0 #666;
2620
    box-shadow: 1px 1px 3px 0 #666;
2621
}
2621
}
2622
2622
2623
body#opac-main #opacmainuserblockmobile {
2624
    display: none;
2625
}
2626
2623
.mobile_only {
2627
.mobile_only {
2624
   display : none;
2628
   display : none;
2625
}
2629
}
(-)a/koha-tmpl/opac-tmpl/ccsr/en/includes/doc-head-close.inc (+1 lines)
Lines 22-27 Link Here
22
<link rel="stylesheet" type="text/css" media="print" href="[% themelang %]/css/print.css" />
22
<link rel="stylesheet" type="text/css" media="print" href="[% themelang %]/css/print.css" />
23
<meta name="viewport" content="width=device-width,initial-scale=1.0,maximum-scale=1.0,minimum-scale=1.0,user-scalable=no">
23
<meta name="viewport" content="width=device-width,initial-scale=1.0,maximum-scale=1.0,minimum-scale=1.0,user-scalable=no">
24
<link rel="stylesheet" type="text/css" media="screen and (max-width:700px)" href="[% themelang %]/css/mobile.css" />
24
<link rel="stylesheet" type="text/css" media="screen and (max-width:700px)" href="[% themelang %]/css/mobile.css" />
25
[% IF ( OPACMobileUserCSS ) %]<style type="text/css" media="screen and (max-width:700px)">[% OPACMobileUserCSS %]</style>[% END %]
25
[% IF ( OPACUserCSS ) %]<style type="text/css">[% OPACUserCSS %]</style>[% END %]
26
[% IF ( OPACUserCSS ) %]<style type="text/css">[% OPACUserCSS %]</style>[% END %]
26
<!-- yui js -->
27
<!-- yui js -->
27
<script type="text/javascript" src="[% yuipath %]/utilities/utilities.js"></script>
28
<script type="text/javascript" src="[% yuipath %]/utilities/utilities.js"></script>
(-)a/koha-tmpl/opac-tmpl/ccsr/en/includes/masthead.inc (-8 / +39 lines)
Lines 84-97 Link Here
84
84
85
[% IF ( OpacPublic ) %]
85
[% IF ( OpacPublic ) %]
86
<div id="fluid-offset">
86
<div id="fluid-offset">
87
[% UNLESS ( advsearch ) %]<form name="searchform" method="get" action="/cgi-bin/koha/opac-search.pl" id="searchform" class="[% IF ( OpacAddMastheadLibraryPulldown ) %]multi-libraries[% ELSE %]single-library[% END %]">
87
[% UNLESS ( advsearch ) %]
88
[% IF ( OpacAddMastheadLibraryPulldown ) %]
89
    [% IF ( OpacShowFiltersPulldownMobile and not OpacShowLibrariesPulldownMobile ) or ( not OpacShowFiltersPulldownMobile and OpacShowLibrariesPulldownMobile ) %]
90
        <form name="searchform" method="get" action="/cgi-bin/koha/opac-search.pl" id="searchform" class="multi-libraries single-field-mobile">
91
    [% ELSE %]
92
        <form name="searchform" method="get" action="/cgi-bin/koha/opac-search.pl" id="searchform" class="multi-libraries">
93
    [% END %]
94
[% ELSE %]
95
    <form name="searchform" method="get" action="/cgi-bin/koha/opac-search.pl" id="searchform" class="single-library">
96
[% END %]
88
    <label for="masthead_search" class="left"> Search
97
    <label for="masthead_search" class="left"> Search
89
    [% UNLESS ( OpacAddMastheadLibraryPulldown ) %]
98
    [% UNLESS ( OpacAddMastheadLibraryPulldown ) %]
90
            [% IF ( mylibraryfirst ) %] (in [% mylibraryfirst %] only)[% END %]
99
            [% IF ( mylibraryfirst ) %] (in [% mylibraryfirst %] only)[% END %]
91
    [% END %]
100
    [% END %]
92
    </label>
101
    </label>
93
102
    [% IF ( OpacShowFiltersPulldownMobile ) %]
94
    <div id="filters">
103
        <div id="filters">
104
    [% ELSE %]
105
        <div id="filters" class="mobile-hidden">
106
    [% END %]
95
    <select name="idx" id="masthead_search" class="left">
107
    <select name="idx" id="masthead_search" class="left">
96
    [% IF ( ms_kw ) %]
108
    [% IF ( ms_kw ) %]
97
        <option selected="selected" value="">Library catalog</option>
109
        <option selected="selected" value="">Library catalog</option>
Lines 139-145 Link Here
139
</div>
151
</div>
140
152
141
   [% IF ( OpacAddMastheadLibraryPulldown ) %]
153
   [% IF ( OpacAddMastheadLibraryPulldown ) %]
142
    <div id="libraries">
154
        [% IF ( OpacShowLibrariesPulldownMobile ) %]
155
            <div id="libraries">
156
        [% ELSE %]
157
            <div id="libraries" class="mobile-hidden">
158
        [% END %]
143
      <select name="limit" id="select_library" class="left">
159
      <select name="limit" id="select_library" class="left">
144
         <option value="">All libraries</option>
160
         <option value="">All libraries</option>
145
         [% FOREACH BranchesLoo IN BranchesLoop %]
161
         [% FOREACH BranchesLoo IN BranchesLoop %]
Lines 168-181 Link Here
168
184
169
    </form>
185
    </form>
170
[% ELSE %] <!--advsearch -->
186
[% ELSE %] <!--advsearch -->
171
<form name="searchform" method="get" action="/cgi-bin/koha/opac-search.pl" id="searchform" class="[% IF ( OpacAddMastheadLibraryPulldown ) %]multi-libraries[% ELSE %]single-library[% END %]">
187
    [% IF ( OpacAddMastheadLibraryPulldown ) %]
188
        [% IF ( OpacShowFiltersPulldownMobile and not OpacShowLibrariesPulldownMobile ) or ( not OpacShowFiltersPulldownMobile and OpacShowLibrariesPulldownMobile ) %]
189
            <form name="searchform" method="get" action="/cgi-bin/koha/opac-search.pl" id="searchform" class="multi-libraries single-field-mobile">
190
        [% ELSE %]
191
            <form name="searchform" method="get" action="/cgi-bin/koha/opac-search.pl" id="searchform" class="multi-libraries">
192
        [% END %]
193
    [% ELSE %]
194
        <form name="searchform" method="get" action="/cgi-bin/koha/opac-search.pl" id="searchform" class="single-library">
195
    [% END %]
172
    <label for="masthead_search" class="left"> Search
196
    <label for="masthead_search" class="left"> Search
173
    [% UNLESS ( OpacAddMastheadLibraryPulldown ) %]
197
    [% UNLESS ( OpacAddMastheadLibraryPulldown ) %]
174
            [% IF ( mylibraryfirst ) %] (in [% mylibraryfirst %] only)[% END %]
198
            [% IF ( mylibraryfirst ) %] (in [% mylibraryfirst %] only)[% END %]
175
    [% END %]
199
    [% END %]
176
    </label>
200
    </label>
177
201
    [% IF ( OpacShowFiltersPulldownMobile ) %]
178
    <div id="filters" class="transparent">
202
        <div id="filters" class="transparent">
203
    [% ELSE %]
204
        <div id="filters" class="transparent mobile-hidden">
205
    [% END %]
179
        <select name="idx" id="masthead_search" class="left" disabled="disabled">
206
        <select name="idx" id="masthead_search" class="left" disabled="disabled">
180
            <option selected="selected" value="">Library Catalog</option>
207
            <option selected="selected" value="">Library Catalog</option>
181
        </select>
208
        </select>
Lines 186-192 Link Here
186
</div>
213
</div>
187
214
188
   [% IF ( OpacAddMastheadLibraryPulldown ) %]
215
   [% IF ( OpacAddMastheadLibraryPulldown ) %]
189
        <div id="libraries">
216
        [% IF ( OpacShowLibrariesPulldownMobile ) %]
217
            <div id="libraries">
218
        [% ELSE %]
219
            <div id="libraries" class="mobile-hidden">
220
        [% END %]
190
          <select name="limit" id="select_library" class="left transparent">
221
          <select name="limit" id="select_library" class="left transparent">
191
             <option value="">All Libraries</option>
222
             <option value="">All Libraries</option>
192
          </select>
223
          </select>
(-)a/koha-tmpl/opac-tmpl/prog/en/css/opac.css (+4 lines)
Lines 2641-2646 ul.ui-tabs-nav li { Link Here
2641
    display: inline;
2641
    display: inline;
2642
}
2642
}
2643
2643
2644
body#opac-main #opacmainuserblockmobile {
2645
    display: none;
2646
}
2647
2644
.mobile_only {
2648
.mobile_only {
2645
   display : none;
2649
   display : none;
2646
}
2650
}
(-)a/koha-tmpl/opac-tmpl/prog/en/includes/doc-head-close.inc (+1 lines)
Lines 22-27 Link Here
22
    <link rel="stylesheet" type="text/css" href="[% themelang %]/css/[% opac_css_override %]" />
22
    <link rel="stylesheet" type="text/css" href="[% themelang %]/css/[% opac_css_override %]" />
23
[% END %]
23
[% END %]
24
<link rel="stylesheet" type="text/css" media="print" href="[% themelang %]/css/print.css" />
24
<link rel="stylesheet" type="text/css" media="print" href="[% themelang %]/css/print.css" />
25
[% IF ( OPACMobileUserCSS ) %]<style type="text/css" media="screen and (max-width:700px)">[% OPACMobileUserCSS %]</style>[% END %]
25
[% IF ( OPACUserCSS ) %]<style type="text/css">[% OPACUserCSS %]</style>[% END %]
26
[% IF ( OPACUserCSS ) %]<style type="text/css">[% OPACUserCSS %]</style>[% END %]
26
<!-- yui js --> 
27
<!-- yui js --> 
27
<script type="text/javascript" src="[% yuipath %]/utilities/utilities.js"></script> 
28
<script type="text/javascript" src="[% yuipath %]/utilities/utilities.js"></script> 
(-)a/koha-tmpl/opac-tmpl/prog/en/modules/opac-main.tt (-1 / +1 lines)
Lines 37-42 Link Here
37
[% END %]
37
[% END %]
38
38
39
	[% IF ( OpacMainUserBlock ) %]<div id="opacmainuserblock" class="container">[% OpacMainUserBlock %]</div>[% END %]
39
	[% IF ( OpacMainUserBlock ) %]<div id="opacmainuserblock" class="container">[% OpacMainUserBlock %]</div>[% END %]
40
 [% IF ( OpacMainUserBlockMobile ) %]<div id="opacmainuserblockmobile" class="container">[% OpacMainUserBlockMobile %]</div>[% END %]
40
41
41
</div>
42
</div>
42
		
43
		
43
- 

Return to bug 8597