lazhen
2024-10-29 4419b51e5cfed824ca592ae5cba7654994ee005d
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
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
Quintiq file version 2.0
#parent: #root
StaticMethod Publish (
  InterfaceDataset owner,
  String executor
)
{
  TextBody:
  [*
    //// 甄兰鸽 Jul-17-2024 (created)
    requestbody :='[
        {
            "product": "DZ948293",
            "demandDate": "2024-10-01",
            "demandQty": 800,
            "versionName": "V2410204",
            "interfaceTime": "2024-10-01 12:00:00"
        }
    ]';
    loginfo := owner.InterfaceLoginfo( relnew, ExecuteUser := executor
                                       , Name := Translations::InterfaceDataset_CustomerDemandPPAIDS_Name()
                                       , InterfaceDateTime := DateTime::ActualTime()
                                       , Message := '客户需求(PPA+IDS)'
                                       , RequestBody := requestbody);
    
    InterfaceLoginfo::CallInterface( owner, loginfo );
    //if( not isnull( data ) ){
    //  
    //  cnv2 := StringToDate::StandardConverter();
    //  cnv2.SetCustomConversion();
    //  cnv2.CustomFormatString( 'yyyy-MM-dd' );
    //  
    //  sadatalist := construct( FinishedEngineInventorys );
    //  for( seq := 0;seq < data.Size();seq++){
    //    item := data.Get(seq);
    //    sadata := FinishedEngineInventory::GenerateData( loginfo, cnv2, item );
    //    sadatalist.Add( sadata );
    //  }
    //  
    //  options := DatasetFindOptions::Construct( 'MacroPlan' ).IncludeOffline( true ); //to load we must search offline datasets.
    //  mdskey := DatasetController::FindUnique( options );
    //
    //  MDSMacroPlan::Root( mdskey ) -> InventoryInterfaceData::SynchronizeInventory( owner, sadatalist );
    //}
  *]
}