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.AccessibleJPanelNested classes/interfaces inherited from class javax.swing.JComponent
JComponent.AccessibleJComponentNested classes/interfaces inherited from class java.awt.Container
Container.AccessibleAWTContainerNested 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, mPagesCurrentCurrencyFields inherited from class com.portal.bas.comp.PIACustomizablePanel
isTracking, mIAList, mImpl, unregListFields inherited from class com.portal.pfc.ui.ImagePanel
IMAGE_CENTERED, IMAGE_SCALE_TO_HEIGHT, IMAGE_SCALE_TO_WIDTH, IMAGE_SCALED, IMAGE_TILED, mImageIcon, mScaledImageFields inherited from class javax.swing.JComponent
listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOWFields inherited from class java.awt.Component
accessibleContext, BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENTFields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidvoidOverridden to apply style to some of the fontsvoidcollectData(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.voidThis 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.intReturns the currently selected payment typebooleanbooleanvoiditemStateChanged(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 voidprotected voidvoidrefresh()Called when the page should be immediately refreshed - typically as a result of the Reset action being invoked by the user.voidA convenience method that resets every field on this panel.voidsave()Commit changes to PortalvoidCalled when the user performs some type of gesture in the spreadsheet, for example, a mouse click or pressing the Enter or Return key.voidsetClean()Resets the dirty/error state of this panel.protected voidThe custom panel is set to the main panel, from the subclass.voidsetCustomDomComponent(Component cComp) Add custom Component in place of existing DOM fieldvoidAdd custom Spinner field in place of existing DOM fieldvoidsetModelHandle(PModelHandle accMH) Updates the page with new datavoidsetSupportSubordinate(boolean supported) protected voidsetTaxSetupEnabled(boolean flag) This method can be used to disable the Tax Setup panel completely.protected voidshowNextBillingCycle(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, revertToPrimaryMethods 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, viewDataChangeMethods inherited from class com.portal.pfc.ui.ImagePanel
getBackgroundImageIcon, getBackgroundImageMode, imageUpdate, paintComponent, setBackgroundImageIconMethods inherited from class javax.swing.JPanel
getAccessibleContext, getUI, getUIClassID, paramString, setUI, updateUIMethods 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, updateMethods 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, validateTreeMethods 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:PIACustomizablePanelRetrieves the class name of this component's controller, in this case, null.- Specified by:
getControllerClassNamein interfacePComponent- Overrides:
getControllerClassNamein classPIACustomizablePanel- Returns:
- Throws:
RemoteException
-
addNotify
public void addNotify()Overridden to apply style to some of the fonts- Overrides:
addNotifyin classJComponent
-
enteringPage
public void enteringPage()Description copied from class:PMaintenancePageThis 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:
enteringPagein interfacePCCPage- Overrides:
enteringPagein classPMaintenancePage
-
refresh
public void refresh()Description copied from class:PMaintenancePageCalled when the page should be immediately refreshed - typically as a result of the Reset action being invoked by the user.- Specified by:
refreshin interfacePAccountViewPage- Overrides:
refreshin classPMaintenancePage
-
save
Commit changes to Portal- Specified by:
savein interfacePAccountViewPage- Overrides:
savein classPMaintenancePage- Throws:
PSaveException
-
setModelHandle
Updates the page with new data- Specified by:
setModelHandlein interfacePComponent- Overrides:
setModelHandlein classPIACustomizablePanel- Parameters:
accMH- the newPModelHandlefrom which to extract informationpm- the model handle- Throws:
RemoteException- thrown for errors
-
collectData
Retrieves modified data from the panel- Specified by:
collectDatain interfacePCollectDataListener- Overrides:
collectDatain classPIACustomizablePanel- Parameters:
event- thePCollectDataEventevent
-
resetToDefault
public void resetToDefault()Description copied from class:PIACustomizablePanelA convenience method that resets every field on this panel.- Specified by:
resetToDefaultin interfacePComponentAttribute- Overrides:
resetToDefaultin 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:
setCleanin interfacePComponentAttribute- Overrides:
setCleanin 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:
itemStateChangedin 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:PSpreadSheetListenerCalled 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:
selectionChangedin 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:
actionPerformedin interfaceActionListener- Parameters:
e-
-