Allocations - CX_SINGLE_ALLOCATION
A single allocation describes a usage or a resource of a business object, depending on the point of view.
In our example above, the single allocation is described from the viewpoint of
business object Work Center (CX_WORK_STATION) a resource, from the viewpoint of the business object Machine (CX_MACHINE) a usage. As we can see, this is dependent on the type of backrelation from the individual allocation to the business object. In the case of a resource, a business object is referenced by the individual allocation via the back relation "allocators". In the case of a usage, the individual allocation points to the business object via the data field "object".
To show the use of a business object, it is not enough to know only the business object (to reference it via the "object" reference), you also need to specify the quantity of the business object that is "appropriated". This is described via the two data fields "amount" and "baseAmount", which are both attributes of the single allocation object.
- "Machine A with a time of 5 hours
( work plan )
- "Part B in a set of 17
( parts list )
- "Person C with a time of two hours
( project planning )
The business object (in the above examples A. B or C) is the "object" within a single allocation CX_SINGLE_ALLOCATION, the specifications "5 hours", "17 pieces" or "2 hours" describe the scope of use of the business object under consideration. In the business object itself, an individual allocation is linked via the back relation CX_BUSINESS_OBJECT allocations. The function CX_BUSINESS_OBJECT Allocators(os_set) returns all uses of a business object.
As shown in the above graphic, the single allocation describes a resource from the point of view of the work center. The individual allocation is referenced by the relationship "allocations". The backward relationship from the individual allocation to the business object is described by the relationship "allocators".