Open acquaalta opened 3 months ago
We have also this problem and we run Moodle ver 4.3.2 and plugin ver v4.3-r13. I have tested with the language restriction on the top level and sometimes got the menu item in several languages. I have not been able to identify why this happens either, unfortunately. It's not happening in the same session though. I have seen the error when I logged in anew maybe 1 h later.
Hi @anna-sparkfore It's "good" to know that we didn't "imagine" this bug. I hope that it will be solved at some point. Thanks for your comment :-)
Hi @acquaalta and @anna-sparkfore
could you provide some more information on this? We've had this same mistake in previous Moodle and theme versions (now on Moodle 4.4.2, Boost Union v4.4-r1) but as you said were never able to reproduce it reliably. For now I remember the following details on the problem, could you provide steps to reproduce or check if this fits with your settings so we can hopefully nail this down to a particular combination?
Menu mode: inline Presentation type: list Menu item type: static
Login as admin
create new smart menu under /theme/boost_union/smartmenus/menus.php with the following setting Menu mode: inline Presentation type: list restrict visibility by language (e.g. German) Menu item type: static (in our case we linked to a particular course in the system restrict visibility by language (e.g. German) for menu item
duplicate the whole thing
change restrict visibility by language (to English) in the duplicate for the menu and for the item
What happened was that the original menu would appear twice for mainly admins and users logged in as managers, probably after having changed the systems language a few times to test, varying with browsers.
Does this procedure ring a bell with you? Please add more or altering steps if possible, thank you!
This happens, after visiting courses with forced language. i.e. My prefered system language is russian, I see Russian language. If i visit a course with forced English, both RU and En menues display
Hi @wiebkemueller-hsh, We experience the bug with different settings: Menu mode: Submenu Presentation type: List Menu location: Main Navigation Menu item type: Dynamic courses Access rules: By language
Here's a fresh example: I log in and the interface is in Swedish but there are 2 menu items showing:
I visit the Preferred language page to verify that my selected language is Swedish:
In Smart menues I have 2 items: Admin shortcuts in Swedish and English. Menu location(s): Main navigation Menu mode: Submenu Presentation type: List Restrict visibility by roles: Manager Restrict visibility by language: Swedish - English (one per each)
The menu items are static and have no additional restrictions:
I then used the Language selector to switch language to English (which is a temporary language switch). Then the interface reloads and only the Smart menu in English is shown, now the Swedish menu is hidden.
I then logged out, and logged in again. Now only the Smart menu in Swedish appears.
Is there an issue with having 2 restrictions (user role = manager + language = English/Swedish) on a Smart menu? How would you recommend the setup for that scenario?
Also, I just realized a detail that might be related. We use a child language pack "sv_wp" instead of sv AND we have a customized language menu to avoid having 2 Swedish options in the language selector:
Thank you for the detailed examples and documentation on this, we will try to figure something out.
Hello everyone, We have encountered exactly the same problem. We have noticed that the problem always occurs when you log out and are only logged in as a guest. If you visit the course page and change the language, both smart menus are displayed. If you then log in again as admin, you have the same problem. Otherwise the problem seems to occur almost randomly.
we tested the plugin versions v4.3-r13 (2023102038) and v4.3-r15 (2023102042)
Hi,
Moodle version: 4.3.5 Plugin version: v4.3-r13 (2023102038)
We have a couple of smart menus that their visibility is restricted by language. Since the UI is in one specific language at any given time, only one of these smart menus should be displayed. The issue is that sometimes, and I don't understand why and when exactly, we get to see two smart menus at the same time. It's is unwanted, of course, and a duplication of a menu since the content in both menus is the same.
Did you encounter such an issue?