Package com.portal.app.cc
Class PBillingCycleAndTaxSetupPage
java.lang.Object
java.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.JPanel
com.portal.pfc.ui.ImagePanel
com.portal.bas.comp.PIACustomizablePanel
com.portal.app.cc.comp.PMaintenancePage
com.portal.app.cc.PBillingCycleAndTaxSetupPage
- All Implemented Interfaces:
PAccountViewPage
,PCCPage
,PResettable
,PSpreadSheetListener
,PAppComponent
,PClientComponent
,PCollectDataListener
,PComponent
,PComponentAttribute
,PViewDataChangeListener
,ActionListener
,ContainerListener
,ItemListener
,ImageObserver
,MenuContainer
,Serializable
,EventListener
,Accessible
public class PBillingCycleAndTaxSetupPage
extends PMaintenancePage
implements ItemListener, PResettable, PSpreadSheetListener, ActionListener
Panel for viewing/modifying Billing and Tax setup information during account
maintenence.
Subclasses can add custom fields/panel to this panel along the following lines:
Subclasses can add custom fields/panel to this panel along the following lines:
public class MyPanel extends PBillingCycleAndTaxSetupPage { public MyPanel() { PIACustomizablePanel p = new PIACustomizablePanel(); p.setLayout(new GridBagLayout()); p.add(new JLabel("One"), new GridBagConstraints(0, 0, 1, 1, 0.0, 0.0 ,GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(10, 5, 0, 0), 0, 0)); p.add(new JLabel("Two"), new GridBagConstraints(0, 1, 1, 1, 0.0, 0.0 ,GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(10, 5, 0, 0), 0, 0)); p.add(new JTextField(10), new GridBagConstraints(1, 0, 1,1, 0.0, 0.0 ,GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(10, 5, 0, 0), 0, 0)); p.add(new JTextField(10), new GridBagConstraints(1, 1, 1,1, 0.0, 0.0 ,GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(10, 5, 0, 0), 0, 0)); setCustomData(p); } }
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class javax.swing.JPanel
JPanel.AccessibleJPanel
Nested classes/interfaces inherited from class javax.swing.JComponent
JComponent.AccessibleJComponent
Nested classes/interfaces inherited from class java.awt.Container
Container.AccessibleAWTContainer
Nested classes/interfaces inherited from class java.awt.Component
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy
-
Field Summary
Fields inherited from class com.portal.app.cc.comp.PMaintenancePage
mNeedsRefresh, mPagesCurrentCurrency
Fields inherited from class com.portal.bas.comp.PIACustomizablePanel
isTracking, mIAList, mImpl, unregList
Fields inherited from class com.portal.pfc.ui.ImagePanel
IMAGE_CENTERED, IMAGE_SCALE_TO_HEIGHT, IMAGE_SCALE_TO_WIDTH, IMAGE_SCALED, IMAGE_TILED, mImageIcon, mScaledImage
Fields inherited from class javax.swing.JComponent
listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW
Fields inherited from class java.awt.Component
accessibleContext, BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
void
Overridden to apply style to some of the fontsvoid
collectData
(PCollectDataEvent event) Retrieves modified data from the panelconstructFormatString
(String sFormatString, int[] iDiallowedList) Constructs a format string that excludes exemption types that are present in the exemption table.void
This method will be called right after a page is made visible via a drilldown.Retrieves the class name of this component's controller, in this case, null.int
Returns the currently selected payment typeboolean
boolean
void
itemStateChanged
(ItemEvent event) Determines the payment type from the account object represented in the model handle, and explicitely calls setModelHandle() on the panel for that payment type.protected void
protected void
void
refresh()
Called when the page should be immediately refreshed - typically as a result of the Reset action being invoked by the user.void
A convenience method that resets every field on this panel.void
save()
Commit changes to Portalvoid
Called when the user performs some type of gesture in the spreadsheet, for example, a mouse click or pressing the Enter or Return key.void
setClean()
Resets the dirty/error state of this panel.protected void
The custom panel is set to the main panel, from the subclass.void
setCustomDomComponent
(Component cComp) Add custom Component in place of existing DOM fieldvoid
Add custom Spinner field in place of existing DOM fieldvoid
setModelHandle
(PModelHandle accMH) Updates the page with new datavoid
setSupportSubordinate
(boolean supported) protected void
setTaxSetupEnabled
(boolean flag) This method can be used to disable the Tax Setup panel completely.protected void
showNextBillingCycle
(boolean flag) This method can be used in the extended payment page, if the Next Billing Cycle RO field need to be visible off/on.Methods inherited from class com.portal.app.cc.comp.PMaintenancePage
dataNeedsRefresh, getDisplayedCurrency, getLabel, hasUnsavedChanges, isValidContext, primaryToSecondary, recycle, resetUnsavedChanges, revertToPrimary
Methods inherited from class com.portal.bas.comp.PIACustomizablePanel
clear, componentAdded, componentRemoved, containsError, getBackgroundImageSource, getBundle, getModelHandle, getRemoteComponent, getResourceName, getTools, isClean, isCurrencyDisplay, isDirty, isError, isInputTracking, isLight, isRequired, processError, setBackgroundImageMode, setBackgroundImageSource, setCurrencyDisplay, setDefault, setError, setInputTracking, setRequired, setResourceName, togglePrimaryToSecondary, unregister, viewDataChange
Methods inherited from class com.portal.pfc.ui.ImagePanel
getBackgroundImageIcon, getBackgroundImageMode, imageUpdate, paintComponent, setBackgroundImageIcon
Methods inherited from class javax.swing.JPanel
getAccessibleContext, getUI, getUIClassID, paramString, setUI, updateUI
Methods inherited from class javax.swing.JComponent
addAncestorListener, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getPreferredSize, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, hide, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingOrigin, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintBorder, paintChildren, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, addImpl, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusDownCycle, validate, validateTree
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, requestFocus, requestFocus, requestFocusInWindow, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setMixingCutoutShape, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusBackward, transferFocusUpCycle
-
Constructor Details
-
PBillingCycleAndTaxSetupPage
public PBillingCycleAndTaxSetupPage()
-
-
Method Details
-
getControllerClassName
Description copied from class:PIACustomizablePanel
Retrieves the class name of this component's controller, in this case, null.- Specified by:
getControllerClassName
in interfacePComponent
- Overrides:
getControllerClassName
in classPIACustomizablePanel
- Returns:
- Throws:
RemoteException
-
addNotify
public void addNotify()Overridden to apply style to some of the fonts- Overrides:
addNotify
in classJComponent
-
enteringPage
public void enteringPage()Description copied from class:PMaintenancePage
This method will be called right after a page is made visible via a drilldown. The default implementation inspects the currency being used to display data for the client at large and compares it to the currency used by the panel. If they differ primaryToSecondary() is called.
This implementation also looks at the internal refresh flag to determine if a subclass has indicated the page is out of date. If it is, this method invokes the setModelHandle() method with the current PModelHandle.
Subclasses that override this method should call super.enteringPage()- Specified by:
enteringPage
in interfacePCCPage
- Overrides:
enteringPage
in classPMaintenancePage
-
refresh
public void refresh()Description copied from class:PMaintenancePage
Called when the page should be immediately refreshed - typically as a result of the Reset action being invoked by the user.- Specified by:
refresh
in interfacePAccountViewPage
- Overrides:
refresh
in classPMaintenancePage
-
save
Commit changes to Portal- Specified by:
save
in interfacePAccountViewPage
- Overrides:
save
in classPMaintenancePage
- Throws:
PSaveException
-
setModelHandle
Updates the page with new data- Specified by:
setModelHandle
in interfacePComponent
- Overrides:
setModelHandle
in classPIACustomizablePanel
- Parameters:
accMH
- the newPModelHandle
from which to extract informationpm
- the model handle- Throws:
RemoteException
- thrown for errors
-
collectData
Retrieves modified data from the panel- Specified by:
collectData
in interfacePCollectDataListener
- Overrides:
collectData
in classPIACustomizablePanel
- Parameters:
event
- thePCollectDataEvent
event
-
resetToDefault
public void resetToDefault()Description copied from class:PIACustomizablePanel
A convenience method that resets every field on this panel.- Specified by:
resetToDefault
in interfacePComponentAttribute
- Overrides:
resetToDefault
in classPIACustomizablePanel
-
setClean
public void setClean()Resets the dirty/error state of this panel. Any fields marked as changed or in error are reset graphically.- Specified by:
setClean
in interfacePComponentAttribute
- Overrides:
setClean
in classPIACustomizablePanel
-
itemStateChanged
Determines the payment type from the account object represented in the model handle, and explicitely calls setModelHandle() on the panel for that payment type. This avoids exceptions in every panel that does not represent that payment type.- Specified by:
itemStateChanged
in interfaceItemListener
- Parameters:
pm
- the model handle
-
getPaymentType
public int getPaymentType()Returns the currently selected payment type -
isPaymentTypeChanged
public boolean isPaymentTypeChanged()- Returns:
-
isBillingDataChanged
public boolean isBillingDataChanged()- Returns:
-
setSupportSubordinate
public void setSupportSubordinate(boolean supported) - Parameters:
supported
-
-
setCustomData
The custom panel is set to the main panel, from the subclass.- Parameters:
p
- Panel to be displayed
-
preCommit
- Parameters:
pm
-- Throws:
PSaveException
-
postCommit
protected void postCommit() -
selectionChanged
Description copied from interface:PSpreadSheetListener
Called when the user performs some type of gesture in the spreadsheet, for example, a mouse click or pressing the Enter or Return key.- Specified by:
selectionChanged
in interfacePSpreadSheetListener
- Parameters:
pe
-
-
setCustomDomFld
Add custom Spinner field in place of existing DOM field -
setCustomDomComponent
Add custom Component in place of existing DOM field -
showNextBillingCycle
protected void showNextBillingCycle(boolean flag) This method can be used in the extended payment page, if the Next Billing Cycle RO field need to be visible off/on. -
setTaxSetupEnabled
protected void setTaxSetupEnabled(boolean flag) This method can be used to disable the Tax Setup panel completely. -
constructFormatString
Constructs a format string that excludes exemption types that are present in the exemption table. -
actionPerformed
- Specified by:
actionPerformed
in interfaceActionListener
- Parameters:
e
-
-