Class AbstractListChangeItemTableViews

java.lang.Object
com.ptc.core.htmlcomp.tableview.AbstractConfigurableTable
com.ptc.core.htmlcomp.components.JCAConfigurableTable
com.ptc.windchill.enterprise.change2.tableViews.ChangeTableViews
com.ptc.windchill.enterprise.change2.tableViews.list.AbstractListChangeItemTableViews
All Implemented Interfaces:
com.ptc.core.htmlcomp.components.JCAMappable, ConfigurableTable, com.ptc.core.htmlcomp.tableview.FreezableConfigurableTable, com.ptc.core.htmlcomp.tableview.RuntimeTableViewHolder
Direct Known Subclasses:
ListChangeNoticesTableViews, ListChangeRequestsTableViews, ListProblemReportsTableViews, ListVariancesTableViews

public abstract class AbstractListChangeItemTableViews extends ChangeTableViews
Abstract class to support the view definitions of the Change tables which appear under the change tab. This class currently supports the Problem Reports, Change Requests and Change Notices tables however could be subclasses to support additional tables. These table view classes would be called by the listChangeItems.xml TAG.

Supported API: true

Extendable: true
  • Method Details

    • getClassTypes

      public abstract Class<?>[] getClassTypes()
      Method to get an Array of Class types for the table views.

      Supported API: true
      Specified by:
      getClassTypes in interface ConfigurableTable
      Specified by:
      getClassTypes in class ChangeTableViews
      Returns:
      Class[] Returns an Array of Class types for the table views.
    • getOOTBTableViews

      public List getOOTBTableViews(String tableId, Locale locale) throws WTException
      Sets the default table view and returns a list of out of the box table views. The following views will be created:
      1. All Open
      2. Created by Me
      3. Last 7 days
      4. Last 30 days
      5. Last 90 days


      Supported API: true
      Specified by:
      getOOTBTableViews in interface ConfigurableTable
      Specified by:
      getOOTBTableViews in class ChangeTableViews
      Parameters:
      tableId - Passes in the table id
      locale - Passes in the Locale
      Returns:
      result Return a list of out of the box table views.
      Throws:
      WTException - Error thrown during execution.

      Supported API: true
    • getNonResolvedCriteria

      protected com.ptc.core.htmlcomp.tableview.TableViewCriterion getNonResolvedCriteria() throws WTException
      Criteria for the non-resolved change objects. By default, for Problem Reports, Change Requests and Change Notices the criteria will be to look for the "resolutionDate" as empty. Other objects (or different support) can be implemented by overloading this API.

      Supported API: true
      Returns:
      table view criterion
      Throws:
      WTException
    • getOOTBActiveViewName

      public abstract String getOOTBActiveViewName()
      Provide the out of the box active view name.

      Supported API: true
      Specified by:
      getOOTBActiveViewName in interface ConfigurableTable
      Overrides:
      getOOTBActiveViewName in class ChangeTableViews
      Returns:
      String The active view name
    • getOOTBViewName

      public abstract String getOOTBViewName(String viewName)
      Provide the out of the box view name for the defined view name.

      Supported API: true
      Parameters:
      viewName - The name of the view (for example "ALL_OPEN")
      Returns:
      the string representing the view
      See Also:
    • getGeneratedViewName

      public String getGeneratedViewName(String type, String viewName)
      Provide the generated name for a specific view and type. Will attempt to retrieve the view name from the listResource using the form: <type>_<viewName>_NAME. If this resource does not exist it will look for a resource entry for: <viewName>_NAME. Finally if this is not resolved the view name will be returned as the fully qualified path to the resource bundle listResource plus the viewName and the text _NAME on the end.

      Supported API: true
      Parameters:
      type - The text "type" to check for in the resource bundle. An example might be CHANGE_REQUEST.
      viewName - The name of the view to get the generated view name for. For example ALL_OPEN.
      Returns:
      the Generated view name string.
    • getDefaultSortColumn

      public String getDefaultSortColumn()
      Method to get the default column to sort on table views.

      Supported API: true
      Specified by:
      getDefaultSortColumn in interface ConfigurableTable
      Overrides:
      getDefaultSortColumn in class ChangeTableViews
      Returns:
      String Returns the default column to sort on table views.
    • getDefaultViewDescription

      protected abstract String getDefaultViewDescription(String viewName)
      Provide the description for the default view.

      Supported API: true
      Overrides:
      getDefaultViewDescription in class ChangeTableViews
      Parameters:
      viewName - The locale for the description.
      Returns:
      String The default description for the view.
    • getGeneratedDefaultViewDescription

      protected String getGeneratedDefaultViewDescription(String type, String viewName)
      Provide the generated description for a specific view and type. The view name is typically encoded at this point from the output of getGeneratedViewName( ) so several operations are required to be perform on the view in order for the description to be determined correctly. The implemented getDefaultViewDescription() should simply call this method by assigning the type in any subclass.
      Will attempt to retrieve the view description from the listResource using the form: <type>_<short_viewName>_DESCRIPTION. If this resource does not exist it will look for a resource entry for: <viewName>_DESCRIPTION. Finally if this is not resolved the view description will be returned as the fully qualified path to the resource bundle listResource plus the viewName and the text _DESCRIPTION on the end.

      Supported API: true
      Parameters:
      type - The text "type" to check for in the resource bundle. An example might be CHANGE_REQUEST.
      viewName - The name of the view to get the generated view description for.
      Returns:
      the Generated view description string.
      See Also:
    • getGeneratedDefaultViewDescription

      protected String getGeneratedDefaultViewDescription(String type, String viewName, Class<?> primaryResourceClass, String primaryResource)
      Provide the generated description for a specific view and type. The view name is typically encoded at this point from the output of getGeneratedViewName( ) so several operations are required to be perform on the view in order for the description to be determined correctly. The implemented getDefaultViewDescription() should simply call this method by assigning the type in any subclass.
      Will attempt to retrieve the view description from the listResource using the form: <type>_<short_viewName>_DESCRIPTION. If this resource does not exist it will look for a resource entry for: <viewName>_DESCRIPTION. Finally if this is not resolved the view description will be returned as the fully qualified path to the resource bundle listResource plus the viewName and the text _DESCRIPTION on the end.

      Supported API: true
      Parameters:
      type - The text "type" to check for in the resource bundle. An example might be CHANGE_REQUEST.
      viewName - The name of the view to get the generated view description for.
      primaryResourceClass - The primary resource class
      primaryResource - The primary resource bundle location
      Returns:
      the Generated view description string.
      See Also:
    • getLockedColumns

      protected List<String> getLockedColumns()
      Retrieve the locked columns for the table view.

      Supported API: true
      Specified by:
      getLockedColumns in class ChangeTableViews
      Returns:
      Mapinvalid input: '<'String,Boolean> Ordered Map of column Ids and whether it is locked.
    • getDefaultColumns

      public abstract List<String> getDefaultColumns(String viewName)
      Abstract method to return columnIds for the view

      Supported API: true
      Parameters:
      locale - Passes in the viewName
      Returns:
      List Returns a list of columnIds
    • getLabel

      public abstract String getLabel(Locale locale)
      Provide a label that describes the table which these table views belong.

      Supported API: true
      Specified by:
      getLabel in interface ConfigurableTable
      Specified by:
      getLabel in class ChangeTableViews
      Parameters:
      locale - Passes in the Locale
      Returns:
      String Returns the label for the table views.