Package org.adempiere.webui.adwindow
Interface IADTabpanel
- All Superinterfaces:
Cloneable
,org.zkoss.zk.ui.Component
,Evaluatee
,org.zkoss.zk.ui.ext.Scope
,Serializable
- All Known Implementing Classes:
ADSortTab
,ADTabpanel
Interface for AD_Tab panel component (with all the AD_Fields definition)
- Author:
- Low Heng Sin
-
Field Summary
Modifier and TypeFieldDescriptionstatic final String
Component boolean attribute to indicate ON_ACTIVATE_EVENT have been posted for the current execution cyclestatic final String
Activate/Deactivate event for IADTabpanel.Fields inherited from interface org.zkoss.zk.ui.Component
APPLICATION_SCOPE, COMPONENT_SCOPE, DESKTOP_SCOPE, PAGE_SCOPE, REQUEST_SCOPE, SESSION_SCOPE, SPACE_SCOPE
-
Method Summary
Modifier and TypeMethodDescriptionvoid
activate
(boolean b) Activate/deactivate this IADTabpanel instance.
Call by init or after tab selection changed.void
afterSave
(boolean onSaveEvent) Handle after save eventvoid
createUI()
Layout fields of the tab panelboolean
dataSave
(boolean onSaveEvent) Save changes.
CallGridTab.dataSave(boolean)
void
dynamicDisplay
(int col) Dynamic update of every field's UI properties ( visibility, filter and mandatory ).Get parent detail paneGet display logicGet GridTab of tabGet GridView componentint
Get record id of current rowGet table nameint
Get tab levelint
getTabNo()
Get tab nogetTitle()
Get title of tabList<org.zkoss.zul.Button>
Get toolbar buttonsGet tree panel componentvoid
init
(AbstractADWindowContent winPanel, GridTab gridTab) Initialized tab panelboolean
Is tab panel have been activatedboolean
Is current row not stallboolean
Is tab panel in detail pane modedefault boolean
Get is detail pane visibleboolean
Is customize grid button enabledefault boolean
Is process button enableboolean
Is quick form enabledboolean
Is tab panel showing grid viewboolean
needSave
(boolean rowChange, boolean onlyRealChange) void
After Find window closes switch to grid view if configuredboolean
Handle enter key eventvoid
query()
Execute query through the backedGridTab
instance.void
query
(boolean currentRows, int currentDays, int maxRows) void
refresh()
Refresh data through the backedGridTab
instance.void
Reset detail data grid when current record of parent tab is new and not saved yet.
CallGridTab.resetDetailForNewParentRecord()
void
setDetailPane
(DetailPane detailPane) Set theDetailPane
part that own this IADTabpanel instancevoid
setDetailPaneMode
(boolean detailMode) Turn on/off detail mode, i.e whether tab panel is currently a header or detail tab of the window.void
setTabNo
(int tabNo) Set tab number/sequence within an AD_Windowvoid
Switch between grid and form viewvoid
updateDetailToolbar
(org.zkoss.zul.Toolbar toolbar) UpdateDetailPane
toolbar buttons statevoid
updateToolbar
(ADWindowToolbar toolbar) Update ADWindowToolbar buttons stateMethods inherited from interface org.zkoss.zk.ui.Component
addEventListener, addEventListener, addForward, addForward, addForward, addForward, appendChild, applyProperties, clone, detach, getAttribute, getAttribute, getAttributeOrFellow, getAttributes, getAttributes, getAuService, getAutag, getChildren, getClientAttribute, getClientDataAttribute, getDefinition, getDesktop, getEventListeners, getFellow, getFellow, getFellowIfAny, getFellowIfAny, getFellows, getFirstChild, getId, getLastChild, getMold, getNextSibling, getPage, getParent, getPreviousSibling, getRoot, getShadowVariable, getShadowVariable, getSpaceOwner, getStubonly, getTemplate, getTemplateNames, getUuid, getWidgetAttributeNames, getWidgetClass, getWidgetListener, getWidgetListenerNames, getWidgetOverride, getWidgetOverrideNames, hasAttribute, hasAttribute, hasAttributeOrFellow, hasFellow, hasFellow, insertBefore, invalidate, isInvalidated, isListenerAvailable, isVisible, query, queryAll, removeAttribute, removeAttribute, removeChild, removeEventListener, removeForward, removeForward, setAttribute, setAttribute, setAuService, setAutag, setClientAttribute, setClientDataAttribute, setId, setMold, setPage, setPageBefore, setParent, setStubonly, setStubonly, setTemplate, setVisible, setWidgetClass, setWidgetListener, setWidgetOverride
Methods inherited from interface org.compiere.util.Evaluatee
get_ValueAsString
Methods inherited from interface org.zkoss.zk.ui.ext.Scope
addScopeListener, getAttribute, hasAttribute, removeAttribute, removeScopeListener, setAttribute
-
Field Details
-
ON_ACTIVATE_EVENT
Activate/Deactivate event for IADTabpanel. Fire for init or after tab selection changed.- See Also:
-
ATTR_ON_ACTIVATE_POSTED
Component boolean attribute to indicate ON_ACTIVATE_EVENT have been posted for the current execution cycle- See Also:
-
-
Method Details
-
init
Initialized tab panel- Parameters:
winPanel
-gridTab
-
-
getDisplayLogic
String getDisplayLogic()Get display logic- Returns:
- display logic
-
getTabLevel
int getTabLevel()Get tab level- Returns:
- tab level
-
getTableName
String getTableName()Get table name- Returns:
- table name from GridTab
-
getRecord_ID
int getRecord_ID()Get record id of current row- Returns:
- record ID of current row
-
isCurrent
boolean isCurrent()Is current row not stall- Returns:
- true if refresh is not needed
-
getTitle
String getTitle()Get title of tab- Returns:
- title of tab
-
createUI
void createUI()Layout fields of the tab panel -
getGridTab
GridTab getGridTab()Get GridTab of tab- Returns:
GridTab
instance that back this IADTabpanel instance
-
activate
void activate(boolean b) Activate/deactivate this IADTabpanel instance.
Call by init or after tab selection changed.- Parameters:
b
-
-
query
void query()Execute query through the backedGridTab
instance. -
refresh
void refresh()Refresh data through the backedGridTab
instance. -
query
void query(boolean currentRows, int currentDays, int maxRows) - Parameters:
currentRows
-currentDays
-maxRows
-
-
switchRowPresentation
void switchRowPresentation()Switch between grid and form view -
onAfterFind
void onAfterFind()After Find window closes switch to grid view if configured -
dynamicDisplay
void dynamicDisplay(int col) Dynamic update of every field's UI properties ( visibility, filter and mandatory ).- Parameters:
col
- optional column name
-
afterSave
void afterSave(boolean onSaveEvent) Handle after save event- Parameters:
onSaveEvent
-
-
onEnterKey
boolean onEnterKey()Handle enter key event- Returns:
- true if the event is process
-
isGridView
boolean isGridView()Is tab panel showing grid view- Returns:
- true if current presentation of the tab panel is grid/list view
-
isActivated
boolean isActivated()Is tab panel have been activated- Returns:
- true if the tab panel have been activated
-
setDetailPaneMode
void setDetailPaneMode(boolean detailMode) Turn on/off detail mode, i.e whether tab panel is currently a header or detail tab of the window.- Parameters:
detailMode
-
-
isDetailPaneMode
boolean isDetailPaneMode()Is tab panel in detail pane mode- Returns:
- true if the panel is in detail mode (i.e a tab in DetailPane)
-
getGridView
GridView getGridView()Get GridView component- Returns:
GridView
instance
-
needSave
boolean needSave(boolean rowChange, boolean onlyRealChange) - Parameters:
rowChange
-onlyRealChange
-- Returns:
- true if there are pending changes
-
dataSave
boolean dataSave(boolean onSaveEvent) Save changes.
CallGridTab.dataSave(boolean)
- Parameters:
onSaveEvent
-- Returns:
- true if the save operation completed successfully
-
setTabNo
void setTabNo(int tabNo) Set tab number/sequence within an AD_Window- Parameters:
tabNo
-
-
getTabNo
int getTabNo()Get tab no- Returns:
- tab no ( ad_tab.tabno )
-
setDetailPane
Set theDetailPane
part that own this IADTabpanel instance- Parameters:
detailPane
-
-
getDetailPane
DetailPane getDetailPane()Get parent detail pane- Returns:
- the
DetailPane
part that own this IADTabpanel instance
-
resetDetailForNewParentRecord
void resetDetailForNewParentRecord()Reset detail data grid when current record of parent tab is new and not saved yet.
CallGridTab.resetDetailForNewParentRecord()
-
getTreePanel
ADTreePanel getTreePanel()Get tree panel component- Returns:
ADTreePanel
instance
-
isEnableQuickFormButton
boolean isEnableQuickFormButton()Is quick form enabled- Returns:
- true if Quick Form Button is Enabled
-
isDetailVisible
default boolean isDetailVisible()Get is detail pane visible- Returns:
- true if the containing
DetailPane
instance is visible
-
getToolbarButtons
List<org.zkoss.zul.Button> getToolbarButtons()Get toolbar buttons- Returns:
- List of toolbar buttons
-
isEnableCustomizeButton
boolean isEnableCustomizeButton()Is customize grid button enable- Returns:
- true if customize grid button is enabled
-
isEnableProcessButton
default boolean isEnableProcessButton()Is process button enable- Returns:
- true if process Button is Enabled
-
updateToolbar
Update ADWindowToolbar buttons state- Parameters:
toolbar
- -ADWindowToolbar
-
updateDetailToolbar
void updateDetailToolbar(org.zkoss.zul.Toolbar toolbar) UpdateDetailPane
toolbar buttons state- Parameters:
toolbar
- -Toolbar
-