1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
| Quintiq file version 2.0
| #parent: #root
| StaticMethod Create (
| StockingPoint_MPs owners,
| Account_MP account,
| String costDriver,
| Date start,
| String timeUnit,
| Number lengthOfTime,
| Real cost,
| Boolean isFromDB
| ) as owning StockingPointCosts
| {
| Description: 'Batch create'
| TextBody:
| [*
| // Batch create Stocking point costs
| stockingPointCosts := construct( StockingPointCosts );
|
| traverse( owners, Elements, owner )
| {
| obj := StockingPointCost::Create( owner.MacroPlan().IDHolder().GetStockingPointCostID(),
| owner,
| account,
| costDriver,
| start,
| timeUnit,
| lengthOfTime,
| cost,
| isFromDB );
| stockingPointCosts.Add( obj.astype( StockingPointCost ) );
| }
| return &stockingPointCosts;
| *]
| }
|
|