Tuesday 5 July 2011

Basics Of Attributes And Class With Example

Classes are a logical grouping of attributes that apply to the same set of products.

Versioning is now available.

·         Product Classes provide a way to organize and administer product attributes.When a product get associated with the product class then all the attributes with the class gets inherited in the product.
·         Subclasses are product classes that have a parent product class.They inherit the attributes of their parent product class.

Attributes are characteristics of a product that a customer can choose.

A Product attribute has two parts:-

·         Name
·         Value

Product Attributes and Product Features are similar in concepts.They both describe characteristics of the product that are of interest to customer but Product Feature do not create configurability.

Two Attribute Domain Types used as Standard are:-

Enumerated:-Specific values that the Attribute can have. (Eg: LOV Values)
Free Form:-User can freely any value against the Text Box of the Attribute.

Steps to Create Attributes and Classes:-

1. Navigate to Administration - Product --> Attribute Definitions and create new records as shown below


2. Drilldown on the Workspace of the Attributes.

3. Select the domain type as Enumerated, (Free form will allow one to enter values manually) and Create new Records in the Attribute Values applet.

4. Release the Attribute Definitions.


5. Then go to Product Classes view to create new Product Class.

6. Drilldown on the Current Workspace of the Product Class.

7. Go to Attributes view tab and create new record.Select the Attributes created in the Attribute Definition Column.


8. Then go to Products view and lock the Product to attach the Product Class with the Product.Then Release the Product.



9. Test by Validating the Product.

Monday 4 July 2011

Display Static images in Product Configurator

Requirement: Configure the Pre-Defined UI Properties and place the image in the Server.

Solution:

Pre-defined UI Properties:
Below mentioned UI Properties are used to display images on Root Product or On Relationship.
: Display static Image on Product and Relationship in Product Configuration Screen

Property NameProductHeaderImage
Property ValueImages/<filename>
DescriptionThis property can be defined only on Root Product. This property Displays an image of the root product on every selection page. Image displays beneath item header, to the left of item labels. The default image area is 120×120 pixels square.




Property NameImage
Property ValueImages/<filename>
DescriptionThis UI Property can only be define on Relationships.The image displays on the right side of relationship header. The image is displayed full size.


*Image Location: In order to display the images on Product Configuration Screen in any Environment, the image must be stored in the Siebel installation directory in "\Public\enu\Images\" on that environment.

The default image is displayed as shown below:
 
Product Header Image:
· Navigate to Administration-Product -> Product Definition –> Workspace –> Properties Tab.
· Select Root product and define the UI Properties as shown below.

 
Relationship Image:
· Navigate to Administration-Product -> Product Definition –> Workspace –> Properties Tab.
· Select relationship and define the UI Properties as shown below.


 

After defining the properties the custom image will be displayed as shown below:


Changing The Display Name Of an Item Of Type Checkbox For a Customizable Product

In the Bookshelf > Product Administration Guide > Configurator Web Templates > Modifying the Display Name of Items
The following 3 steps are needed in order to change display name of items:
1. Creating a New UI Control Template. You do this by saving a copy of the UI control template you selected in the User Interface view. Then you insert a
variable name in the new template.
2. Assigning the New UI Control Template. Assign the new template to the item.
3. Defining a UI Property for the Item. Define a UI Property for the item. "
Note: In the Bookshelf it is mentioned to change the attribute CfgFieldName = "CxObjName" however this does not exist in the eCfgControlCheckJS.swt
template.
The above steps 2 and 3 remain the same. However for step 1 the following need to be considered when your changes are for a checkbox (based on
eCfgControlCheckJS.swt):
The eCfgControlCheckJS.swt contains the following code:
"...
Usage="CheckBox"
CfgFieldList="CfgFieldName:Name, CfgUIControl:lblName, HtmlAttrib_width:310, Default:Y*
CfgFieldName:RequireMoreChild, Default:Y*
CfgFieldName:Explanation, CfgUIControl:lblExplanation*
CfgFieldName:Customize, CfgUIControl:lblCustomize"
>
CfgJSShow="showCheckBox" CfgJSUpdateExclusion="updateExcludedItemForPort" CfgJSUpdateSelection="updatePortItemsForCheckBox"/>
..."
A) In case you would just need to add additional information for your checkbox.
The information you want to display is stored your UI Property "My_UI_Property" and you want to display it next to your item name. Then the following
changes can be done in the template:
Add the following line to your cfgFieldList definition:
CfgFieldName:.My_UI_Property, CfgUIControl:lblName, DataSource:Broker, NeedRefresh:N*
The part of the template would look like:
"...
Usage="CheckBox"
CfgFieldList="CfgFieldName:Name, CfgUIControl:lblName, HtmlAttrib_width:310, Default:Y*
CfgFieldName:.My_UI_Property, CfgUIControl:lblName, DataSource:Broker, NeedRefresh:N*
CfgFieldName:RequireMoreChild, Default:Y*
CfgFieldName:Explanation, CfgUIControl:lblExplanation*
CfgFieldName:Customize, CfgUIControl:lblCustomize"
>
..."
B) If you want to rename the item name with the value in your UI Property please note the following:
The Item name of the checkbox has additional functionality as it is displayed as a hyperlink when the checkbox is checked. Therefore, it is displayed via a
java script that is called in the template in tag by the following snippet: CfgJSShow="showCheckBox"
This actual java script is located in the cfgui.js file.Therefore, in order to change the display of the name you need to do the following:
1) change the .swt template
Instead of launching the showCheckBox script, launch your custom script: showCheckBox_Custom:
CfgJSShow="showCheckBox_Custom" CfgJSUpdateExclusion="updateExcludedItemForPort" CfgJSUpdateSelection="updatePortItemsForCheckBox"/>
2) change the cfgui.js file: (make sure to create a backup file before changing it)
2a) locate and function showCheckBox and copy it to showCheckBox_Custom.
Then change the showCheckBox_Custom function:
Call showDomainAndChildrenControl_Custom instead of showDomainAndChildrenControl
function showCheckBox_Custom (grpItemId)
{
showDomainAndChildrenControl_Custom (grpItemId, "checkbox");
}
2b) locate the function showDomainAndChildrenControl and copy it to
showDomainAndChildrenControl_Custom
function showDomainAndChildrenControl_Custom (grpItemId, controlType)
{
...
}
2c) change showDomainAndChildrenControl_Custom function:
locate the following line:
displayName=portDomainPropSet.GetProperty("CxObjName")
and change it to:
displayName=portDomainPropSet.GetProperty(".My_UI_Property")
2d) Save the files
3) Make sure to refresh the cache (browser and server)
This should change your checkbox display to the value defined in the UI property.
Please note: All your products that use your custom .swt file need to have the UI property defined in order to get the appropriate values for your
customization.