yypsybs
2023-10-17 9ddc6a9215c98af29ec989b2a0f6cd69f06ff2f5
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
Quintiq file version 2.0
#parent: #root
Method VerificationData (
  GlobalOTDSOP globalOTDSOP
)
{
  TextBody:
  [*
    info( "策略个数:", globalOTDSOP.MatAttrSettingAndPlanStrategy( relsize ) );
    traverse ( globalOTDSOP, MatAttrSettingAndPlanStrategy, masaps ) {
      if ( masaps.PlanningStrategyCustom() <> "安全库存" and masaps.PlanningStrategyCustom() <> "JIT" and masaps.PlanningStrategyCustom() <> "M/A" and
           masaps.PlanningStrategyCustom() <> "PO拉料" and masaps.PlanningStrategyCustom() <> "VMI" ) {
        error( "手动设置策略错误:", masaps.MatCode() );     
      }
      
      if ( ( masaps.PlanningStrategyAuto() <> ""   and masaps.PlanningStrategyAuto() = "JIT" )  or 
           ( masaps.PlanningStrategyCustom() <> "" and masaps.PlanningStrategyCustom() = "JIT" ) 
          ) {
        if ( masaps.MinimumNumberOfDaysInStock() > 0 or masaps.MaximumNumberOfDaysInInventory() > 0 ) {
          error( "JIT策略存在最小和最大库存天数:", masaps.MatCode() );
        }
      }
    }
  *]
}