
Tips:
The main suppliers proceedings folder (CX_LOG_CUBE)
is connected in the slot „tradeAgreement“ on the order item. Therefore
it is not necessary to go through all PurchaseAccount subMonitors checking for
settings [0], which also indicates, that it is the main supplier. With a CX_ITEM
object (or any inherited one) in the stack, the following access path accesses
the main supplier object: Get(PurchaseItem().tradeAgreement.DimensionByCondition("type(owner)=CX_SUPPLIER").owner)
This structure is used for the following modules and can serve as a guideline:
Purchedt.mod: Several functions are called in the SupplierList SetFormat, executing all single sub-steps.
Autopure.mod: Macro GetUniqueIDAndNameOfMainSupplier provides main supplier number and name of the passed item.