StockStateTotals
Summary
The StockStateTotals
loop lets you display various information about the total amount by the stock state.
Examples
Basic usage
Notice the use of @item.GetValue to get data from the loop variable.
If you just write @GetValue, the data will be taken from outside the loop.
Similarly, you have to use @item.GetLoop to use loops inside a loop.
<table>
<tr>
@foreach (LoopItem item in GetLoop("StockStateTotals") {
<td> @item.GetValue("Relevant.Tag") </td>
}
</tr>
</table>
Check if the loop exists
@if (Loops.Contains("StockStateTotals")) {
...
}
Example of usage
The following general example illustrates how to use a loop construct.
<table>
<!--@LoopStart(StockStateTotals)-->
<tr>
<td><!--@Loop:Tag--></td>
</tr>
<!--LoopEnd(StockStateTotals)-->
</table>
Check if the loop exists
<!--@If LoopDefined(StockStateTotals)-->
...
<!--@EndIf(StockStateTotals)-->
Available tags
Ecom:StockStateTotals.TotalQuantity
Returns the total number of the specific unit.
RAZOR
@GetDouble("Ecom:StockStateTotals.TotalQuantity")
Ecom:StockStateTotals.TotalVolume
Returns the total volume of the specific unit.
RAZOR
@GetDouble("Ecom:StockStateTotals.TotalVolume")
Ecom:StockStateTotals.TotalWeight
Returns the total weight of the specific unit.
RAZOR
@GetDouble("Ecom:StockStateTotals.TotalWeight")
Ecom:StockStateTotals.Unit
Returns the name of the stock unit.
RAZOR
@GetString("Ecom:StockStateTotals.Unit")
Ecom:StockStateTotals.UnitID
Returns the ID of the stock unit.
RAZOR
@GetString("Ecom:StockStateTotals.UnitID")