Rules Repeater server behavior
The Rules Repeater server behavior is applied to the table row (<tr>) that displays the one of the four available rules display sections: Discounts, Charges, Shipping and Tax.
The figure below shows the Rules Repeater server behavior as it is applied to the discount rules table row:
The server behavior parses the data containing the shopping cart contents and displays the data for each rule specific to that category. As you can see, each column contains server-side code that retrieves the rule name and corresponding line item total.
Note: The server-side code for the rule name and rule charge/discount value is available for insert as display text, or to be bound to the default value of a given form element using the Bindings panel (see Bindings in this section for more information).
The figure below shows the Rules Repeater server behavior as it is applied to the discount rules table row:
The server behavior parses the data containing the shopping cart contents and displays the data for each rule specific to that category. As you can see, each column contains server-side code that retrieves the rule name and corresponding line item total.
Note: The server-side code for the rule name and rule charge/discount value is available for insert as display text, or to be bound to the default value of a given form element using the Bindings panel (see Bindings in this section for more information).
To apply the Rules Repeater server behavior:
- In Code view, select the entire table row (<tr>content</tr>) within your display specific to a given rules category.
- In the Server Behaviors panel group, click the plus button and select eCart > Cart Display > Rules Repeater.
The Repeat Cart Region dialog box opens.
- Select the cart name that corresponds to the eCart Object specific to the shopping cart implementation for the given display.
- Click OK to apply the server behavior to the page.