Class MenuSearchController

java.lang.Object
org.adempiere.webui.apps.MenuSearchController
All Implemented Interfaces:
org.zkoss.zk.ui.event.EventListener<org.zkoss.zk.ui.event.Event>

public class MenuSearchController extends Object implements org.zkoss.zk.ui.event.EventListener<org.zkoss.zk.ui.event.Event>
Controller for search on AD_Menu records.
Author:
hengsin
  • Field Details

  • Constructor Details

    • MenuSearchController

      public MenuSearchController(org.zkoss.zul.Tree tree)
      Parameters:
      tree - usually the tree instance from MenuTreePanel
  • Method Details

    • updateRecentItems

      public void updateRecentItems()
      If there are changes in the recent menu items for user, reload and update menu items model
    • refreshModel

      public void refreshModel()
      Populate model from tree
    • create

      public void create(org.zkoss.zk.ui.Component parent)
      Call refreshModel() and layout UI.
      Parameters:
      parent -
    • onEvent

      public void onEvent(org.zkoss.zk.ui.event.Event event) throws Exception
      Specified by:
      onEvent in interface org.zkoss.zk.ui.event.EventListener<org.zkoss.zk.ui.event.Event>
      Throws:
      Exception
    • search

      public void search(String value)
      Echo ON_SEARCH_ECHO_EVENT to initial search with value.
      Parameters:
      value -
    • onSearchEcho

      public void onSearchEcho(String value)
      Handle ON_SEARCH_ECHO_EVENT event.
      Parameters:
      value -
    • selectPrior

      public MenuItem selectPrior()
      Select ListItem that comes before the current selected ListItem.
      Returns:
      new selected MenuItem
    • selectNext

      public MenuItem selectNext()
      Select ListItem that comes after the current selected ListItem.
      Returns:
      new selected MenuItem
    • onOk

      public boolean onOk(org.zkoss.zul.Textbox textbox)
      Handle ON_OK event
      Parameters:
      textbox -
      Returns:
      true if there's partial or exact match for textbox value
    • setHighlightText

      public void setHighlightText(String s)
      Set text to highlight
      Parameters:
      s -