Class MenuTemplateBean

    • Constructor Detail

      • MenuTemplateBean

        public MenuTemplateBean()
    • Method Detail

      • init

        @PostConstruct
        public void init()
      • initMainMenu

        public void initMainMenu()
      • isAllowed

        public boolean isAllowed​(EAccessProperty... accessProperties)
      • isAllowed

        public boolean isAllowed​(IAccessProperty... customProperties)
      • isAllowed

        public boolean isAllowed​(IViewModel view)
      • addMainMenuEntry

        public void addMainMenuEntry​(CustomViewModel customView)
      • getMainMenuModel

        public org.primefaces.model.menu.MenuModel getMainMenuModel()
        Returns:
        Creates the MenuModel for the menu component, based on the current getMainMenuEntries(). This allows for dynamic menu entries and should be used in favor of c:forEach, which has issues when the menu entries change dynamically.
      • getByView

        public IMenuEntryModel getByView​(IViewModel view)
        Returns:
        The menu entry for the given view. null, if no such entry exists.
      • getClientDashboardEntries

        public List<IMenuEntryModel> getClientDashboardEntries()
        Returns:
        The menu entries that are to be shown on the (client) dashboard, in the correct order.
      • getAdminDashboardEntries

        public List<IMenuEntryModel> getAdminDashboardEntries​(@Nullable
                                                              EAdminDashCategory category)
        Parameters:
        category - If given, only returns entries for that category. Iff null, returns all entries for the admin dashboard.
        Returns:
        The menu entries that are to be shown on the (admin) dashboard, in the correct order.
      • getSerenityMenuCookie

        public String getSerenityMenuCookie​(IViewModel currentView,
                                            String idPrefix)
        Parameters:
        currentView - View for which to get the cookie.
        Returns:
        Value of the cookie the Serenity menu uses for storing the currently selected menu entry.