| 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
 | | Quintiq file version 2.0 |  | #parent: #root |  | StaticMethod FromSupplyPlanning ( |  |   GlobalOTDTable otdTable, |  |   MacroPlan macroPlan, |  |   MacroPlan mappingRoot, |  |   String mrpCalverNo |  | ) |  | { |  |   Description: |  |   [* |  |     SupplyPlanning转PRData |  |     todo 修改mappingRoot为MPSync |  |   *] |  |   TextBody: |  |   [* |  |     // yypsybs Sep-12-2023 (created) |  |     // 按MRPCalverNo查,已有旧记录时不处理 |  |     oldRecords := selectset( macroPlan, PRData, item, |  |                              item.MRPCalverNo() = mrpCalverNo ); |  |     if( isnull( oldRecords ) or oldRecords.Size() = 0 ) { |  |       pispips := ProductInStockingPointInPeriod::GetByMRPCalverNo( macroPlan, mrpCalverNo ); |  |       traverse( pispips, Elements, item, item.NewSupplyQuantity() > 0 ) { |  |         PRData::FromSupplyPlanning( otdTable, macroPlan, mappingRoot, item ); |  |       } |  |     } |  |   *] |  | } | 
 |