Ecom:StockUnit.Quantity
Version: - doubleSummary
Returns the amount/quantity of the unit registered at the stock location.
Settings
The value is based on the Quantity field for the stock location selected in Stock for the product.
(Ecommerce > Product catalog > Shop > Group > Product > Stock > Edit stock info > Quantity)
Examples
Outputting the template tag
@GetDouble("Ecom:StockUnit.Quantity")
Check if tag has a value
@if(!double.IsNullOrWhiteSpace(GetDouble("Ecom:StockUnit.Quantity"))) {
@* Tag has value, so let's do something useful here. *@
}
Assign tag to a value for later use
@{
double storedTag = GetDouble("Ecom:StockUnit.Quantity");
}
Outputting the template tag
<!--@Ecom:StockUnit.Quantity-->
Check if double has a value
<!--@If Defined(@Ecom:StockUnit.Quantity)-->
Let's output this tag here: <strong><!--@Ecom:StockUnit.Quantity--></strong>
<!--@EndIf(@Ecom:StockUnit.Quantity)-->