Edit Template

About these pages
About Templates

This page will be used to edit the information about a user-defined template.

The ES_TemplateType.Name for this template has to be user-created, or we will not get to this page. In other words default templates cannot be edit by the store administrator.
 
If the user presses the Save button: The form is submitted. The scripts do a validation check, e.g. it checks to see if all the required fields have been filled in. If the data is valid, then the script calls the appropriate stored procedure to update the merchant database with the new values. We then go back to the previous page.
If the user presses the Cancel button: We simply go to the previous page.
 
Template Name
EM_Template.Name.
 
Template Description
EM_Template.Description.
 
First Template Attribute

Background Color
EM_Attribute.Name.
 
If there are no items to be displayed in the listbox then we will (dynamically) not display the following listbox.
The items in the selection box correspond to all the values that the selected attribute currently has. These may be obtained by running an appropriate query on the ES_AttributeValue table and getting a rowset containing EM_Attribute.Value.Value.

Select the attribute Value highlighted in the selection box above. Then go to the previous page.
 
If his attributes allows the user to add new values to it, then also display the following edit box that will allow the user to add his own value for this particular attribute. The user can only add the valued to the attributes that allow new values to be added to them i.e., for the attributes for which the ES_TemplateAttribute.IsNewValueAllowed is set to TRUE.
EM_TemplateAttributeOption.Value. This edit box allows the user to enter his own value to the template attribute if that particular attribute allows for this option.

Select the attribute value entered in the edit box above as the new (user-defined) value for this attribute.
 
Second Template Attribute

Background Color
EM_Attribute.Name.
 
If there are no items to be displayed in the listbox then we will (dynamically) not display the following listbox.
The items in the selection box correspond to all the values that the selected attribute currently has. These may be obtained by running an appropriate query on the ES_AttributeValue table and getting a rowset containing EM_Attribute.Value.Value.

Select the attribute Value highlighted in the selection box above. Then go to the previous page.
 
If his attributes allows the user to add new values to it, then also display the following edit box that will allow the user to add his own value for this particular attribute. The user can only add the valued to the attributes that allow new values to be added to them i.e., for the attributes for which the ES_TemplateAttribute.IsNewValueAllowed is set to TRUE.
EM_TemplateAttributeOption.Value. This edit box allows the user to enter his own value to the template attribute if that particular attribute allows for this option.

Select the attribute value entered in the edit box above as the new (user-defined) value for this attribute.
 
N-th Template Attribute

Background Color
EM_Attribute.Name.
 
If there are no items to be displayed in the listbox then we will (dynamically) not display the following listbox.
The items in the selection box correspond to all the values that the selected attribute currently has. These may be obtained by running an appropriate query on the ES_AttributeValue table and getting a rowset containing EM_Attribute.Value.Value.

Select the attribute Value highlighted in the selection box above. Then go to the previous page.
 
If his attributes allows the user to add new values to it, then also display the following edit box that will allow the user to add his own value for this particular attribute. The user can only add the valued to the attributes that allow new values to be added to them i.e., for the attributes for which the ES_TemplateAttribute.IsNewValueAllowed is set to TRUE.
EM_TemplateAttributeOption.Value. This edit box allows the user to enter his own value to the template attribute if that particular attribute allows for this option.

Select the attribute value entered in the edit box above as the new (user-defined) value for this attribute.