When you create a new site in Site Administration, you must select a site category. The site category you choose determines the site configuration properties you can set for the site (that is, the settings you see in Site Administration).

Out of the box, the ATG platform ships with a default site category that includes basic properties that most sites are likely to require, such as Site Description and Site Name. Other modules, such as Commerce (DCS) and Commerce Reference Store (CommerceReferenceStore), layer on additional properties to the default site category, such as default price lists and CSS file locations. For Commerce Reference Store 10.2, site configuration properties are added to the default site category by:

Note: For details on each module’s properties, refer to the documentation for the individual module.

Depending on your application’s requirements, you may choose to append site configuration properties to the default site category (this is the Commerce Reference Store’s approach), or you may choose to create an entirely new site category. You should create a new site category if:

Whether you create a new site category or append properties to the default site category, it is important to understand the underlying site category structure. Each site category in Site Administration is backed by a corresponding siteTemplate item in the Site repository that gives the category a name and points to a view mapping. View mappings control the display of repository item properties in a UI. You can have more than one view mapping refer to the same type of repository item, with each view mapping specifying different display and editing characteristics for the properties of the repository item. To return to our previous example, one view mapping could mark a property as required while another could mark it as hidden.

It is possible to define characteristics such as required and read only, or to provide a default value for a property, in the siteConfiguration XML repository definition file. However, any configuration you specify in the siteConfiguation XML definition will apply to all site configurations; that is, all site configuration items in the Site repository will use that default value. Specifying characteristics like defaults in view mappings allows you to have different defaults for different site categories. When you select a category for your site, you get the corresponding default. For example, consider the following diagram:

This diagram is described in subsequent sections

In this diagram, the following happens:

  1. The /atg/multisite/siteRepository.xml defines three properties for the siteConfiguration item type, Properties 1, 2, and 3. Property 3 has a default value of True. Because it is specified at the XML definition file level, this property will be the same for all sites created in the Site repository.

  2. View Mapping A further refines Property 1 to mark it as required, and Property 2 to set its default value to True. These values will be reflected in Site Administration. View Mapping A doesn’t further refine Property 3 beyond specifying that the property should be visible in Site Administration.

    View Mapping B further refines Property 1 to mark it as hidden, meaning it will not appear in Site Administration, and Property 2 to set its default value to False. Like View Mapping A, View Mapping B doesn’t further refine Property 3 beyond specifying that the property should be visible in Site Administration.

    Both view mappings configure the display of the site properties in Site Administration. However, because they specify different behavior for the properties, the presentation and behavior of the properties in the Site Administration will also be different.

  3. siteTemplate A defines Site Category A and specifies that the category should use View Mapping A as its view mapping. siteTemplate B defines Site Category B and specifies that the category should use View Mapping B as its view mapping.

  4. When you create a site using Site Category A in Site Administration, the following happens:

    When you create a site using Site Category B in Site Administration, the following happens:

In general, you should define the existence of site properties in the siteRepository.xml and define the behavior of properties (read only, defaults, required, and so on) in view mappings. The exception to this rule is a property that should behave identically across all sites stored in the Site Repository.

The following sections describe how to append custom site configuration properties to the default site category, using Commerce Reference Store as an example. For detailed information on creating new site categories, see Defining Site Categories. In particular, pay attention to the caveats described in the Important Warning section. For more details on view mappings themselves, see the ATG Content Administration Programming Guide.


Copyright © 1997, 2013 Oracle and/or its affiliates. All rights reserved. Legal Notices