| | |
| | | |
| | | targetQuantity := targetQuantity - [Number]finalQuantity; |
| | | targetCell := minselect( targetCells, Elements, tempNAOPCell, tempNAOPCell.OrderNr() > 0 and tempNAOPCell.Quantity() > 0, tempNAOPCell.OrderNr() ); |
| | | finalQuantity := minvalue( targetQuantity, targetCell.Quantity() ); |
| | | currentCell := select( naopc, NewAssemblyOnlinePlanCell, tempNAOPCell, tempNAOPCell.NewAssemblyOnlinePlanRow() = targetCell.NewAssemblyOnlinePlanRow() ); |
| | | finalQuantity := minvalue( targetQuantity, guard( targetCell.Quantity(), 0.0 ) ); |
| | | currentCell := select( naopc, NewAssemblyOnlinePlanCell, tempNAOPCell, |
| | | guard( tempNAOPCell.NewAssemblyOnlinePlanRow() = targetCell.NewAssemblyOnlinePlanRow(), false ) ); |
| | | } |
| | | } |
| | | } |
| | |
| | | traverse ( ts, Elements.ProductInTrip, pit, pit.Quantity() > 0 and pit.ProductID() = ppr.ProductID() ) { |
| | | ppcell := select( ppr, PackagingPlanCell, tempPPCell, tempPPCell.PackagingPlanColumn().StartDate() = pit.Trip().Departure().Date() ); |
| | | |
| | | if ( pit.Trip().LaneLeg().AsOriginStockingPointLeg().StockingPoint_MP().ID().Regex( "外租库" ) and pit.Trip().LaneLeg().AsDestinationStockingPointLeg().StockingPoint_MP().ID().Regex( "线边库" ) ) { |
| | | ppcell.Unpacking( pit.Quantity() ); |
| | | } |
| | | |
| | | if ( pit.Trip().LaneLeg().AsOriginStockingPointLeg().StockingPoint_MP().ID().Regex( "线边库" ) and pit.Trip().LaneLeg().AsDestinationStockingPointLeg().StockingPoint_MP().ID().Regex( "外租库" ) ) { |
| | | ppcell.Package( pit.Quantity() ); |
| | | if ( not isnull( ppcell ) ) { |
| | | if ( pit.Trip().LaneLeg().AsOriginStockingPointLeg().StockingPoint_MP().ID().Regex( "外租库" ) and pit.Trip().LaneLeg().AsDestinationStockingPointLeg().StockingPoint_MP().ID().Regex( "线边库" ) ) { |
| | | ppcell.Unpacking( pit.Quantity() ); |
| | | } |
| | | |
| | | if ( pit.Trip().LaneLeg().AsOriginStockingPointLeg().StockingPoint_MP().ID().Regex( "线边库" ) and pit.Trip().LaneLeg().AsDestinationStockingPointLeg().StockingPoint_MP().ID().Regex( "外租库" ) ) { |
| | | ppcell.Package( pit.Quantity() ); |
| | | } |
| | | } |
| | | } |
| | | // traverse ( ppr, PackagingPlanCell, ppcell/*, ppcell.StartDate() <= Date::Construct( 2025, 1, 4 )*/ ) { |