hongjli
2023-10-11 77b8d972800221d19bd0ea7f2a14b720920b16bb
_Main/BL/Type_CapacityAllocationResultsRuleConfiguration/StaticMethod_RecursiveGeneration.qbl
@@ -9,15 +9,28 @@
{
  TextBody:
  [*
    operations := selectset( macroPlan, Routing.RoutingStep.Operation, tempO,
                             exists( tempO, OperationOutput, tempOO, tempOO.ProductInStockingPoint_MP() = outputPISP ) );
    traverse ( operations, Elements, o ) {
      traverse ( o, OperationInput, tempOI ) {
        inputPISP := tempOI.ProductInStockingPoint_MP();
        CapacityAllocationResultsRuleConfiguration::RecursiveGeneration( macroPlan, tempOI.ProductInStockingPoint_MP(), firstPISP, startDate );
        info( "输入PISP:", inputPISP.Name(), "    输出PISP:", outputPISP.Name(), "    第一次PISP:", firstPISP.Name() );
    traverse ( outputPISP, ProcessOutput.AsProcessOutput, pmp ) {
      ontype( pmp ) {
        Operation as o : {
          traverse ( o, OperationInput, oi ) {
            oiPISP := oi.ProductInStockingPoint_MP();
            CapacityAllocationResultsRuleConfiguration::RecursiveGeneration( macroPlan, oiPISP, firstPISP, startDate );
            info( "输入PISP:", oiPISP.Name(), "    输出PISP:", outputPISP.Name(), "    第一次PISP:", firstPISP.Name() );
          }
        }
        LaneLeg as ll : {
          traverse ( ll, LaneLegInput, lli ) {
            lliPISP := lli.ProductInStockingPoint_MP();
            if ( lliPISP.ProductID() = outputPISP.ProductID() ) {
              CapacityAllocationResultsRuleConfiguration::RecursiveGeneration( macroPlan, lliPISP, firstPISP, startDate );
              info( "输入PISP:", lliPISP.Name(), "    输出PISP:", outputPISP.Name(), "    第一次PISP:", firstPISP.Name() );
            }
          }
        }
      }
    }
  *]
}