Uploaded image for project: 'Runtime'
  1. Runtime
  2. RUNTIME-2786

SimpleMenu needs proper support of contextual gallery and menu items

    • Icon: Improvement Improvement
    • Resolution: Unresolved
    • Icon: Major Major
    • 4.LATER
    • None
    • None
    • None
    • 2 - Long term
    • 2 - Normal

      Currently, the org.ametys.core.ui.SimpleMenu has 1 components manager for its items, which are both attributes of the class and loaded only once.

      If we want a gallery or menu that depends on the context, such as the current skin in the web, we have to destroy and recreate the ComponentManager each time we load it. See org.ametys.web.clientsideelement.TemplatesMenu._lazyInitializeTemplateGallery and  org.ametys.plugins.newsletter.category.TemplatesMenu._lazyInitializeTemplateGallery for classes awaiting a FIXME

       

      We could possibly change the _getGalleryItems and _getMenuItems API to pass the List<ClientSideElement> instead of using a class attribute. We could also add a web implementation of a smart cache by skin reloaded on skin updates of the ClientSideElements, 

          [RUNTIME-2786] SimpleMenu needs proper support of contextual gallery and menu items

          There are no comments yet on this issue.

            Unassigned Unassigned
            glefebvre Grégory Lefebvre (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated: