Lines 383-388
sub get_template_and_user {
Link Here
|
383 |
my $opac_name = ''; |
383 |
my $opac_name = ''; |
384 |
if (($opac_search_limit && $opac_search_limit =~ /branch:(\w+)/ && $opac_limit_override) || ($in->{'query'}->param('limit') && $in->{'query'}->param('limit') =~ /branch:(\w+)/)){ |
384 |
if (($opac_search_limit && $opac_search_limit =~ /branch:(\w+)/ && $opac_limit_override) || ($in->{'query'}->param('limit') && $in->{'query'}->param('limit') =~ /branch:(\w+)/)){ |
385 |
$opac_name = $1; # opac_search_limit is a branch, so we use it. |
385 |
$opac_name = $1; # opac_search_limit is a branch, so we use it. |
|
|
386 |
} elsif ( $in->{'query'}->param('multibranchlimit') ) { |
387 |
$opac_name = $in->{'query'}->param('multibranchlimit'); |
386 |
} elsif (C4::Context->preference("SearchMyLibraryFirst") && C4::Context->userenv && C4::Context->userenv->{'branch'}) { |
388 |
} elsif (C4::Context->preference("SearchMyLibraryFirst") && C4::Context->userenv && C4::Context->userenv->{'branch'}) { |
387 |
$opac_name = C4::Context->userenv->{'branch'}; |
389 |
$opac_name = C4::Context->userenv->{'branch'}; |
388 |
} |
390 |
} |
Lines 391-403
sub get_template_and_user {
Link Here
|
391 |
AnonSuggestions => "" . C4::Context->preference("AnonSuggestions"), |
393 |
AnonSuggestions => "" . C4::Context->preference("AnonSuggestions"), |
392 |
AuthorisedValueImages => C4::Context->preference("AuthorisedValueImages"), |
394 |
AuthorisedValueImages => C4::Context->preference("AuthorisedValueImages"), |
393 |
BranchesLoop => GetBranchesLoop($opac_name), |
395 |
BranchesLoop => GetBranchesLoop($opac_name), |
394 |
CalendarFirstDayOfWeek => (C4::Context->preference("CalendarFirstDayOfWeek") eq "Sunday")?0:1, |
396 |
BranchCategoriesLoop => GetBranchCategories( undef, undef, 1, $opac_name ), |
|
|
397 |
CalendarFirstDayOfWeek => (C4::Context->preference("CalendarFirstDayOfWeek") eq "Sunday")?0:1, |
395 |
LibraryName => "" . C4::Context->preference("LibraryName"), |
398 |
LibraryName => "" . C4::Context->preference("LibraryName"), |
396 |
LibraryNameTitle => "" . $LibraryNameTitle, |
399 |
LibraryNameTitle => "" . $LibraryNameTitle, |
397 |
LoginBranchname => C4::Context->userenv?C4::Context->userenv->{"branchname"}:"", |
400 |
LoginBranchname => C4::Context->userenv?C4::Context->userenv->{"branchname"}:"", |
398 |
OPACAmazonCoverImages => C4::Context->preference("OPACAmazonCoverImages"), |
401 |
OPACAmazonCoverImages => C4::Context->preference("OPACAmazonCoverImages"), |
399 |
OPACFRBRizeEditions => C4::Context->preference("OPACFRBRizeEditions"), |
402 |
OPACFRBRizeEditions => C4::Context->preference("OPACFRBRizeEditions"), |
400 |
OpacHighlightedWords => C4::Context->preference("OpacHighlightedWords"), |
403 |
OpacHighlightedWords => C4::Context->preference("OpacHighlightedWords"), |
401 |
OPACItemHolds => C4::Context->preference("OPACItemHolds"), |
404 |
OPACItemHolds => C4::Context->preference("OPACItemHolds"), |
402 |
OPACShelfBrowser => "". C4::Context->preference("OPACShelfBrowser"), |
405 |
OPACShelfBrowser => "". C4::Context->preference("OPACShelfBrowser"), |
403 |
OpacShowRecentComments => C4::Context->preference("OpacShowRecentComments"), |
406 |
OpacShowRecentComments => C4::Context->preference("OpacShowRecentComments"), |
Lines 408-414
sub get_template_and_user {
Link Here
|
408 |
OpacAuthorities => C4::Context->preference("OpacAuthorities"), |
411 |
OpacAuthorities => C4::Context->preference("OpacAuthorities"), |
409 |
OPACBaseURL => ($in->{'query'}->https() ? "https://" : "http://") . $ENV{'SERVER_NAME'} . |
412 |
OPACBaseURL => ($in->{'query'}->https() ? "https://" : "http://") . $ENV{'SERVER_NAME'} . |
410 |
($ENV{'SERVER_PORT'} eq ($in->{'query'}->https() ? "443" : "80") ? '' : ":$ENV{'SERVER_PORT'}"), |
413 |
($ENV{'SERVER_PORT'} eq ($in->{'query'}->https() ? "443" : "80") ? '' : ":$ENV{'SERVER_PORT'}"), |
411 |
opac_css_override => $ENV{'OPAC_CSS_OVERRIDE'}, |
414 |
opac_css_override => $ENV{'OPAC_CSS_OVERRIDE'}, |
412 |
opac_search_limit => $opac_search_limit, |
415 |
opac_search_limit => $opac_search_limit, |
413 |
opac_limit_override => $opac_limit_override, |
416 |
opac_limit_override => $opac_limit_override, |
414 |
OpacBrowser => C4::Context->preference("OpacBrowser"), |
417 |
OpacBrowser => C4::Context->preference("OpacBrowser"), |
Lines 422-428
sub get_template_and_user {
Link Here
|
422 |
OpacNavRight => "" . C4::Context->preference("OpacNavRight"), |
425 |
OpacNavRight => "" . C4::Context->preference("OpacNavRight"), |
423 |
OpacNavBottom => "" . C4::Context->preference("OpacNavBottom"), |
426 |
OpacNavBottom => "" . C4::Context->preference("OpacNavBottom"), |
424 |
OpacPasswordChange => C4::Context->preference("OpacPasswordChange"), |
427 |
OpacPasswordChange => C4::Context->preference("OpacPasswordChange"), |
425 |
OPACPatronDetails => C4::Context->preference("OPACPatronDetails"), |
428 |
OPACPatronDetails => C4::Context->preference("OPACPatronDetails"), |
426 |
OPACPrivacy => C4::Context->preference("OPACPrivacy"), |
429 |
OPACPrivacy => C4::Context->preference("OPACPrivacy"), |
427 |
OPACFinesTab => C4::Context->preference("OPACFinesTab"), |
430 |
OPACFinesTab => C4::Context->preference("OPACFinesTab"), |
428 |
OpacTopissue => C4::Context->preference("OpacTopissue"), |
431 |
OpacTopissue => C4::Context->preference("OpacTopissue"), |