Ecom:Product.Discount.Amount

Version: - double  

Summary

Returns the discount amount.

Settings

The value is based on the Amount field for the discount.

(Management Center - Ecommerce - Orders - Order discounts - Order discount - Discount - Discount Type - Amount)

Remarks

The tag is only available if the discount type is AMOUNT.

 

Examples

Outputting the template tag

@GetDouble("Ecom:Product.Discount.Amount")

Check if tag has a value

@if(!double.IsNullOrWhiteSpace(GetDouble("Ecom:Product.Discount.Amount"))) { @* Tag has value, so let's do something useful here. *@ }

Assign tag to a value for later use

@{ double storedTag = GetDouble("Ecom:Product.Discount.Amount"); }

Outputting the template tag

<!--@Ecom:Product.Discount.Amount-->

Check if double has a value

<!--@If Defined(@Ecom:Product.Discount.Amount)--> Let's output this tag here: <strong><!--@Ecom:Product.Discount.Amount--></strong> <!--@EndIf(@Ecom:Product.Discount.Amount)-->