IBM Support

How to use a dynamic condition within a pipeline for custom attributes?

Question & Answer


Question

How to use a dynamic condition within a pipeline for custom attributes?

Answer

Sometimes it becomes necessary to put a logic before transaction to drop the order into a drop status based on a condition. This can be done by putting a dynamic condition before a transaction and then dropping it to a drop status according to its true or false outcome.

Four attributes go into the dynamic method in the interface YCPDynamicConditionEx

evaluateCondition(YFSEnvironment env, java.lang.String name, java.util.Map mapData, org.w3c.dom.Document doc)

The document comes in as null if condition is placed in pipeline but it will feed the event xml in case placed within event handlers.

To use custom attributes, Condition variables 1 or 2 from the map can be used which are order line level attributes.The map structure is consistent and it cannot be modified.

[{"Product":{"code":"SS6PEW","label":"IBM Sterling Order Management"},"Business Unit":{"code":"BU048","label":"IBM Software"},"Component":"Not Applicable","Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"All","Edition":"","Line of Business":{"code":"LOB59","label":"Sustainability Software"}}]

Historical Number

HTG2656

Document Information

Modified date:
16 June 2018

UID

swg21563442