6 Designing Flex Asset Types

Flex asset types are part of a flex asset family, and they inherit attributes from parents, grandparents, and so on. Each asset type is stored across several database tables.

For an overview of the data model, see Understanding the Asset Types and Asset Models. For information about flex asset types, see these topics:

About Designing Flex Asset Types

When creating flex asset types, you also create the individual data structure assets of those types. These assets are flex attributes, flex parent definitions, flex definitions, and flex parent assets. For creating flex asset types, the Flex Family Maker utility is available in the Admin interface.

Typically, you design the flex asset types and create the data structure assets on a development system. When your data model is ready, you migrate your work from the development system to the management and delivery systems.

Design Tips for Flex Families

The data structure that you create for your flex family should offer flexibility and convenience to the site visitors and content contributors who enter data into the WebCenter Sites database. Here are some tips that can help you meet the site visitors’ and content teams’ needs.

See these topics:

Visitors on the Delivery System

The experience of the visitors to your online site is based on the following asset types:

  • Flex asset

  • Flex attribute

Your online site pages display flex assets (assetsets) for the visitors through queries that are based on attribute values (searchstates). To give the appearance of hierarchy on your online site, use attribute values as the basis for drill-down searches.

Users on the Management System

The users of your management system navigate through a visual hierarchical structure that you create for them with the following flex asset types:

  • Flex parent definition

  • Flex definition

  • Flex parent

Although the organizational structure that you create with these asset types does affect the data, it determines which attribute values are inherited by which flex assets. Its biggest impact is on the users of the management system.

You are not required to use flex parents and flex parent definitions, but their inheritance properties make them a valuable tool for users who are maintaining a large amount of data such as an online catalog:

  • Changing an attribute value at the parent level changes that value for all the flex assets who are children of that parent, which means you only have to change the value once.

  • Inherited attribute values aren't subject to user error, which means less data cleanup is required.

The inheritance tree that you create for your content providers has no bearing on how your site visitors navigate the online site you are designing. For example, if content is entered into your management system through some completely automated process (perhaps it is bulk loaded from an ERP system) you would have no need for parent asset types at all, yet you can still create drill-down searches on your online site.

How Many Attribute Types Should You Create?

As described in Assetsets and Searchstates, only the flex assets that share a common attribute type can belong to the same assetset because queries (searchstates) are based on attributes and not on the organizational constructs of parent definitions and flex definitions.

You might create a nicely delineated interface on the management system by organizing you data to use separate types of attributes, but this data cannot be synthesized well on the delivery system. As a general rule, you should create one type of attribute for your system. Multiple versions of the rest of the family members (the flex asset type, flex definition type, flex parent type, and flex parent definition type) must still share the same pool of attributes. For example, in the avisports sample site, the article asset type and the image asset type share the same attribute type. Therefore, you are able to create assetsets that contain an article and a corresponding image for that article.

Designing Flex Attributes

Before you begin creating attributes, design them on paper. Determine all the attributes you need and decide where they will appear, with flex assets or the flex parents. Start by planning out the bottom level of your hierarchy (that is, the individual instances of flex asset types like products) and determine the attributes you need for each item at that level. For example, before creating flex filter assets, determine which attributes must be created and assigned to the definitions as the input and output attributes for your filters.

You must determine all of the flex attributes that you need beforehand because the way you plan to use these attributes creates dependencies that you must account for when you create them.

Which Data Types Are Available for Attributes

Assess the data types that are available for attributes and the default input types for those data types. Determine which data types will work best for which attributes. To change the default input style for an attribute, you create an attribute editor for it before you create the attribute. See Designing Attribute Editors.

When you create a flex asset that uses an attribute of type blob, the format of the value entered for the attribute on an Inspect form depends on its type. For example, a text file shows the first 200 bytes in the file. An image file displays as a thumbnail image. And some files cannot be displayed at all. In this case, WebCenter Sites displays the message filename not displayable but the file location is still successfully recorded.

About Using Attribute Editors

The default input type for an attribute depends on the data type that you select for it. You can create an attribute editor instead of using the default input type.

Creating flex assets and their attribute editors is an iterative process. You can create the attribute editors first or the attributes first and then go back and assign the attribute editors. For information about process of creating attribute editors, see Designing Attribute Editors.

About Attributes of Type Blob

The default input style of an attribute of type blob is a text field with a Browse button. Click Browse to locate and select a file and WebCenter Sites uploads it to the default storage directory. You cannot use the WebCenter Sites forms to edit the contents of the file.

To be able to enter content directly into the external file through the WebCenter Sites forms, you must assign an attribute editor to the attribute:

  • For an attribute editor that uses the TEXTAREA input style, create a field that can hold up to 2,000 characters (entered through the forms). When saved, that content is written to the default storage directory.

  • In your CKEditor, you can use a CKEDITOR field to edit the contents of the external file that the attribute represents.

About Attributes of Type Asset

The default input style for an attribute of type asset is a drop-down list of all the assets of the type specified. An unfiltered drop-down list is not recommended for more than 20 assets of that type.

In general, whenever you create an attribute of type asset, you should assign it an attribute editor.

  • An attribute editor that uses the PICKASSET style checks to find out whether the tree is toggled on or off in the WebCenter Sites interface. If the tree is on, the user can select an asset from a tab in the tree. If the tree is toggled off, the attribute editor displays a dialog that lists the assets from the Bookmarks and History tabs.

  • Another option is to use the PULLDOWN style but to supply a query asset that limits the options that appear in the list.

  • For valid choices of assets that are small in number, use the CHECKBOXES or the RADIOBUTTONS input style, both of which require a query asset to identify the assets.

Where Will Each Attribute Be Used?

After you have determined the list of attributes, determine whether you plan to use them in a flex definition or a flex parent definition. Sort them logically by using the following guidelines:

  • An attribute whose value is unique to an individual flex asset (product, article, image, for example) belongs at the bottom of the tree, with the flex asset.

  • An attribute whose value is the same for multiple flex assets belongs in a parent. Of course there are always exceptions. For example, a toaster that costs the same amount as a bowling ball is unlikely to inherit its prices from a common parent.

  • Based on that attribute distribution, you can determine how many flex definitions you need and how many parent definitions you need.

Remember that there is both a physical limit (based on your DBMS) and a psychological limit (user satisfaction) as to how many attributes you can or should use in an individual flex asset or flex parent. Someone has to enter all those values. Be sure to create and then assign to the definitions only those attributes that you really plan to use. You can add more attributes when you need additional ones.

Attribute Dependencies Imposed by Hierarchy

After you know where an attribute will be used, you can determine whether hierarchical concerns add requirements to the attribute. For example, an attribute used by a flex parent must be configured to hold multiple values for data structure that allows flex assets to have multiple parents, because a flex asset might inherit multiple values for it. In general, try not to make the inheritance structure too complex.

How Many Definition Types Should You Create?

The appearance and input of data on the management system is based on the flex asset definitions and the flex parent definitions. Parents and flex assets appear on tabs in the tree based on the hierarchy that you create through the definitions.

In general, it is best to create a separate set of definition types for each flex asset member in a family. For example, in the avisports sample site, the article and image flex assets share the same attribute asset type, but they have different parents, and flex definitions. The definition for article assets contains only attributes that are relevant to articles, whereas, the definition for image assets contains only attributes that are relevant to image assets. Article and image assets that share the same parents and definitions will have some attributes left blank in both types of assets because some attributes won't apply to article assets and some to image assets.

Designing Parent Definition and Flex Definition Assets

The hierarchy on the tabs in the tree in the WebCenter Sites interfaces is created through the flex parent definitions and flex definitions:

  • To set a hierarchy three levels deep, you need at least two parent definitions and at least one flex definition.

  • To specify a hierarchy two levels deep, you need at least one parent definition and at least one flex definition.

Be sure to consider the basic tenets of usability when you set up a structural hierarchy with the flex definitions and flex parent definitions. For example:

  • How deep can the hierarchy go before the content providers feel lost in the tree?

  • How many attribute values can be inherited to alleviate the possibility of user error during input?

  • How many options can be comfortably displayed in a drop-down list?

The content providers won't like to use a complex system. Keep the following rules in mind as you design the data structure with a flex family for your online site:

  • Carefully planned, easy-to-use asset design (data design) makes content providers happy.

  • Usable layout and efficient code makes site visitors happy.

And both user groups need efficient systems that perform well.

Determining Hierarchical Place

You can log in to WebCenter Sites, access the avisports sample site, and examine the form for a new content parent definition or for a new content definition.

In the Parent Definition section of these forms, you determine two things:

  • The hierarchical position of the assets that use this definition.

  • The parents that they can inherit attributes from.

Remember that although the hierarchical position has meaning only in the Oracle WebCenter Sites: Contributor interface on the management system, the attributes that they inherit have meaning both on the management system and on your online site.

The text box named Available lists all the existing parent definitions. You use this section of the form to specify how many parents are possible, by selecting parent definitions from the Available list and moving them to the Selected list.

When you create a parent asset or a flex asset, the New form displays a definition field in which you specify a definition for the parent or flex asset. The definitions available for you to select are determined by the definitions you selected from the Available list when you created the definition you are using to create the parent or flex asset.

Note:

By default, the available definitions for the parent or flex asset you are creating are displayed in a drop-down list. However, when you create the parent definition, you can specify whether this will be displayed as a drop-down list, type ahead field, or drop zone (pick from tree) field.

The asset inherits the attribute values (if any) of the parent selected in the New form. The more parent definitions you select from the Available list, the more fields the content providers have to fill out when they create a new flex asset. Not selecting a parent definition in the Available list positions the assets created with this definition at the top level of the tree on the tab that displays your flex assets. The best way to understand how parent definitions, flex definitions, parent assets, and flex assets interact is to examine the assets delivered with the avisports sample site.

Determining Attribute Inheritance

You can configure attribute inheritance in the Attributes section of the parent definition form. You use that section to specify the attributes that define the parents that are created with this definition. When you create a parent with this definition, the values entered for these attributes are passed down to the flex assets that are children of the parent asset.

How Many Flex Parent Definition Assets?

Consider usability when you decide how many flex parent definition assets and how many parent assets of those definitions that you need. For short drop-down lists in the new parent and new flex asset form, create many parent definitions so that there are fewer parents with each definition. However, to have a small number of parent definitions and a large number of parents, create a tab that lists all the parents so the content providers can select the correct parent asset from the tab.

How Many Flex Definition Assets?

Create enough flex definitions so that fields (attributes) are not left blank on the New and Edit flex asset forms. Creating few definitions increases the form size with lots of attribute fields, not all of which apply for each asset. When you have long forms with lots of attribute fields, not only do content providers have to sort through the form to determine which attributes apply to the asset they are currently creating, the form takes a long time to be rendered in the user's browser.

The Flex Family Maker Utility

The Flex Family Maker utility creates flex families and their database tables. It writes information to the database tables and creates directories in the ElementCatalog table to which the utility copies elements.

  • Creates several database tables (the number depends on which flex asset types you create).

  • Writes information about the new flex family to these tables:

    • FlexAssetTypes: Holds a row for each flex asset member type.

    • FlexGrpTmplTypes: Holds a row for each flex parent definition type.

    • FlexGrpTypes: Holds a row for each flex parent type.

    • FlexTmplTypes: Holds a row for each flex definition type.

  • Creates new directories in the ElementCatalog table using the following naming convention:

    OpenMarket/Xcelerate/AssetType/NameOfYourAssetType

  • Copies elements from the ElementCatalog table to the directories created for your asset types. WebCenter Sites use these elements to format the New, Edit, Inspect, Search, and Search Results forms for assets of that type.

For information about the main database tables for flex assets and flex parent assets, see Flex Families and the Database.

Flex Asset Elements

The Flex Family Maker creates elements and SQL statements and stores them in appropriate database tables.

The Flex Family Maker copies elements for the new flex asset type to OpenMarket/Xcelerate/AssetType/NameOfAssetType in the ElementCatalog table. For example, the avisports sample site article asset elements are in:

OpenMarket/Xcelerate/AssetType/AVIArticle

It also creates a SQL statement that the search elements use and places it in the SystemSQL table under OpenMarket/Xcelerate/AssetType/NameOfAssetType.

For information on the elements and SQL statement that Flex Family Maker copies for you, see Elements and SQL Statements for the Asset Type. The elements for flex assets are the same as the elements for the basic assets with the exception of the AppendSelectDetailsSE element.

Setting Up Your Development System

Before you create a flex asset family, you need to set up your development system and get access to it.

  1. Create the appropriate WebCenter Sites sites.
  2. Create a user name for yourself that has administrator rights, and enable that user name on all of the sites on your development system.

    Without administrator rights, you do not have access to the Admin node in the General Admin tree, which means that you cannot perform some procedures in this chapter.

  3. Assign the Designer and GeneralAdmin roles to your user name so you will have access to all the trees in the WebCenter Sites Admin interface and all of the existing Start menu shortcuts for the assets in the sample site.

    Be sure that the TableEditor ACL is assigned to your user name.

    See Administering Oracle WebCenter Sites.

Creating a Flex Asset Family

For your flex asset data model you need to create flex asset types and individual data structure assets of those types: flex attributes, flex parent definitions, flex definitions, and flex parent assets.

These topics are presented in the order in which a new flex asset family should be created. So, to create a flex family for the first time, follow the procedure in the sequence given here:

Creating a Flex Family

To create a new flex family:

Note:

WebCenter Sites is case-insensitive to the names of the flex assets regardless of the underlying case-sensitivity of the database. If you create a flex family with the name of an existing asset but different case, WebCenter Sites adds the rest of the flex family under the existing asset type(s). For example, if the following flex family already exists {Product_A, Product_PD, Product_CD, Product_P, Product_C}, and you try to create this flex family: {PRODUCT_A, PRODUCT_PD, PRODUCT_CD, PRODUCT_P, myProduct_C}, then WebCenter Sites will use the existing asset types and create the following flex family: {Product_A, Product_PD, Product_CD, Product_P, myProduct_C}.

  1. In the General Admin tree, select the Admin node.

  2. Expand Flex Family Maker and click Add New Family.

    The Add New Flex Family form opens.

  3. In the Add New Flex Family form, fill in the following fields to name the members of the flex family:

    1. In the Flex Attribute field, enter the name of the new flex attribute asset type.

      The name you enter in this field is the internal name of the new attribute asset type. It becomes the name of the core table for this asset type and the prefix for all its auxiliary tables.

      Note:

      There are three suffixes reserved for use. Flex attributes cannot have a name end with _size, _type, or _file. For example, broadformsize is an acceptable flex attribute name; broadform_size is not.

    2. In the Flex Parent Definition field, enter the name of the new flex parent definition asset type.

      The name you enter in this field is the internal name of the new parent definition asset type. It becomes the name of the core table for this asset type and the prefix for all its auxiliary tables.

    3. In the Flex Definition field, enter the name of the new flex definition asset type.

      The name you enter in this field is the internal name of the new flex definition asset type. It becomes the name of the core table for this asset type and the prefix for all its auxiliary tables.

    4. In the Flex Parent field, enter the name of the new flex parent asset type.

      The name you enter in this field is the internal name of the new parent asset type. It becomes the name of the core table for this asset type and the prefix for all its auxiliary tables.

    5. In the Flex Asset field, enter the name of the new flex asset type.

      The name you enter in this field is the internal name of the new flex asset type. It becomes the name of the core table for this asset type and the prefix for all its auxiliary tables.

    6. In the Flex Filter field, enter the name of the new flex filter asset type.

      The name you enter in this field is the internal name of the new flex filter asset type. It becomes the name of the core table for this asset type and the prefix for all its auxiliary tables.

  4. Click Continue.

    The Add New Flex Family form opens. WebCenter Sites automatically populates the Description and Plural Form fields.

    Figure 6-1 Add New Flex Family Dialog

    This image shows the Add New Flex Family dialog.
  5. In the Add New Flex Family form, do the following:

    1. To enter your own values into the Description field for each member of the family, enter the external name of the asset type, that is, the name of the asset type when it is displayed in WebCenter Sites. This is the name that displays on the forms (New, Edit, Inspect, and so on).

    2. To enter your own values into the Plural Form field for each member of the family, enter the plural version of its name. This version is used in status messages and so on when appropriate.

  6. Click Add New Flex Family.

    Flex Family Maker creates the database tables that will store assets of these types.

    It also copies elements that format the forms for assets of these types to a directory with the name of the asset type in the ElementCatalog and SystemSQL tables.

(Conditional) Creating Additional Flex Family Members

To create additional flex family members (for example, if you need multiple flex parent asset types):

  1. In the General Admin tree, expand the Admin node, and then expand the flex family you just created.
  2. Drill down the flex family tree until you reach the type of flex family member you want to create (flex parent for example).
  3. Under the type of flex family member you want to create, double-click Add New Member Asset Type.

    The New Member Asset Type form opens.

    Figure 6-2 Flex Family Maker: New Parent Definition Asset Type Form

    Description of Figure 6-2 follows
    Description of "Figure 6-2 Flex Family Maker: New Parent Definition Asset Type Form"
  4. In the form, fill out the required fields and click Save.

    WebCenter Sites displays a message confirming that the asset type was created.

  5. Repeat this procedure for each additional flex family member you want to create.

(Conditional) Configuring the Flex Family Members

When the Flex Family Maker creates the new flex family, it also creates an icon and administrative forms for configuring the new flex family, located on the Admin tab.

  1. In the General Admin tree, expand the Admin node, and then expand the Asset Types icon.

  2. Under Asset Types, select one of the asset types in your new flex family. To see the asset types for your flex family in the list, right-click the navigation pane and choose Refresh All from the context menu, and then select an asset type in your new flex family.

  3. Click Edit.

    The Edit Asset Type form opens.

  4. In the Edit Asset Type form, do the following:

    1. In the Description field, change the value, if necessary. The text in this field is the name that WebCenter Sites uses for this asset type on the forms and lists in the WebCenter Sites interfaces. By default, Description is set to the value you specified in the Add New Flex Family form for that asset type.

    2. In the Plural Form field, change the value, if necessary. The text in this field is the text that WebCenter Sites uses in the WebCenter Sites interfaces when it is appropriate to refer to the asset type in the plural.

    3. In the Can Be a Child Asset field, change the value, if necessary. To allow the asset type to be the child asset type in an association field for another asset, set the value to True.

    4. In the Use Dimensions field, change the value if necessary. To enable this asset type to support the creation of multilingual content, set the value to True.

  5. Click Save.

  6. Repeat steps 1 to 5 for each flex family member you want to configure.

Enabling the New Flex Asset Types

Before you start creating assets (attributes, flex parent definitions, and so on), you must complete some steps on the Admin tab. Your login must grant you administrator rights to access to the Admin tab.

To enable the new flex asset types:

  1. In the General Admin tree, expand the Admin node, and then click the Sites icon and complete the following steps:

    1. Expand the site that you are going to use to work with these asset type.

    2. Under that site, select Asset Types and then Enable.

    3. Select your new asset types from the list and click Enable Asset Types.

      WebCenter Sites can automatically create a new start menu item or a search start menu item (or both) for the asset types you are enabling.

    4. Enable the option next to any available start menu item that you would like WebCenter Sites to create, as shown in the following figure:

      Figure 6-3 Start Menu Selection Dialog

      Description of Figure 6-3 follows
      Description of "Figure 6-3 Start Menu Selection Dialog"

      Generate these menu items now, or you or your site administrator must manually create them later (no one can create assets of the enabled asset types until start menu items are created for them).

  2. Click Enable Asset Types.

  3. The asset types are now enabled for the site(s). If you did not use WebCenter Sites to generate start menu items, you or your site administrator must now manually create them. As the developer of the asset types and the designer of the online site, your responsibility is to let the administrator know enough about your assets and site design that the site administrator can configure meaningful start menu items.

    You (the developers) must let the site and system administrators know which fields are used by the queries, collections, or other design elements for your online site so that they can create meaningful start menu items for the content providers.

  4. Repeat steps 1 through 3 for each site on which you want to enable these asset types.

After you or your administrator has created start menu items for your new asset types, you can create assets of these types.

Note:

You may have added your asset types to a tab in the tree. However, to create assets of these types you must create start menu shortcuts for them.

Create Flex Attributes

The steps can differ significantly based on the data type that you select for your attribute. Therefore, this section presents several procedures:

Creating Flex Attributes: Basic Procedure

This example shows you the basic procedure for creating flex attributes.

  1. In the menu bar, click New, and then select the name of your attribute type from the list of shortcuts. For example, New Product Attribute. To be able to select assignees for the workflow associated with this asset, choose at least one user from each role and click Set Assignees.

    The Product Attribute form opens.

    Figure 6-4 Product Attribute Form

    Description of Figure 6-4 follows
    Description of "Figure 6-4 Product Attribute Form"
  2. In the form, fill in the following fields:

    1. In the Name field, enter a name of up to 64 characters, excluding spaces.

    2. In the Description field, enter a short, descriptive phrase that describes the use or function of the attribute.

    3. In the Value Type field, select a data type for this attribute:

      For information about deciding which data type is appropriate for your attribute, see Data Types for Attributes.

    4. In the Number of Values field, select either single or multiple from the drop-down list, as appropriate for the data type that you selected in the Value Type field.

      To make this attribute available to a flex parent (if your data structure allows multiple flex parents for a flex asset), select multiple because the flex assets that inherit values for this attribute might inherit a value from multiple parents.

      Note:

      When an attribute is configured to accept multiple values, it displays on the flex parent and flex asset forms as a field with an Add Another Attribute Name button. To enable the attribute to accept multiple values for inheritance reasons without allowing content providers to select multiple values for the attribute for individual parents or flex assets, assign the attribute an attribute editor that presents it as a single-value field (but select multiple in the Value Type field).

      WebCenter Sites does not allow attributes of type text to have multiple values, due to the way these attributes are stored in the database. A message denoting this restriction displays if you attempt to save an attribute configured in such a way.

    5. To use any other input type than the default type for this attribute (which is based on the data type that you selected in the Value Type field), in the Attribute Editor field, select an attribute editor from the drop-down list.

      Note:

      If you select the CHECKBOXES attribute editor, ensure the Number of Values field is set to multiple.

      If you need more information about:

    6. To override the default ISO character set (ISO 8859-1), in the ISO Character Set field, enter the one you want to use for this attribute.

  3. Click Save.

Creating Flex Attributes of Type Blob (Upload Field)

This example shows you how to create a flex attribute of type Blob.

  1. Complete steps 1 through 2c in Creating Flex Attributes: Basic Procedure.
  2. In the Value Type field, select blob.
  3. (Optional) In the Folder field, enter a path to the directory that you want to store the attribute values in. The value you enter in this field is appended to the value set as the default storage directory (defdir) for the MungoBlobs table.
  4. In the Number of Values field, select single or multiple, as appropriate.
  5. If you do not want to use the default input type (a Browse button), in the Attribute Editor field and select one of the following:
    • An attribute editor that specifies the TEXTAREA input style.

    • If your system is configured to use CKEditor, an attribute editor that specifies the CKEDITOR input style.

  6. Click Save.
Creating Flex Attributes of Type Asset

To create an attribute of type asset:

  1. Complete steps 1 through 22.b in Creating Flex Attributes: Basic Procedure.
  2. In the Value Type field, select asset.
  3. In the Asset Type field, select an option from the drop-down list.
  4. In the Mirror Dependency Type field, select a dependency type.
  5. In the Number of Values field, select either single or multiple from the drop-down list, as appropriate for the data type that you selected in the Value Type field.

    If this attribute is to be used by a flex parent and your data structure allows flex assets to have multiple flex parents, you must select multiple because the flex assets who inherit values for this attribute might inherit a value from multiple parents.

  6. If the number of assets of the type you selected in the Number of Values field is more than 20, select one in the Attribute Editor field. For information about appropriate attribute editors, see About Using Attribute Editors.
  7. Click Save.
Creating Foreign Flex Attributes

To keep data in another system (a price list, for example) that you also want to use for your flex assets, create a foreign attribute that points to the column in the foreign table whose data you want to use as a flex attribute.

To create a foreign attribute:

  1. Register the foreign table that contains the data you want to use as a flex attribute.
  2. Complete steps 1 to 2d in Creating Flex Attributes: Basic Procedure.

    Note:

    In the Value Type field, you cannot select either asset or blob.

  3. If you plan to use WebCenter Sites flex asset forms to enter values for the attribute into the foreign table and you do not want to use the default input type for the data type that you selected in the Value Type field, in the Attribute Editor field, select an appropriate attribute editor.
  4. In the Editing Style field, do one of the following:
    • To use WebCenter Sites forms to enter values into this attribute's fields for the flex assets that use it, select local.

    • If you do not want users to be able to write values to this table through WebCenter Sites forms, select external.

  5. In the Storage Style field, select external from the drop-down list.
  6. In the External ID field, specify the name of the column that serves as the primary key for the table that holds this foreign attribute, that is, the column that uniquely identifies the attribute.
  7. In the External Table field, enter the name of the table that stores this attribute.
  8. In the External Column field, enter the name of the column in the table specified in the External Table that holds the values for this attribute.
  9. Click Save.

(Conditional) Creating Flex Filter Assets

Create a flex filter asset whose functionality is defined by one of the default WebCenter Sites filter classes.

Before you can create flex filter assets, the flex attributes that you plan to use as the input and output attributes must be created. Create the appropriate flex attributes if they don't exist yet. Note the following requirements:

  • For flex filters that use the Document Transformation filter type, the input and output attributes must be of type blob.

  • For any flex filter, the input attribute, output attribute, and flex filter asset must all belong to the same flex family.

For more information about flex filter classes, and detailed instructions on creating flex filter assets, see Creating Flex Filters.

To create a flex filter asset:

  1. In the menu bar, click New.
  2. In the list of asset types, select the type of filter you want to create. For example, New Media Filter. To be able to select assignees for the workflow associated with this asset, choose at least one user from each role and click Set Assignees.

    The Media Filter form opens.

    Figure 6-5 Media Filter Dialog

    This image shows the Media Filter dialog.
  3. In the New form, do the following:
    • In the Name field, enter a unique name for this filter asset.

    • In the Description field, enter a brief description summarizing the filter's function.

    • In the Filters field, select the filter class that will define the functionality of the flex filter asset you are creating. By default, the filter options are Doc-Type, Document Transformation, FieldCopier, and ThumbnailCreator.

      Note:

      Custom filter classes that may have been created for your system appear in this list. For information on creating a custom flex filter class, see Defining a Flex Filter Class and Creating a Flex Filter Asset.

    • Click Get Arguments. In the Arguments field, specify the input and output arguments for the flex filter asset. Click Add to add the arguments to the filter.

  4. Click Save.

Creating Parent Definition Assets

To create a parent definition asset:

  1. In the menu bar, click New.

  2. Select the name of your product definition asset from the list of shortcuts. For example, New Product Parent Definition. To be able to select assignees for the workflow associated with this asset, choose at least one user from each role and click Set Assignees.

    The Product Parent Definition form opens.

    Figure 6-6 Product Parent Definition Dialog

    This image shows the Product Parent Definition dialog.
  3. In the Product Parent Definition form, fill in the fields as follows:

    1. For Name, enter a name of up to 64 characters.

    2. For Description, enter a short descriptive phrase that describes the parent definition.

    3. For Parent Select Style, determine how flex parents that use this definition will be selected on the parent asset forms. Do one of the following:

      • If the number of parents of this type will be small, choose Select Boxes. Then, all the parents of this type will be displayed as options in a drop-down list on the flex asset forms.

      • If the number of parents of this type will be large, choose Pick From Tree. Then, when you select a parent of this type on the flex asset form, you select it from the tree on the tab that displays your catalog data.

    4. In the Product Parent Definitions section, select a parent definition from the Available list and then click one of the buttons described in the following table:

      Table 6-1 Buttons in Parent Definition Form

      Button in parent definition form Creates a field in the New parent form that does the following:

      Single Value: Required

      Forces you to select one parent for the field.

      Single Value: Optional

      Lets you select only one parent for the field.

      Multiple Value: Required

      Forces you to select at least one parent asset for the field.

      Multiple Value: Optional

      Lets you select multiple parent assets for the field.

      WebCenter Sites moves the parent definition from the Available list to the Selected list.

    5. Repeat step 3.d as many times as necessary. Remember that the corresponding New parent form will include a field for each item that you select in the Available list on this parent definition form.

    6. In the Attributes section, select the appropriate attributes from the Available list, and then do one of the following:

      • Click Required to specify that the attribute is required, that is, all flex parents created with this definition must have a value for this attribute.

      • Click Optional to specify that the attribute is optional.

      Note:

      To assign a flex filter asset to this parent definition in the future, you must include the input and output attributes that the flex filter uses.

      To order the attributes as you want them to appear on the parent form for parents of this type, use the Display Order arrows to the right of the Selected box.

    7. In the Filters section, select any flex filter assets that are appropriate for this parent definition.

  4. Click Save.

  5. Repeat this procedure for each parent definition asset that you have to create.

Creating Flex Definition Assets

To create a flex definition asset:

  1. In the menu bar, click New.

  2. Select the name of your flex definition asset type from the list of shortcuts. For example, New Product Definition. To be able to select assignees for the workflow associated with this asset, choose at least one user from each role and click Set Assignees.

    The Product Definition form opens.

  3. In the Product Definition form, fill in the fields as follows:

    1. In the Name field, enter a name of up to 64 characters.

    2. In the Description field, enter a short, descriptive phrase that describes the parent definition.

    3. In the Product Parent Definitions section, select a parent definition from the Available list and then click one of the buttons described in the following table:

      Table 6-2 Buttons in Flex Definition Form

      Button in flex definition form Creates a field in the New flex asset form that does the following:

      Single Value: Required

      Forces you to select only one parent in the field.

      Single Value: Optional

      Lets you select only one parent in the field.

      Multiple Value: Required

      Forces you to select at least one parent asset in the field.

      Multiple Value: Optional

      Lets you select multiple parent assets in the field.

      WebCenter Sites moves the parent definition from the Available list to the Selected list. For information about selecting parent definitions, see Determining Hierarchical Place.

    4. Repeat the previous step as many times as is necessary. Remember that the corresponding New Flex Asset form will include a field for each item that you select in the Available list on this flex definition form.

    5. In the Attributes section, select attributes from the Available list, and then do one of the following:

      • Click Required to specify that the attribute is required; that is, that all flex assets created with this definition must have a value for this attribute.

      • Click Optional to specify that the attribute is optional.

      Note:

      To assign a flex filter asset to this flex definition in the future, you must include the input and output attributes that the flex filter uses.

      To order the attributes as you want them to appear on the New and Edit forms for flex assets created with this definition, use the Display Order arrows to the right of the Selected box.

    6. In the Filters section, select any flex filter assets that are appropriate for this flex definition.

  4. Click Save.

  5. Repeat this procedure for each flex definition that you have to create.

Creating Flex Parent Assets

To create flex parent assets:

  1. Log in to WebCenter Sites as an administrator and select the Contributor interface.

  2. In the menu bar, select Content, then New, and then the type of flex parent asset you want to create.

    A tab opens displaying the Create view of the flex parent asset you want to create.

    Figure 6-7 Product Parent Dialog

    This image shows the Product Parent dialog.
  3. In the Product Parent form, fill in the fields as follows:

    1. In the Name field, enter a name of up to 64 characters.

    2. In the Product Parent Definition field, select a parent definition from the drop-down list. The definition you select formats the next sections of the form (the sections you fill out to define this parent asset).

    3. Click Continue.

    The Content section of the form opens.

    Figure 6-8 Content Section

    This image shows the Category: New (Category) dialog.
  4. In the Content section of the form, fill in the fields keeping in mind the following:

    • An asterisk (*) next to the field indicates that the field is required.

    • In this example, the field in which you designate a parent asset is called FSIIProductTopLevel. The parent that you drag and drop into this field becomes the grandparent of any flex assets you designate as children of the parent you are creating in this procedure. If this field is not required, and you do not select any parents (grandparents), the parent you are creating will be a top-level parent in the Content tree.

    • To determine whether the field is single or multi-valued, point to the drop zone associated with the field. A tooltip is displayed showing the type of assets this field accepts along with information about whether the field is single or multi-valued.

  5. Use the form section selector to switch to the next sections of the form (Marketing and Metadata sections). An asterisk (*) next to the field indicates that it is a required field.

    The fields displayed in these sections are based on the parent definition you chose for this parent. The values that you enter into these fields are inherited by any flex assets that have this parent asset as their parents.

  6. In the asset's toolbar, click the Save icon.

    WebCenter Sites writes the new parent to the database. All the information other than the attribute values are written to the FlexParent, FlexParent _AMap, and FlexParent_Extension tables, where FlexParent represents the internal name of your flex parents. The attribute values are written to the FlexParent _Mungo table.

Creating and Assigning Asset Type Icons (Contributor Interface Only)

When a user performs a search in the Contributor interface and displays the results of the search in the Thumbnail view, each asset in the search results list is represented by a thumbnail image. By default, the name, asset type, modification date, and locale of the assets in the search results list are displayed below the thumbnail image representing the asset or the asset's type. Images can either be assigned per asset or per asset type. The focus of this section is to assign a thumbnail image for each asset type.

You must create and assign images that uniquely identify the members of your new flex family.

  1. For each flex family member, do the following:

    1. Create two image files of type JPG, one to be displayed in the docked search results list, and the other to be displayed in the undocked search results list. The standard size of the image that will be displayed in the docked search results list is 96x96 pixels. The standard size of the image that will be displayed in the undocked search results list is 170x170 pixels.

    2. Name the image files as follows:

      • To name the image that will be displayed for the asset type in the docked search results list, use the syntax assetType.jpg.

      • To name the image that will be displayed for the asset type in the undocked search results list, use the syntax assetType_large.jpg.

      Note:

      You must save the images as JPGs. The file name determines the asset type for which the icon will be displayed. The name is case-sensitive.

    3. Place the image files in the appropriate directory:

      <cs_app_dir>/images/search

      where <cs_app_dir> is the directory of the deployed WebCenter Sites application on your application server.

  2. Restart your application server for the icons to appear in the Thumbnail view of the search results list in the Contributor interface.

Coding Templates for the Flex Assets

Creating your flex asset definitions and coding the templates for the flex assets that use those definitions is an iterative process. Although you have to create definitions and flex assets before you can create templates for your flex assets, it is likely that you will discover areas that need refinement in your data design only after you have coded a template and tested the code.

For information about coding elements for your templates, see Creating Template, CSElement, and SiteEntry Assets and Coding Elements for Templates and CSElements.

Testing Your Design (Creating Test Flex Assets)

To thoroughly test your design, you must examine where flex assets appear on the tree, what their forms look like, how long it takes to load their forms, and so on. Create some flex assets and examine them.

For information about creating assets, see Using Oracle WebCenter Sites.

(Conditional) Creating Flex Asset Associations

In most cases, you should use a flex asset's attributes to form associations. In the rare case that your associations must work across flex definitions, create associations between flex assets.

To create associations:

  1. In the General Admin tree, expand the Admin node, and then expand the Asset Types node.
  2. Expand the node for the asset type you want to create an association for.
  3. Expand the node for Asset Associations.
  4. Click Add New.

    The Add New Association form opens.

    Figure 6-9 Add New Association Dialog

    This image shows the Add New Association dialog.
  5. In the Add New Association form, fill in the fields as follows:
    • In the Name field, enter a name for the association.

    • In the Description field, enter a description of the association.

    • In the Child Asset field, select a child asset to associate with this asset.

    • In the Subtypes field, select one or more subtypes for this association.

    • In the Mirror Dependency Type field, select a dependency type for the associated flex asset.

    • In the Type of Association field, select one of the following:

      • Single valued - only one value allowed per asset.

      • Multivalued - multiple values allowed per asset.

  6. Click Add New Association to associate the flex asset types.

Moving Asset Types to Other Systems

After you finish creating your flex family, creating the data structure assets (including attribute editors), and coding templates for the flex asset type, system administrators can configure the asset types for the management system. They enable revision tracking where appropriate, create workflow processes, create start menu shortcuts, and so on.

Move your flex family, data structure assets, and coding templates to the management and delivery systems so system administrators can configure them. For information about moving your asset types to the management and delivery systems, see Administering Oracle WebCenter Sites.

What You May Need to Know About Editing Flex Attributes, Parents, and Definitions

Some editing tips that you can use when editing flex asset types to prevent schema changes that lead to data loss.

See these topics:

What You May Need to Know About Editing Attributes

Note the following when editing a flex attribute:

  • You can change the Name without causing a schema change. However, to import flex assets into your WebCenter Sites database using XMLPost, you must edit your XMLPost files if you change the name of an attribute.

  • You can change the Description without causing data loss.

  • If you change the data type in the Value Type field, you lose all data associated with the attribute in the _Mungo table(s) that use this attribute type.

  • If the attribute's data type is asset and you change the asset type, all existing data for the attribute is invalid.

  • If you change the Folder field for a blob attribute, WebCenter Sites will no longer be able to find any existing data for that attribute. If you must change this value, move the file system to match the new value that you set.

  • You can change the Number of Values from single to multiple without causing data loss or complications.

  • If you change the Number of Values from multiple to single, WebCenter Sites cannot determine which of the values in any existing rows are the values to keep.

  • You can change the Search Engine and ISO Character Set without causing data loss.

What You May Need to Know About Editing Parent Definitions and Flex Definitions

Note the following when editing a parent definition or a flex definition:

  • You can change the Name without causing a schema change. However, to import flex assets into your WebCenter Sites database using XMLPost, you must edit your XMLPost files if you change the name of a parent definition.

  • You can change the Description and the Parent Select Style fields without causing data loss.

  • If you change the parent selections:

    • Adding parents is allowed.

    • Removing parents can cause assets to no longer have valid data.

    • Changing parents from optional to required can cause problems because parents or flex assets who do not have one of the newly required parents are no longer valid.

    • Changing parents from required to optional is allowed.

    • Changing parents from single value to multiple value is allowed.

    • Changing parents from multiple value to single value causes unpredictable results because WebCenter Sites cannot determine which of the previously acceptable multiple values is the one to keep and which ones to remove.

  • If you change the attribute selections:

    • Adding optional attributes is allowed.

    • Adding required attributes causes existing parents or flex assets without them to be invalid.

    • Removing attributes causes existing parents or flex assets with such an attribute value to be invalid.

What You May Need to Know About Editing Parents and Flex Assets

Note the following when editing a flex or parent asset:

  • You can change the Name without causing a schema change. However, to import flex assets into your WebCenter Sites database using XMLPost, you must edit your XMLPost files if you change the name of a parent definition.

  • You can change the Description without causing data loss.

  • If you change parents, WebCenter Sites corrects all the inherited attribute values.

  • You cannot change the definition that you used to create the parent or flex asset.

  • Changing the value of an attribute is allowed. If you change the value of an attribute for a parent, WebCenter Sites corrects that attribute for all the assets that inherited it from this parent. Changing the attribute value for a flex asset is allowed.

Using Product Sets

When you’re managing an online catalog with WebCenter Sites, using the product set feature with product assets can help you group products that are identical but are packaged and sold differently.

See these topics:

About Using Product Sets

A book is the same book whether it is the paperback version or the hard-cover version. And a soft drink is the same soft drink whether it is sold in individual cans, as a six-pack, in a 2-liter bottle, or a case. Product sets allow you to group products like these together so that they can be displayed together (in the same form) on the management system, yet remain individual saleable units, identified as such by their SKUs.

The model for the product set feature is as follows:

  • The product set is a product parent that takes on the characteristics of a product asset. The product set (parent) has all of the attributes that define the core product.

  • The product assets are SKUs. That is, they have only those attributes that describe the packaging or are the unique identifiers for members of the set: the SKU, the bottle size, and so on.

  • The product set (parent) has an attribute that marks it as a product set and the value of this attribute is unique among all the product sets. This attribute is called GAProductSet and is a reserved name. The products in the set inherit this attribute and, by this inheritance, are marked as members of that product set (that is, children of that product parent).

Creating a Product Set

To create a product set:

  1. Create a product attribute named GAProductSet. This is a reserved name and your attribute name must match it exactly.
  2. Create a new product parent definition and select the GAProductSet attribute.
  3. Create a new product definition and designate that the parents created with the definition that you created in step 2 can be parents of products created with this product definition.
  4. Create a new product parent from the definition you created in step 2.
  5. Using the product definition that you created in step 3, create the products in the set and designate that the parent that you created in step 4 is their product parent.

Now, when you inspect or edit the product set (product parent), each product (SKU) in the set is listed on the Product Parent form, presenting a representation of the product set relationship.

There can be only one GAProductSet attribute in the WebCenter Sites database. To create product sets in multiple WebCenter Sites sites, you must share the GAProductSet attribute to the sites that you want to use it in.