¶Ô±ÈÐÂÎļþ |
| | |
| | | Quintiq file version 2.0 |
| | | #parent: #root |
| | | Relation CustomerDemandPPAIDS_InterfaceLoginfo_InterfaceLoginfo_CustomerDemandPPAIDS |
| | | { |
| | | #keys: '1[415136.0.1027064726]' |
| | | DefaultRelationStrategy |
| | | { |
| | | } |
| | | RelationSide.LeftSide InterfaceLoginfo |
| | | { |
| | | #keys: '3[415136.0.1027064728][415136.0.1027064727][415136.0.1027064729]' |
| | | Cardinality: '0to1' |
| | | ObjectDefinition: CustomerDemandPPAIDS |
| | | OwningSide: 'Reference' |
| | | } |
| | | RelationSide.RightSide CustomerDemandPPAIDS |
| | | { |
| | | #keys: '3[415136.0.1027064731][415136.0.1027064730][415136.0.1027064732]' |
| | | Cardinality: '1toN' |
| | | ObjectDefinition: InterfaceLoginfo |
| | | OwningSide: 'Reference' |
| | | } |
| | | } |
| | |
| | | StaticMethod GenerateData ( |
| | | const MacroPlan macroplan, |
| | | InterfaceDataset interfaceDataset, |
| | | String executor, |
| | | Boolean versionflag |
| | | ) |
| | | { |
| | |
| | | TextBody: |
| | | [* |
| | | // çå
°é¸½ Aug-20-2024 (created) |
| | | cdlast := maxobject( interfaceDataset, CustomerDemandPPAIDS, cd, cd.InterfaceTime(), cd.DemandDate(), cd.Product() ); |
| | | if( not isnull( cdlast ) ){ |
| | | loginfo := cdlast.InterfaceLoginfo(); |
| | | if( not loginfo.IsShow() ){ |
| | | loginfo.Delete(); |
| | | }else{ |
| | | loginfo.Last( false ); |
| | | } |
| | | interfaceDataset.CustomerDemandPPAIDS( relflush ); |
| | | } |
| | | nowdate := DateTime::ActualTime(); |
| | | loginfo := interfaceDataset.InterfaceLoginfo( relnew, ExecuteUser := executor |
| | | , Name := Translations::InterfaceDataset_CustomerDemandPPAIDS_Name() |
| | | , InterfaceDateTime := DateTime::ActualTime() |
| | | , Message := '客æ·éæ±ï¼PPA+IDSï¼æ°æ®æ¨é' |
| | | , IsShow := false |
| | | , Last := true |
| | | , ReturnSuccess := true |
| | | , ReturnMsg := 'Success' |
| | | , Success := true |
| | | ); |
| | | traverse( macroplan, SalesDemand.astype( Forecast ), forecast ){ |
| | | interfaceDataset.CustomerDemandPPAIDS( relnew, Product := forecast.ProductID() |
| | | cd :=interfaceDataset.CustomerDemandPPAIDS( relnew, Product := forecast.ProductID() |
| | | , DemandDate := forecast.StartDate() |
| | | , DemandQty := [Number]forecast.Quantity() |
| | | , VersionName := macroplan.ScenarioName() |
| | | , InterfaceTime := nowdate |
| | | , VersionFlag := versionflag |
| | | ); |
| | | loginfo.CustomerDemandPPAIDS( relinsert, cd ); |
| | | } |
| | | loginfo.TotalRow( loginfo.CustomerDemandPPAIDS( relsize ) ); |
| | | *] |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | Quintiq file version 2.0 |
| | | #parent: #root |
| | | Attribute IsShow |
| | | { |
| | | #keys: '3[415136.0.1027064712][415136.0.1027064711][415136.0.1027064713]' |
| | | Description: 'æ¯å¦æ¾ç¤º' |
| | | ValueType: Boolean |
| | | } |
¶Ô±ÈÐÂÎļþ |
| | |
| | | Quintiq file version 2.0 |
| | | #parent: #root |
| | | DefaultValue |
| | | { |
| | | ISOValue: 'true' |
| | | TargetAttribute: IsShow |
| | | } |
| | |
| | | Form.ApplyChanges(); |
| | | |
| | | if( efInterfacename.Text() = Translations::InterfaceDataset_CustomerDemandPPAIDS_Name() ){ |
| | | CustomerDemandPPAIDS::GenerateData( MacroPlan, InterfaceDataset, ifexpr( rbgVersionFlag.BoundValue() = "true", true, false ) ); |
| | | CustomerDemandPPAIDS::GenerateData( MacroPlan, InterfaceDataset, QuintiqUser::CurrentUser().DisplayName(), ifexpr( rbgVersionFlag.BoundValue() = "true", true, false ) ); |
| | | } |
| | | |
| | | Form.Close(); |