[Bug 28650] New: Assumed branchcode variable appears to be empty
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=28650 Bug ID: 28650 Summary: Assumed branchcode variable appears to be empty Change sponsored?: --- Product: Koha Version: master Hardware: All OS: All Status: NEW Severity: normal Priority: P5 - low Component: Templates Assignee: oleonard@myacpl.org Reporter: m.de.rooy@rijksmuseum.nl QA Contact: testopia@bugs.koha-community.org Found on bug 27948, but it occurs more often. We expect the variable branchcode in the template just like e.g. the lang variable. And we use it in a call to KohaNews.get. Example from opac-suggestions template: [% SET opacsuggestion = KohaNews.get( location => "OpacSuggestioninstructions", lang => lang, library => branchcode ) %] But unfortunately we do not have a general branchcode variable. So what we get is the All branches output, not the branch one. Should we fill branchcode in Auth.pm? Or call Branches.GetLoggedInBranchcode in the template? -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=28650 --- Comment #1 from Marcel de Rooy <m.de.rooy@rijksmuseum.nl> --- Some spots to consider: git grep "KohaNews.get" Koha/Template/Plugin/KohaNews.pm:[% KohaNews.get() %] Koha/Template/Plugin/KohaNews.pm:the following TT code: [% KohaNews.get() %] koha-tmpl/opac-tmpl/bootstrap/en/includes/masthead-sci.inc:[% SET OpacHeader = KohaNews.get( location => "opacheader", lang => lang, library => branchcode, blocktitle => 0 ) %] koha-tmpl/opac-tmpl/bootstrap/en/includes/masthead-sco.inc:[% SET OpacHeader = KohaNews.get( location => "opacheader", lang => lang, library => branchcode, blocktitle => 0 ) %] koha-tmpl/opac-tmpl/bootstrap/en/includes/masthead.inc:[% SET OpacHeader = KohaNews.get( location => "opacheader", lang => lang, library => branchcode, blocktitle => 0 ) %] koha-tmpl/opac-tmpl/bootstrap/en/includes/masthead.inc:[% SET OpacCustomSearch = KohaNews.get( location => "OpacCustomSearch", lang => lang, library => branchcode, blocktitle => 0 ) %] koha-tmpl/opac-tmpl/bootstrap/en/includes/masthead.inc:[% SET OpacLoginInstructions = KohaNews.get( location => "OpacLoginInstructions", lang => lang, library => branchcode ) %] koha-tmpl/opac-tmpl/bootstrap/en/includes/opac-bottom.inc:[% SET opaccredits = KohaNews.get( location => "opaccredits", lang => lang, library => branchcode ) %] koha-tmpl/opac-tmpl/bootstrap/en/modules/maintenance.tt:[% SET OpacHeader = KohaNews.get( location => "opacheader", lang => lang, library => branchcode, blocktitle => 0 ) %] koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-auth.tt:[% SET OpacLoginInstructions = KohaNews.get( location => "OpacLoginInstructions", lang => lang, library => branchcode ) %] koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-main.tt:[% SET OpacNavRight = KohaNews.get( location => "OpacNavRight", lang => lang, library => branchcode ) %] koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-main.tt:[% SET OpacMainUserBlock = KohaNews.get( location => "OpacMainUserBlock", lang => lang, library => branchcode ) %] koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-main.tt:[% SET OpacLoginInstructions = KohaNews.get( location => "OpacLoginInstructions", lang => lang, library => branchcode ) %] koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-registration-confirmation.tt:[% SET OpacNavRight = KohaNews.get( location => "OpacNavRight", lang => news_lang, library => branchcode ) %] koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-request-article.tt:[% SET disclaimer = KohaNews.get( location => "ArticleRequestsDisclaimerText", lang => lang, library => branchcode ) %] koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-suggestions.tt:[% SET opacsuggestion = KohaNews.get( location => "OpacSuggestioninstructions", lang => lang, library => branchcode ) %] koha-tmpl/opac-tmpl/bootstrap/en/modules/sci/sci-main.tt:[% SET OpacHeader = KohaNews.get( location => "opacheader", lang => lang, library => branchcode, blocktitle => 0 ) %] -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=28650 Marcel de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- See Also| |https://bugs.koha-community | |.org/bugzilla3/show_bug.cgi | |?id=27948 -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=28650 --- Comment #2 from Marcel de Rooy <m.de.rooy@rijksmuseum.nl> --- Decided to fix the call in koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-request-article.tt (bug 27948) by calling GetBranches. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=28650 Marcel de Rooy <m.de.rooy@rijksmuseum.nl> changed: What |Removed |Added ---------------------------------------------------------------------------- See Also| |https://bugs.koha-community | |.org/bugzilla3/show_bug.cgi | |?id=28597 -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=28650 Jonathan Druart <jonathan.druart+koha@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Depends on| |22880 CC| |jonathan.druart+koha@gmail. | |com --- Comment #3 from Jonathan Druart <jonathan.druart+koha@gmail.com> --- Owen, can you have a look at this please? Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=22880 [Bug 22880] Convert opacheader system preference to news block -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=28650 Owen Leonard <oleonard@myacpl.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Resolution|--- |DUPLICATE Status|NEW |RESOLVED --- Comment #4 from Owen Leonard <oleonard@myacpl.org> --- I believe this issue is fixed by Bug 24223. *** This bug has been marked as a duplicate of bug 24223 *** -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org