The activity definition begins with three key elements:

<activity id="personalization.users" inherit-from="assetManager.defaultEdit">

    <activity-name>
      personalization.users
    </activity-name>

The activity ID, personalization.users, indicates the activity to which the enclosing tags apply. This activity governs the functions available to users who enter the Asset Manager by clicking the Users link in the ATG Business Control Center Operations list. This tag also specifies the resource, assetManager.defaultEdit, from which this activity inherits settings. Note that an activity can inherit settings from another activity and a task or workflow can inherit from all three types of resources.

The name of the activity, in this case, is the same as the activity ID. These two identifiers are independent of each other. The ID is defined in the task configuration file and has no significance beyond it, whereas the name corresponds to the name given to the activity in the Asset Manager configuration file. Activities created for the purpose of holding settings inherited by other resources don’t have names.

You may have noticed that there isn’t a <configuration> tag that provides information about the Task Configuration Manager in this activity or any other resource configured by this file. When this information is omitted, the settings provided for the default Task Configuration Manager are used. The default Task Configuration Manager is /atg/web/assetmanager/configuration/ConfigurationManager.

See the sections below for an explanation of the remaining tags in the file.

Defining Common Buttons and General Tab Settings

The common buttons are implemented here:

<operations>
  <operation>create</operation>
  <operation>move</operation>
  <operation>duplicate</operation>
  <operation>delete</operation>
  <operation>addToMultiEdit</operation>
</operations>

The operation tags define the buttons that appear on the Navigation pane toolbar. Unlike other screen elements, the placement and ordering of buttons is defined in the JSP, not determined by the <operations> tag . The buttons named here are subset of the list of buttons available in the Asset Manager, which are described in the ATGMerchandising UI Basics section of the Using theATG Merchandising User Interface chapter in the ATG Merchandising User Guide.

The next section specifies tabs:

<tabs>
   <tab-order>
     <tab-id>browse</tab-id>
     <tab-id>search</tab-id>
     <tab-id>multiEdit</tab-id>
   </tab-order>
   <initial-tab>
     browse
   </initial-tab>

The <tabs> tags correspond to the first organizational screen elements in the Navigation pane, which are defined in assetManager.jsp. The first such element is defined as a tab of which three are specified: Browse, Search, and Multi Edit. These tabs display in the order they are provided to this list. When you use this activity to access the UI, the Browse tab is preselected as determined by the <initial-tab> tag.

Defining the Browse Tab

This section describes the Browse tab:

      <tab id="browse">
        <display-name-resource>
          assetManager.tab.browse
        </display-name-resource>
        <page>
          /browse/browseTab.jsp
        </page>

The Browse tab name is specified to the assetManager.tab.browse key in the global resource bundle named in the AssetUI configuration file <resource bundle> tag. The browseTab.jsp file provides the tab content.

The views on the Browse tab are organized and defined as follows:

        <views>
          <view-order>
            <view-id>personalization.users.users</view-id>
            <view-id>personalization.users.orgsAndRoles</view-id>
            <view-id>personalization.users.orgs</view-id>
          </view-order>
          <initial-view>
            personalization.users.users
          </initial-view>

The names of views map to names in the UI as follows:

View Name

Default View Name in the UI

personalization.users.users

Users

personalization.users.orgsAndRoles

Organizations and Roles

personalization.users.orgs

Organizations

The views display in a drop-down list in the order specified here, and when you open the UI, the Users view displays in the Browse tab because it is specified as the initial view.

All views are similar in structure. Here’s the code for the personalization.users.users view:

          <view id="personalization.users.users">
            <resource-bundle>
              atg.web.personalization.WebAppResources
            </resource-bundle>
            <display-name-resource>
              users.browseTab.view.users
            </display-name-resource>
            <configuration>
              /atg/web/assetmanager/configuration/profile/UserViewConfiguration
            </configuration>
            <page>
              /browse/list.jsp
            </page>
          </view>

Each view has a resource bundle key that maps to the name used for the view in the drop-down list. In addition to a resource bundle key, a new resource bundle is specified because labels for views are stored in a resource bundle that is different from the one used for the rest of the application.

Because there are many configuration options used to structure and operate a view, those options are stored in a Nucleus component to simplify and reduce clutter in the task configuration file. You can view the Nucleus component in the ACC using the path provided in the task configuration file. It’s unlikely you’ll need to modify the component, and you are discouraged from doing so. See the Creating Views section for more information about this component. The list structure used by this view is provided from list.jsp.

Because the same kind of information is provided for all views, personalization.users.users is provided here as an example that represents all views defined here. See the task configuration file itself for specific values given to other views. The only difference between this view and the other two is the inclusion of this tag:

            <operations>
              <operation combine="remove">duplicate</operation>
            </operations>

Although it’s possible that users, organizations, and roles may resemble other item types of their type, they ought to be unique, so the Duplicate button is removed from views used to work with them.

Defining the Search Tab

The Search tab is defined as follows:

<tab id="search">
  <display-name-resource>
    assetManager.tab.search
  </display-name-resource>
  <page>
    /search/searchTab.jsp
  </page>
  <views>
    <initial-view>
      form
    </initial-view>

The Search tab definition begins with the resource bundle key that is mapped to the name used for the tab. Note that two resource bundles have been specified: one in the <default-activity> tag in the AssetUI task configuration file and the other in the <view> tags included in this activity. The first resource bundle is the default and used here; the second is used only for the tags that specifically include it. The content displayed in the Search tab is contained in searchTab.jsp. Note that although the Search tab has views, they aren’t displayed in an ordered drop-down list because they aren’t available for user selection. The searchTab.jsp file is designed to display one view (form) for entering search criteria and another (results) for displaying search results. The form is defined below:

<view id="form">
  <page>
    /search/searchForm.jsp
  </page>
  <item-types>
    <item-type>/atg/userprofiling/ProfileAdapterRepository:user</item-type>
    <item-type>/atg/userprofiling/ProfileAdapterRepository:organization
    </item-type>
    <item-type>/atg/userprofiling/ProfileAdapterRepository:organizationalRole
    </item-type>
    <item-type>/atg/userprofiling/ProfileAdapterRepository:role</item-type>
    <item-type>/atg/userprofiling/ProfileAdapterRepository:roleFolder</item-type>
  </item-types>
</view>

The form view supplies the fields and buttons for building a query in searchForm.jsp. When you want to perform a search, you begin by selecting the type of item you want to locate from a drop-down list. The types available to the drop-down list are provided here by the <item-type> tags. The actual names that are used in the list are the display names defined for the item type in the item descriptor. The item types in the default list include a subset of the types defined for Personalization module.

You may notice the Find, Add Criteria, and New Search buttons aren’t defined in the task configuration file. Because it seems unlikely that you’d want to remove or replace these buttons, they are hardcoded into the search JSPs.

The second view, results, appears as follows:

          <view id="results">
            <page>
              /search/searchResults.jsp
            </page>
            <operations>
              <!-- users/orgs/roles don't need link or unlink -->
              <operation combine="remove">link</operation>
              <operation combine="remove">unlink</operation>
            </operations>
          </view>

The results view uses searchResults.jsp to display the items resulting from a query. The results page lets you select and delete items as well as add them to the Project and Multi Edit tabs. The Link and Unlink buttons are hidden from view because it may be difficult for users to rearrange the positions of items in the Search tab, where they can’t see the results of their adjustments. If you prefer, you can add those buttons in a custom task configuration file.

Defining the Multi Edit Tab

The Multi Edit tab is defined as follows:

  <tab id="multiEdit">
    <display-name-resource>
      assetManager.tab.multiEdit
    </display-name-resource>
    <page>
      /multiEdit/multiEditTab.jsp
    </page>
    <operations>
      <operation combine="remove">addToMultiEdit</operation>
      <operation>removeFromMultiEdit</operation>
      <operation>stepEdit</operation>
      <operation>applyToAll</operation>
      <operation>listEdit</operation>
    </operations>
    <configuration>
      /atg/commerce/web/assetmanager/MultiEditTabConfiguration
    </configuration>
  </tab>
</tabs>

Similar to the Browse tab, the Multi Edit tab stores its tab name in a resource file that maps the string provided here to the tab name. The tab structure is defined in multiEditTab.jsp. The Add to MultiEdit button is extraneous in the Multi Edit tab, so it is removed. Multi Edit-specific buttons are added to the tab – Remove from Multi Edit, Step Edit, List Edit, Apply to All. A configuration component holds additional settings, which are described in the Browse Tab Configuration information in Creating Views section.

 
loading table of contents...