Class PPromotionPage

All Implemented Interfaces:
PAccountViewPage, PCCPage, HoldingsChangeListener, PAppComponent, PClientComponent, PCollectDataListener, PComponent, PComponentAttribute, PViewDataChangeListener, ContainerListener, ImageObserver, MenuContainer, Serializable, EventListener, Accessible

public class PPromotionPage extends PMaintenancePage implements HoldingsChangeListener
Top-level container (tab) for account promotions. There are two kinds of promotions:
  • account level promotions
  • service level promotions

If an account does not contain any GSM services, this tab will be hidden.

See Also:
  • Constructor Details

    • PPromotionPage

      public PPromotionPage()
      Creates a top-level page (tab) containg both account and service level promotions.
  • Method Details

    • isValidContext

      public boolean isValidContext(PAccountViewContext ctx)
      If an account does not contain any GSM services, this tab will be hidden by returning false.
      Specified by:
      isValidContext in interface PAccountViewPage
      Overrides:
      isValidContext in class PMaintenancePage
      Parameters:
      ctx - The current account view's context
      The - current account view's context
      Returns:
      true if the page is valid and should be visible; false otherwise
    • save

      public void save() throws PSaveException
      Saves account and service level promotions for current account (if any). This method will attempt to save account and service level promotions sequentially. If one failed, the program will log the error and continue to save the other.

      Account and service level promotions saving does not need to be in one single transaction because they are not related to each other. Both are grouped in the same tab to allow esaier access to CSRs.

      Specified by:
      save in interface PAccountViewPage
      Overrides:
      save in class PMaintenancePage
      Throws:
      PSaveException
    • addNotify

      public void addNotify()
      Overrides:
      addNotify in class JComponent
    • removeNotify

      public void removeNotify()
      Overrides:
      removeNotify in class JComponent
    • holdingsChange

      public void holdingsChange(HoldingsChangeEvent e)
      Event handler for table HoldingsChangeEvent. Called when an event is sent out that indicates a purchase of a deal/service has been made.
      Specified by:
      holdingsChange in interface HoldingsChangeListener
      Parameters:
      e - a HoldingsChangeEvent encapsulating the event information
    • 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 interface PAccountViewPage
      Overrides:
      refresh in class PMaintenancePage
    • recycle

      public void recycle()
      Makes this page available for reuse.

      Specified by:
      recycle in interface PCCPage
      Overrides:
      recycle in class PMaintenancePage