]> git.koha-community.org Git - koha.git/commit
Bug 15039: Move top language menu to include and streamline logic
authorMarc Véron <veron@veron.ch>
Tue, 20 Oct 2015 15:03:16 +0000 (17:03 +0200)
committerTomas Cohen Arazi <tomascohen@theke.io>
Thu, 22 Oct 2015 14:53:42 +0000 (11:53 -0300)
commit17b3e3c9ebb4ce437a56cee817ee1781ebfce697
tree135fc8df43f405ff9a70f7e199109259a86d2ac0
parent986cbaf830923ce75d396e1a2d87ae8f029f4be9
Bug 15039: Move top language menu to include and streamline logic

The language menu in koha-tmpl/opac-tmpl/bootstrap/en/includes/masthead.inc is used at other places as well (see Bug 14776).

This patch moves it to a file masthead-langmenu.inc to make it re-usable.

Additionally it streamlines the logic (not all combinations of Opac sysprefs that should display the menu did so).

To test:
- Apply patch
- Verify, that the language menu displays / does not display with combinations of:
  - opaclanguagedisplay (Allow)
  - opaclanguages ( > 1 language selected)
  - OpacLangSelectorMode (top or both)
- Verify that sysprefs opacuserlogin and EnableOpacSearchHistory do not interfere
  with the lenguage menu (before, at least one of them had to be on to display the menu)
- Verify that language switching works as before.

Signed-off-by: Chris Kirby <christopherlawrencekirby@gmail.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
koha-tmpl/opac-tmpl/bootstrap/en/includes/masthead-langmenu.inc [new file with mode: 0644]
koha-tmpl/opac-tmpl/bootstrap/en/includes/masthead.inc