Class CMSSidebarWidgetsBean

java.lang.Object
io.goobi.viewer.managedbeans.CMSSidebarWidgetsBean
All Implemented Interfaces:
Serializable

@Named("cmsSidebarWidgetsBean") @RequestScoped public class CMSSidebarWidgetsBean extends Object implements Serializable
JSF backing bean that manages sidebar widget configuration for CMS pages.
See Also:
  • Field Details

    • MAX_DESCRIPTION_LENGTH

      public static final int MAX_DESCRIPTION_LENGTH
      See Also:
  • Constructor Details

    • CMSSidebarWidgetsBean

      public CMSSidebarWidgetsBean()
  • Method Details

    • getAllWidgets

      public List<WidgetDisplayElement> getAllWidgets() throws DAOException
      getAllWidgets.
      Returns:
      the list of all sidebar widget display elements (default, automatic, and custom)
      Throws:
      DAOException - if any.
    • getAllWidgets

      public List<WidgetDisplayElement> getAllWidgets(boolean queryAdditionalInformation) throws DAOException
      getAllWidgets.
      Parameters:
      queryAdditionalInformation - if true, queries embedding pages for each widget
      Returns:
      the list of all sidebar widget display elements, optionally with embedding page information
      Throws:
      DAOException - if any.
    • getEmbeddingPages

      public static List<CMSPage> getEmbeddingPages(CustomSidebarWidget widget)
    • deleteWidget

      public void deleteWidget(Long id) throws DAOException
      deleteWidget.
      Parameters:
      id - database ID of the custom widget to delete
      Throws:
      DAOException - if any.
    • getSidebarGroup

      public HtmlPanelGroup getSidebarGroup(List<CMSSidebarElement> elements, CMSPage page)
      Getter for the field sidebarGroup.
      Parameters:
      elements - ordered list of sidebar elements to render
      page - CMS page owning the sidebar elements
      Returns:
      the HtmlPanelGroup containing the rendered sidebar widget components
    • getSidebarGroup

      public HtmlPanelGroup getSidebarGroup()
      Getter for the field sidebarGroup.
      Returns:
      the HtmlPanelGroup for the current CMS page's sidebar, or an empty group if no page is active
    • setSidebarGroup

      public void setSidebarGroup(HtmlPanelGroup sidebarGroup)
      Setter for the field sidebarGroup.
      Parameters:
      sidebarGroup - panel group to set as the sidebar container