setConditionAmount
Synopsis
void setConditionAmount(SessionId sessionId,
BItemId itemIds,
string ppName,
string condType,
int counter,
decimal amount,
string currency,
CondGroupSelectionOptions options)
throws BasketServiceFault;
See also: SessionId, BItemId, CondGroupSelectionOptions, BasketServiceFault
Set the amount of the condition. currency must be “%” for conditions with calculation rule Percent, or (currently) equal to the document currency.
To set the condition amount of a header condition, itemIds must be the Null-ID. The set of selected items is determined based on the specified set of item IDs and the item selection options. If the resulting set contains exactly one article item, the operations operate on the corresponding item calculation. Otherwise they operate on a (temporary) group calculation that aggregates the individual item calculations.
The ppName argument may be an empty string if only one pricing procedure has been added to the basket. counter may be -1 if the calculation contains only one condition of the given type.
The operation fails if:
-
an attempt is made to set a value with the wrong sign.
-
the new amount is not within these bounds.
-
It is called for a folder
-
the aggregate condition or its amount are not editable.