| | |
| | | // 甄兰鸽 Jul-22-2024 (created) |
| | | address := Translations::InterfaceDataset_Address(); |
| | | httpinterface := HTTPInterface::Create( address,80); |
| | | |
| | | if( loginfo.Name() = Translations::InterfaceDataset_ShippingActualData_Name() ){//发运实际数据 |
| | | |
| | | httpinterface.URL( Translations::InterfaceDataset_ShippingActualData_URL() ); |
| | | httpinterface.MediaType( Translations::InterfaceDataset_ContentType() ); |
| | | httpinterface.PostMethod( true ); |
| | | try{ |
| | | httpinterface.AddHeader("Authorization",InterfaceLoginfo::CallToken()) |
| | | try{ |
| | | if( loginfo.Name() = Translations::InterfaceDataset_ShippingActualData_Name() ){//发运实际数据 |
| | | |
| | | httpinterface.URL( Translations::InterfaceDataset_ShippingActualData_URL() ); |
| | | httpinterface.MediaType( Translations::InterfaceDataset_ContentType() ); |
| | | httpinterface.PostMethod( true ); |
| | | httpinterface.AddHeader("Authorization",InterfaceLoginfo::CallToken( Translations::InterfaceDataset_ShippingActualData_Secret() )) |
| | | |
| | | httpinterface.Call( loginfo.RequestBody() ); |
| | | |
| | | result := httpinterface.Result(); |
| | | loginfo.Response( result ); |
| | | loginfo.Success( true ); |
| | | }onerror{ |
| | | loginfo.ReturnMsg( e.GeneralInformation() ); |
| | | } else if ( loginfo.Name() = Translations::InterfaceDataset_MachineStockData_Name() ){//库存数据(机加库存) |
| | | httpinterface.URL( Translations::InterfaceDataset_MachineStockData_URL() ); |
| | | httpinterface.MediaType( Translations::InterfaceDataset_ContentType() ); |
| | | httpinterface.PostMethod( true ); |
| | | httpinterface.AddHeader("Authorization",InterfaceLoginfo::CallToken( Translations::InterfaceDataset_MachineStockData_Secret() )) |
| | | |
| | | httpinterface.Call( loginfo.RequestBody() ); |
| | | |
| | | result := httpinterface.Result(); |
| | | loginfo.Response( result ); |
| | | loginfo.Success( true ); |
| | | } |
| | | }onerror{ |
| | | loginfo.ReturnMsg( e.GeneralInformation() ); |
| | | } |
| | | //后续公共处理 |
| | | loginfo.FinishTime( DateTime::ActualTime() ); |