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

(-)a/C4/Auth.pm (+3 lines)
Lines 150-155 sub get_template_and_user { Link Here
150
        # user info
150
        # user info
151
        $template->param( loggedinusername => $user );
151
        $template->param( loggedinusername => $user );
152
        $template->param( sessionID        => $sessionID );
152
        $template->param( sessionID        => $sessionID );
153
        $template->param(  OpacNotPublic   => C4::Context->preference("OpacNotPublic") )
154
            unless (  $template->param( 'loggedinusername'  ) );
153
155
154
		my ($total, $pubshelves, $barshelves) = C4::Context->get_shelves_userenv();
156
		my ($total, $pubshelves, $barshelves) = C4::Context->get_shelves_userenv();
155
		if (defined($pubshelves)) {
157
		if (defined($pubshelves)) {
Lines 917-922 sub checkauth { Link Here
917
        virtualshelves       => C4::Context->preference("virtualshelves"),
919
        virtualshelves       => C4::Context->preference("virtualshelves"),
918
        LibraryName          => C4::Context->preference("LibraryName"),
920
        LibraryName          => C4::Context->preference("LibraryName"),
919
        opacuserlogin        => C4::Context->preference("opacuserlogin"),
921
        opacuserlogin        => C4::Context->preference("opacuserlogin"),
922
        OpacNotPublic        => C4::Context->preference("OpacNotPublic"),
920
        OpacNav              => C4::Context->preference("OpacNav"),
923
        OpacNav              => C4::Context->preference("OpacNav"),
921
        opaccredits          => C4::Context->preference("opaccredits"),
924
        opaccredits          => C4::Context->preference("opaccredits"),
922
        opacreadinghistory   => C4::Context->preference("opacreadinghistory"),
925
        opacreadinghistory   => C4::Context->preference("opacreadinghistory"),
(-)a/installer/data/mysql/updatedatabase.pl (+7 lines)
Lines 3520-3525 if (C4::Context->preference('Version') < TransformToNum($DBversion)){ Link Here
3520
    SetVersion ($DBversion);
3520
    SetVersion ($DBversion);
3521
}
3521
}
3522
3522
3523
$DBversion = '3.01.00.xxx';
3524
if (C4::Context->preference("Version") < TransformToNum($DBversion)) {
3525
    $dbh->do("INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES ('OpacNotPublic','0','OPAC search-bar and buttons, and non-authenticated OPAC access','','YesNo')");
3526
    print "Upgrade to $DBversion done (added 'OpacNotPublic' syspref)\n";
3527
    SetVersion ($DBversion);
3528
}
3529
3523
=item DropAllForeignKeys($table)
3530
=item DropAllForeignKeys($table)
3524
3531
3525
  Drop all foreign keys of the table $table
3532
  Drop all foreign keys of the table $table
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/opac.pref (+6 lines)
Lines 294-299 OPAC: Link Here
294
                  yes: Show
294
                  yes: Show
295
                  no: "Don't show"
295
                  no: "Don't show"
296
            - purchase suggestions from other patrons on the OPAC.
296
            - purchase suggestions from other patrons on the OPAC.
297
        -
298
            - pref: OPACNotPublic
299
              choices:
300
                  yes: "Disable"
301
                  no:  "Enable"
302
            - OPAC search-bar field and Cart/Virtual-Shelves buttons, and non-authenticated OPAC access.
297
    Privacy:
303
    Privacy:
298
        -
304
        -
299
            - pref: EnableOpacSearchHistory
305
            - pref: EnableOpacSearchHistory
(-)a/koha-tmpl/opac-tmpl/prog/en/includes/masthead.inc (+11 lines)
Lines 25-30 Link Here
25
   <!-- /TMPL_IF --><a href="/cgi-bin/koha/opac-main.pl"><!-- TMPL_IF NAME="LibraryName" --><!-- TMPL_VAR NAME="LibraryName" --><!-- TMPL_ELSE -->Koha Online Catalog<!-- /TMPL_IF --></a></h1>
25
   <!-- /TMPL_IF --><a href="/cgi-bin/koha/opac-main.pl"><!-- TMPL_IF NAME="LibraryName" --><!-- TMPL_VAR NAME="LibraryName" --><!-- TMPL_ELSE -->Koha Online Catalog<!-- /TMPL_IF --></a></h1>
26
26
27
<div id="fluid">
27
<div id="fluid">
28
29
<!-- Hide search-bar block, if OpacNotPublic=YES --> 
30
<!-- TMPL_UNLESS NAME="OpacNotPublic" -->
31
28
<div id="fluid-offset">
32
<div id="fluid-offset">
29
<!-- TMPL_UNLESS NAME="advsearch" --><form name="searchform" method="get" action="/cgi-bin/koha/opac-search.pl" id="searchform">
33
<!-- TMPL_UNLESS NAME="advsearch" --><form name="searchform" method="get" action="/cgi-bin/koha/opac-search.pl" id="searchform">
30
    <label for="masthead_search" class="left"> Search 
34
    <label for="masthead_search" class="left"> Search 
Lines 166-174 Link Here
166
	  </div>
170
	  </div>
167
</div><!-- /listmenu /virtualshelves -->
171
</div><!-- /listmenu /virtualshelves -->
168
<!-- /TMPL_IF -->
172
<!-- /TMPL_IF -->
173
174
<!-- Hide search-bar block, if OpacNotPublic=YES --> 
175
<!-- /TMPL_UNLESS -->
176
169
<div id="listsDetails"></div>
177
<div id="listsDetails"></div>
170
</div>
178
</div>
171
</div>
179
</div>
180
172
<div id="breadcrumbs" class="yui-g">
181
<div id="breadcrumbs" class="yui-g">
173
<!-- TMPL_IF NAME="searchdesc" --><p><!-- TMPL_IF name="total" --><strong>&ldquo;<!-- TMPL_VAR NAME="query_desc" ESCAPE="HTML"--> <!-- TMPL_VAR NAME="limit_desc" ESCAPE="HTML"-->&rdquo; </strong>returned <!-- TMPL_VAR NAME="total" ESCAPE="HTML"--> results. <!-- TMPL_IF NAME="related" --> (related searches: <!-- TMPL_LOOP NAME="related" --><!-- TMPL_VAR NAME="related_search" --><!-- /TMPL_LOOP -->). <!-- /TMPL_IF -->
182
<!-- TMPL_IF NAME="searchdesc" --><p><!-- TMPL_IF name="total" --><strong>&ldquo;<!-- TMPL_VAR NAME="query_desc" ESCAPE="HTML"--> <!-- TMPL_VAR NAME="limit_desc" ESCAPE="HTML"-->&rdquo; </strong>returned <!-- TMPL_VAR NAME="total" ESCAPE="HTML"--> results. <!-- TMPL_IF NAME="related" --> (related searches: <!-- TMPL_LOOP NAME="related" --><!-- TMPL_VAR NAME="related_search" --><!-- /TMPL_LOOP -->). <!-- /TMPL_IF -->
174
<a href="<!-- TMPL_VAR NAME="OPACBaseURL" -->/cgi-bin/koha/opac-search.pl?<!-- TMPL_VAR name="query_cgi" ESCAPE="HTML" --><!-- TMPL_VAR NAME="limit_cgi"  ESCAPE="HTML" -->&amp;format=rss2"><img src="/opac-tmpl/prog/images/feed-icon-16x16.png" alt="Subscribe to this search" title="Subscribe to this search" border="0" /></a>
183
<a href="<!-- TMPL_VAR NAME="OPACBaseURL" -->/cgi-bin/koha/opac-search.pl?<!-- TMPL_VAR name="query_cgi" ESCAPE="HTML" --><!-- TMPL_VAR NAME="limit_cgi"  ESCAPE="HTML" -->&amp;format=rss2"><img src="/opac-tmpl/prog/images/feed-icon-16x16.png" alt="Subscribe to this search" title="Subscribe to this search" border="0" /></a>
Lines 182-185 Link Here
182
    <!-- /TMPL_IF -->
191
    <!-- /TMPL_IF -->
183
</p>
192
</p>
184
</div>
193
</div>
194
195
185
<!-- /TMPL_IF --></p><!-- /TMPL_IF --></div>
196
<!-- /TMPL_IF --></p><!-- /TMPL_IF --></div>
(-)a/kohaversion.pl (-1 / +1 lines)
Lines 10-16 Link Here
10
use strict;
10
use strict;
11
11
12
sub kohaversion {
12
sub kohaversion {
13
    our $VERSION = '3.01.00.124';
13
    our $VERSION = '3.01.00.xxx';
14
    # version needs to be set this way
14
    # version needs to be set this way
15
    # so that it can be picked up by Makefile.PL
15
    # so that it can be picked up by Makefile.PL
16
    # during install
16
    # during install
(-)a/opac/ilsdi.pl (-2 / +2 lines)
Lines 123-129 if ( not $cgi->param('service') ) { Link Here
123
        {   template_name   => "ilsdi.tmpl",
123
        {   template_name   => "ilsdi.tmpl",
124
            query           => $cgi,
124
            query           => $cgi,
125
            type            => "opac",
125
            type            => "opac",
126
            authnotrequired => 1,
126
            authnotrequired => (C4::Context->preference("OpacNotPublic") ? 0 : 1),
127
            debug           => 1,
127
            debug           => 1,
128
        }
128
        }
129
    );
129
    );
Lines 137-143 if ( $cgi->param('service') eq "Describe" and grep { $cgi->param('verb') eq $_ } Link Here
137
        {   template_name   => "ilsdi.tmpl",
137
        {   template_name   => "ilsdi.tmpl",
138
            query           => $cgi,
138
            query           => $cgi,
139
            type            => "opac",
139
            type            => "opac",
140
            authnotrequired => 1,
140
            authnotrequired => (C4::Context->preference("OpacNotPublic") ? 0 : 1),
141
            debug           => 1,
141
            debug           => 1,
142
        }
142
        }
143
    );
143
    );
(-)a/opac/maintenance.pl (-1 / +1 lines)
Lines 31-37 my ( $template, $borrowernumber, $cookie ) = get_template_and_user( Link Here
31
        template_name   => "maintenance.tmpl",
31
        template_name   => "maintenance.tmpl",
32
        type            => "opac",
32
        type            => "opac",
33
        query           => $input,
33
        query           => $input,
34
        authnotrequired => 1,
34
        authnotrequired => (C4::Context->preference("OpacNotPublic") ? 0 : 1),
35
        flagsrequired   => { borrow => 1 },
35
        flagsrequired   => { borrow => 1 },
36
    }
36
    }
37
);
37
);
(-)a/opac/opac-ISBDdetail.pl (-1 / +1 lines)
Lines 63-69 my ( $template, $loggedinuser, $cookie ) = get_template_and_user( Link Here
63
        template_name   => "opac-ISBDdetail.tmpl",
63
        template_name   => "opac-ISBDdetail.tmpl",
64
        query           => $query,
64
        query           => $query,
65
        type            => "opac",
65
        type            => "opac",
66
        authnotrequired => 1,
66
        authnotrequired => (C4::Context->preference("OpacNotPublic") ? 0 : 1),
67
        debug           => 1,
67
        debug           => 1,
68
    }
68
    }
69
);
69
);
(-)a/opac/opac-MARCdetail.pl (-1 / +1 lines)
Lines 67-73 my ( $template, $loggedinuser, $cookie ) = get_template_and_user( Link Here
67
        template_name   => "opac-MARCdetail.tmpl",
67
        template_name   => "opac-MARCdetail.tmpl",
68
        query           => $query,
68
        query           => $query,
69
        type            => "opac",
69
        type            => "opac",
70
        authnotrequired => 1,
70
        authnotrequired => (C4::Context->preference("OpacNotPublic") ? 0 : 1),
71
        debug           => 1,
71
        debug           => 1,
72
    }
72
    }
73
);
73
);
(-)a/opac/opac-addbybiblionumber.pl (-1 / +1 lines)
Lines 59-65 my ( $template, $loggedinuser, $cookie ) = get_template_and_user( Link Here
59
        template_name   => "opac-addbybiblionumber.tmpl",
59
        template_name   => "opac-addbybiblionumber.tmpl",
60
        query           => $query,
60
        query           => $query,
61
        type            => "opac",
61
        type            => "opac",
62
        authnotrequired => 1,
62
        authnotrequired => (C4::Context->preference("OpacNotPublic") ? 0 : 1),
63
    }
63
    }
64
);
64
);
65
65
(-)a/opac/opac-alert-subscribe.pl (-1 / +1 lines)
Lines 46-52 my $biblionumber = $query->param('biblionumber'); Link Here
46
        template_name   => "opac-alert-subscribe.tmpl",
46
        template_name   => "opac-alert-subscribe.tmpl",
47
        query           => $query,
47
        query           => $query,
48
        type            => "opac",
48
        type            => "opac",
49
        authnotrequired => 1,
49
        authnotrequired => (C4::Context->preference("OpacNotPublic") ? 0 : 1),
50
        debug           => 1,
50
        debug           => 1,
51
    }
51
    }
52
);
52
);
(-)a/opac/opac-authorities-home.pl (-2 / +2 lines)
Lines 75-81 if ( $op eq "do_search" ) { Link Here
75
            template_name   => "opac-authoritiessearchresultlist.tmpl",
75
            template_name   => "opac-authoritiessearchresultlist.tmpl",
76
            query           => $query,
76
            query           => $query,
77
            type            => 'opac',
77
            type            => 'opac',
78
            authnotrequired => 1,
78
            authnotrequired => (C4::Context->preference("OpacNotPublic") ? 0 : 1),
79
            debug           => 1,
79
            debug           => 1,
80
        }
80
        }
81
    );
81
    );
Lines 151-157 else { Link Here
151
            template_name   => "opac-authorities-home.tmpl",
151
            template_name   => "opac-authorities-home.tmpl",
152
            query           => $query,
152
            query           => $query,
153
            type            => 'opac',
153
            type            => 'opac',
154
            authnotrequired => 1,
154
            authnotrequired => (C4::Context->preference("OpacNotPublic") ? 0 : 1),
155
            debug           => 1,
155
            debug           => 1,
156
        }
156
        }
157
    );
157
    );
(-)a/opac/opac-authoritiesdetail.pl (-1 / +1 lines)
Lines 63-69 my ( $template, $loggedinuser, $cookie ) = get_template_and_user( Link Here
63
        template_name   => "opac-authoritiesdetail.tmpl",
63
        template_name   => "opac-authoritiesdetail.tmpl",
64
        query           => $query,
64
        query           => $query,
65
        type            => "opac",
65
        type            => "opac",
66
        authnotrequired => 1,
66
        authnotrequired => (C4::Context->preference("OpacNotPublic") ? 0 : 1),
67
        debug           => 1,
67
        debug           => 1,
68
    }
68
    }
69
);
69
);
(-)a/opac/opac-basket.pl (-1 / +1 lines)
Lines 32-38 my ( $template, $borrowernumber, $cookie ) = get_template_and_user ( Link Here
32
        template_name   => "opac-basket.tmpl",
32
        template_name   => "opac-basket.tmpl",
33
        query           => $query,
33
        query           => $query,
34
        type            => "opac",
34
        type            => "opac",
35
        authnotrequired => 1,
35
        authnotrequired => (C4::Context->preference("OpacNotPublic") ? 0 : 1),
36
        flagsrequired   => { borrow => 1 },
36
        flagsrequired   => { borrow => 1 },
37
    }
37
    }
38
);
38
);
(-)a/opac/opac-browser.pl (-1 / +1 lines)
Lines 44-50 my ( $template, $loggedinuser, $cookie ) = get_template_and_user( Link Here
44
        template_name   => "opac-browser.tmpl",
44
        template_name   => "opac-browser.tmpl",
45
        query           => $query,
45
        query           => $query,
46
        type            => "opac",
46
        type            => "opac",
47
        authnotrequired => 1,
47
        authnotrequired => (C4::Context->preference("OpacNotPublic") ? 0 : 1),
48
        debug           => 1,
48
        debug           => 1,
49
    }
49
    }
50
);
50
);
(-)a/opac/opac-detail.pl (-1 / +1 lines)
Lines 55-61 my ( $template, $borrowernumber, $cookie ) = get_template_and_user( Link Here
55
        template_name   => "opac-detail.tmpl",
55
        template_name   => "opac-detail.tmpl",
56
        query           => $query,
56
        query           => $query,
57
        type            => "opac",
57
        type            => "opac",
58
        authnotrequired => 1,
58
        authnotrequired => (C4::Context->preference("OpacNotPublic") ? 0 : 1),
59
        flagsrequired   => { borrow => 1 },
59
        flagsrequired   => { borrow => 1 },
60
    }
60
    }
61
);
61
);
(-)a/opac/opac-downloadcart.pl (-1 / +1 lines)
Lines 40-46 my ( $template, $borrowernumber, $cookie ) = get_template_and_user ( Link Here
40
        template_name   => "opac-downloadcart.tmpl",
40
        template_name   => "opac-downloadcart.tmpl",
41
        query           => $query,
41
        query           => $query,
42
        type            => "opac",
42
        type            => "opac",
43
        authnotrequired => 1,
43
        authnotrequired => (C4::Context->preference("OpacNotPublic") ? 0 : 1),
44
        flagsrequired   => { borrow => 1 },
44
        flagsrequired   => { borrow => 1 },
45
    }
45
    }
46
);
46
);
(-)a/opac/opac-downloadshelf.pl (-1 / +1 lines)
Lines 40-46 my ( $template, $borrowernumber, $cookie ) = get_template_and_user ( Link Here
40
        template_name   => "opac-downloadshelf.tmpl",
40
        template_name   => "opac-downloadshelf.tmpl",
41
        query           => $query,
41
        query           => $query,
42
        type            => "opac",
42
        type            => "opac",
43
        authnotrequired => 1,
43
        authnotrequired => (C4::Context->preference("OpacNotPublic") ? 0 : 1),
44
        flagsrequired   => { borrow => 1 },
44
        flagsrequired   => { borrow => 1 },
45
    }
45
    }
46
);
46
);
(-)a/opac/opac-main.pl (-1 / +1 lines)
Lines 36-42 my ( $template, $borrowernumber, $cookie ) = get_template_and_user( Link Here
36
        template_name   => "opac-main.tmpl",
36
        template_name   => "opac-main.tmpl",
37
        type            => "opac",
37
        type            => "opac",
38
        query           => $input,
38
        query           => $input,
39
        authnotrequired => 1,
39
        authnotrequired => (C4::Context->preference("OpacNotPublic") ? 0 : 1),
40
        flagsrequired   => { borrow => 1 },
40
        flagsrequired   => { borrow => 1 },
41
    }
41
    }
42
);
42
);
(-)a/opac/opac-review.pl (-1 / +1 lines)
Lines 36-42 my ( $template, $borrowernumber, $cookie ) = get_template_and_user( Link Here
36
        template_name   => "opac-review.tmpl",
36
        template_name   => "opac-review.tmpl",
37
        query           => $query,
37
        query           => $query,
38
        type            => "opac",
38
        type            => "opac",
39
        authnotrequired => 1,
39
        authnotrequired => (C4::Context->preference("OpacNotPublic") ? 0 : 1),
40
    }
40
    }
41
);
41
);
42
42
(-)a/opac/opac-search-history.pl (-1 / +1 lines)
Lines 40-46 my ($template, $loggedinuser, $cookie) Link Here
40
= get_template_and_user({template_name => "opac-search-history.tmpl",
40
= get_template_and_user({template_name => "opac-search-history.tmpl",
41
                                query => $cgi,
41
                                query => $cgi,
42
                                type => "opac",
42
                                type => "opac",
43
                                authnotrequired => 1,
43
                                authnotrequired => (C4::Context->preference("OpacNotPublic") ? 0 : 1),
44
                                flagsrequired => {borrowers => 1},
44
                                flagsrequired => {borrowers => 1},
45
                                debug => 1,
45
                                debug => 1,
46
                                });
46
                                });
(-)a/opac/opac-search.pl (-1 / +1 lines)
Lines 79-85 else { Link Here
79
    template_name => $template_name,
79
    template_name => $template_name,
80
    query => $cgi,
80
    query => $cgi,
81
    type => "opac",
81
    type => "opac",
82
    authnotrequired => 1,
82
    authnotrequired => (C4::Context->preference("OpacNotPublic") ? 0 : 1),
83
    }
83
    }
84
);
84
);
85
85
(-)a/opac/opac-sendbasket.pl (-1 / +1 lines)
Lines 62-68 if ( $email_add ) { Link Here
62
            template_name   => "opac-sendbasket.tmpl",
62
            template_name   => "opac-sendbasket.tmpl",
63
            query           => $query,
63
            query           => $query,
64
            type            => "opac",
64
            type            => "opac",
65
            authnotrequired => 1,
65
            authnotrequired => (C4::Context->preference("OpacNotPublic") ? 0 : 1),
66
            flagsrequired   => { borrow => 1 },
66
            flagsrequired   => { borrow => 1 },
67
        }
67
        }
68
    );
68
    );
(-)a/opac/opac-sendshelf.pl (-2 / +2 lines)
Lines 40-46 my ( $template, $borrowernumber, $cookie ) = get_template_and_user ( Link Here
40
        template_name   => "opac-sendshelfform.tmpl",
40
        template_name   => "opac-sendshelfform.tmpl",
41
        query           => $query,
41
        query           => $query,
42
        type            => "opac",
42
        type            => "opac",
43
        authnotrequired => 1,
43
        authnotrequired => (C4::Context->preference("OpacNotPublic") ? 0 : 1),
44
        flagsrequired   => { borrow => 1 },
44
        flagsrequired   => { borrow => 1 },
45
    }
45
    }
46
);
46
);
Lines 64-70 if ( $email ) { Link Here
64
            template_name   => "opac-sendshelf.tmpl",
64
            template_name   => "opac-sendshelf.tmpl",
65
            query           => $query,
65
            query           => $query,
66
            type            => "opac",
66
            type            => "opac",
67
            authnotrequired => 1,
67
            authnotrequired => (C4::Context->preference("OpacNotPublic") ? 0 : 1),
68
            flagsrequired   => { borrow => 1 },
68
            flagsrequired   => { borrow => 1 },
69
        }
69
        }
70
    );
70
    );
(-)a/opac/opac-serial-issues.pl (-2 / +2 lines)
Lines 48-54 if ( $selectview eq "full" ) { Link Here
48
            template_name   => "opac-full-serial-issues.tmpl",
48
            template_name   => "opac-full-serial-issues.tmpl",
49
            query           => $query,
49
            query           => $query,
50
            type            => "opac",
50
            type            => "opac",
51
            authnotrequired => 1,
51
            authnotrequired => (C4::Context->preference("OpacNotPublic") ? 0 : 1),
52
            debug           => 1,
52
            debug           => 1,
53
        }
53
        }
54
    );
54
    );
Lines 86-92 else { Link Here
86
            template_name   => "opac-serial-issues.tmpl",
86
            template_name   => "opac-serial-issues.tmpl",
87
            query           => $query,
87
            query           => $query,
88
            type            => "opac",
88
            type            => "opac",
89
            authnotrequired => 1,
89
            authnotrequired => (C4::Context->preference("OpacNotPublic") ? 0 : 1),
90
            debug           => 1,
90
            debug           => 1,
91
        }
91
        }
92
    );
92
    );
(-)a/opac/opac-shelves.pl (-1 / +1 lines)
Lines 29-35 my ( $template, $loggedinuser, $cookie ) = get_template_and_user({ Link Here
29
        template_name   => "opac-shelves.tmpl",
29
        template_name   => "opac-shelves.tmpl",
30
        query           => $query,
30
        query           => $query,
31
        type            => "opac",
31
        type            => "opac",
32
        authnotrequired => 1,
32
        authnotrequired => (C4::Context->preference("OpacNotPublic") ? 0 : 1),
33
    });
33
    });
34
$template->param(listsview => 1);
34
$template->param(listsview => 1);
35
# if $loggedinuser is not defined, set it to -1, which should
35
# if $loggedinuser is not defined, set it to -1, which should
(-)a/opac/opac-showmarc.pl (-1 / +1 lines)
Lines 48-54 my ( $template, $loggedinuser, $cookie ) = get_template_and_user({ Link Here
48
        template_name   => "opac-showmarc.tmpl",
48
        template_name   => "opac-showmarc.tmpl",
49
        query           => $input,
49
        query           => $input,
50
        type            => "opac",
50
        type            => "opac",
51
        authnotrequired => 1,
51
        authnotrequired => (C4::Context->preference("OpacNotPublic") ? 0 : 1),
52
        debug           => 1,
52
        debug           => 1,
53
});
53
});
54
54
(-)a/opac/opac-showreviews.pl (-1 / +1 lines)
Lines 34-40 my ( $template, $borrowernumber, $cookie ) = &get_template_and_user( Link Here
34
        template_name   => "opac-showreviews.tmpl",
34
        template_name   => "opac-showreviews.tmpl",
35
        query           => $query,
35
        query           => $query,
36
        type            => "opac",
36
        type            => "opac",
37
        authnotrequired => 1,
37
        authnotrequired => (C4::Context->preference("OpacNotPublic") ? 0 : 1),
38
    }
38
    }
39
);
39
);
40
40
(-)a/opac/opac-suggestions.pl (-1 / +1 lines)
Lines 44-50 if ( C4::Context->preference("AnonSuggestions") ) { Link Here
44
            template_name   => "opac-suggestions.tmpl",
44
            template_name   => "opac-suggestions.tmpl",
45
            query           => $input,
45
            query           => $input,
46
            type            => "opac",
46
            type            => "opac",
47
            authnotrequired => 1,
47
            authnotrequired => (C4::Context->preference("OpacNotPublic") ? 0 : 1),
48
        }
48
        }
49
    );
49
    );
50
    if ( !$$suggestion{suggestedby} ) {
50
    if ( !$$suggestion{suggestedby} ) {
(-)a/opac/opac-tags.pl (-1 / +1 lines)
Lines 107-113 if ($is_ajax) { Link Here
107
		template_name   => "opac-tags.tmpl",
107
		template_name   => "opac-tags.tmpl",
108
		query           => $query,
108
		query           => $query,
109
		type            => "opac",
109
		type            => "opac",
110
		authnotrequired => ($add_op ? 0 : 1),	# auth required to add tags
110
        authnotrequired => ($add_op && C4::Context->preference("OpacNotPublic") ? 0 : 1),  # auth required to add tags
111
		debug           => 1,
111
		debug           => 1,
112
	});
112
	});
113
}
113
}
(-)a/opac/opac-tags_subject.pl (-1 / +1 lines)
Lines 44-50 my ( $template, $loggedinuser, $cookie ) = get_template_and_user( Link Here
44
        template_name   => "opac-tags_subject.tmpl",
44
        template_name   => "opac-tags_subject.tmpl",
45
        query           => $query,
45
        query           => $query,
46
        type            => "opac",
46
        type            => "opac",
47
        authnotrequired => 1,
47
        authnotrequired => (C4::Context->preference("OpacNotPublic") ? 0 : 1),
48
        debug           => 1,
48
        debug           => 1,
49
    }
49
    }
50
);
50
);
(-)a/opac/opac-topissues.pl (-1 / +1 lines)
Lines 48-54 my ($template, $borrowernumber, $cookie) Link Here
48
	= get_template_and_user({template_name => 'opac-topissues.tmpl',
48
	= get_template_and_user({template_name => 'opac-topissues.tmpl',
49
				query => $input,
49
				query => $input,
50
				type => "opac",
50
				type => "opac",
51
				authnotrequired => 1,
51
				authnotrequired => (C4::Context->preference("OpacNotPublic") ? 0 : 1),
52
				debug => 1,
52
				debug => 1,
53
				});
53
				});
54
my $dbh = C4::Context->dbh;
54
my $dbh = C4::Context->dbh;
(-)a/opac/opac-userupdate.pl (-1 / +1 lines)
Lines 66-72 if ( !$updateemailaddress || $updateemailaddress eq '' ) { Link Here
66
            template_name   => "kohaerror.tmpl",
66
            template_name   => "kohaerror.tmpl",
67
            query           => $query,
67
            query           => $query,
68
            type            => "opac",
68
            type            => "opac",
69
            authnotrequired => 1,
69
            authnotrequired => (C4::Context->preference("OpacNotPublic") ? 0 : 1),
70
            flagsrequired   => { borrow => 1 },
70
            flagsrequired   => { borrow => 1 },
71
            debug           => 1,
71
            debug           => 1,
72
        }
72
        }

Return to bug 4289