Class WChartEditor

java.lang.Object
org.adempiere.webui.editor.WEditor
org.adempiere.webui.editor.WChartEditor
All Implemented Interfaces:
PropertyChangeListener, EventListener, IInputValidator, org.zkoss.zk.ui.event.EventListener<org.zkoss.zk.ui.event.Event>

public class WChartEditor extends WEditor
Default editor for DisplayType.Chart.
A readonly editor that render chart from MChart model to Panel component.
Author:
Low Heng Sin Modifications - chart display, Paul Bowden, Adaxa Pty Ltd
  • Constructor Details

    • WChartEditor

      public WChartEditor(GridField gridField, int windowNo)
      Parameters:
      gridField -
      windowNo -
    • WChartEditor

      public WChartEditor(GridField gridField, int windowNo, boolean tableEditor, IEditorConfiguration editorConfiguration)
      Parameters:
      gridField -
      windowNo -
      tableEditor -
      editorConfiguration -
  • Method Details

    • getComponent

      public org.zkoss.zul.Panel getComponent()
      Overrides:
      getComponent in class WEditor
      Returns:
      Component
    • getDisplay

      public String getDisplay()
      Specified by:
      getDisplay in class WEditor
      Returns:
      X_AD_Chart.getName()
    • getValue

      public Object getValue()
      Always return null
      Specified by:
      getValue in class WEditor
      Returns:
      Object, current value of editor
    • isMandatory

      public boolean isMandatory()
      Overrides:
      isMandatory in class WEditor
      Returns:
      true if field is mandatory
    • setMandatory

      public void setMandatory(boolean mandatory)
      No op.
      Overrides:
      setMandatory in class WEditor
      Parameters:
      mandatory - whether the field is mandatory
    • isReadWrite

      public boolean isReadWrite()
      Always return true
      Specified by:
      isReadWrite in class WEditor
      Returns:
      true if editable
    • setReadWrite

      public void setReadWrite(boolean readWrite)
      No op.
      Specified by:
      setReadWrite in class WEditor
    • setValue

      public void setValue(Object value)
      No op.
      Specified by:
      setValue in class WEditor
    • getEvents

      public String[] getEvents()
      Overrides:
      getEvents in class WEditor
      Returns:
      list of WEditor.component events that this editor will listen to
    • onEvent

      public void onEvent(org.zkoss.zk.ui.event.Event event) throws Exception
      Throws:
      Exception
    • dynamicDisplay

      public void dynamicDisplay()
      Call createChart() to re-render chart.
      Overrides:
      dynamicDisplay in class WEditor
    • isSearchable

      public boolean isSearchable()
      Overrides:
      isSearchable in class WEditor
      Returns:
      true if usable in find window, false otherwise
    • setFieldStyle

      protected void setFieldStyle(String style)
      Description copied from class: WEditor
      Set field style
      Overrides:
      setFieldStyle in class WEditor
      Parameters:
      style - sclass name (@sclass=) or zclass name (@zclass=) or css style string