Example #1
0
 /**
  * Factory method to create a DeletePreAlert object from an array
  * @param array $props - Associative array of initial properties to set
  * @return DeletePreAlert
  */
 public static function create(array $props)
 {
     $deletePreAlert = new DeletePreAlert();
     $deletePreAlert->UserCode = parent::getValue($props, "UserCode");
     $deletePreAlert->CarrierDeliveryNo = parent::getValue($props, "CarrierDeliveryNo");
     return $deletePreAlert;
 }
Example #2
0
 public static function create($props)
 {
     $requestSet = new RequestSet($props);
     $requestSet->Token = parent::getValue($props, 'Token');
     $requestSet->Data = parent::getValue($props, 'Data');
     return $requestSet;
 }
Example #3
0
 /**
  * Factory method to create an Address object from an array
  * @param array $props - Associative array of initial properties to set
  * @return WebHookData
  */
 public static function create(array $props)
 {
     $webHookData = new WebHookData();
     $webHookData->SeqID = parent::getValue($props, "SeqID");
     $webHookData->Type = parent::getValue($props, "Type");
     $webHookData->Timestamp = parent::getValue($props, "Timestamp");
     $webHookData->Data = parent::getValue($props, "Data");
     $webHookData->Signature = parent::getValue($props, "Signature");
     return $webHookData;
 }
Example #4
0
 /**
  * Factory method to create an Address object from an array
  * @param array $props - Associative array of initial properties to set
  * @return WareHouse
  */
 public static function create(array $props)
 {
     $wareHouse = new WareHouse();
     $wareHouse->PostCode = parent::getValue($props, "PostCode");
     $wareHouse->SupportProducts = parent::getValue($props, "SupportProducts");
     $wareHouse->Tel = parent::getValue($props, "Tel");
     $wareHouse->WareHouseAddress = parent::getValue($props, "WareHouseAddress");
     $wareHouse->WareHouseCode = parent::getValue($props, "WareHouseCode");
     $wareHouse->WareHouseName = parent::getValue($props, "WareHouseName");
     return $wareHouse;
 }
Example #5
0
 /**
  * Factory method to create an Address object from an array
  * @param array $props - Associative array of initial properties to set
  * @return Item
  */
 public static function create(array $props)
 {
     $item = new Item();
     $item->Brand = parent::getValue($props, "Brand");
     $item->ItemDeclareType = parent::getValue($props, "ItemDeclareType");
     $item->ItemNameEnglish = parent::getValue($props, "ItemNameEnglish");
     $item->ItemNameLocalLang = parent::getValue($props, "ItemNameLocalLang");
     $item->ItemNumber = parent::getValue($props, "ItemNumber");
     $item->ItemSKU = parent::getValue($props, "ItemSKU");
     $item->ItemTotalAmount = parent::getValue($props, "ItemTotalAmount");
     $item->ItemUnitPrice = parent::getValue($props, "ItemUnitPrice");
     $item->SpecValue = parent::getValue($props, "SpecValue");
     $item->SpecUnit = parent::getValue($props, "SpecUnit");
     $item->Specifications = parent::getValue($props, "Specifications");
     return $item;
 }
Example #6
0
 /**
  * Factory method to create a CreatePreAlert object from an array
  * @param array $props - Associative array of initial properties to set
  * @return CreatePreAlert
  */
 public static function create(array $props)
 {
     $preAlert = new CreatePreAlert();
     $preAlert->AttachParam = parent::getValue($props, "AttachParam");
     $preAlert->CarrierCompanyCode = parent::getValue($props, "CarrierCompanyCode");
     $preAlert->CarrierDeliveryNo = parent::getValue($props, "CarrierDeliveryNo");
     $preAlert->City = parent::getValue($props, "City");
     $preAlert->ConsigneeEMail = parent::getValue($props, "ConsigneeEMail");
     $preAlert->ConsigneeIDBackCopy = parent::getValue($props, "ConsigneeIDBackCopy");
     $preAlert->ConsigneeIDFrontCopy = parent::getValue($props, "ConsigneeIDFrontCopy");
     $preAlert->ConsigneeIDNumber = parent::getValue($props, "ConsigneeIDNumber");
     $preAlert->ConsigneeIDType = parent::getValue($props, "ConsigneeIDType");
     $preAlert->ConsigneeMobile = parent::getValue($props, "ConsigneeMobile");
     $preAlert->ConsigneeName = parent::getValue($props, "ConsigneeName");
     $preAlert->ConsigneePostCode = parent::getValue($props, "ConsigneePostCode");
     $preAlert->ConsigneeStreetDoorNo = parent::getValue($props, "ConsigneeStreetDoorNo");
     $preAlert->CountryOfDestination = parent::getValue($props, "CountryOfDestination");
     $preAlert->District = parent::getValue($props, "District");
     $preAlert->HasInsure = parent::getValue($props, "HasInsure");
     $preAlert->OperatingInstructions = parent::getValue($props, "OperatingInstructions");
     $preAlert->ItemDeclareCurrency = parent::getValue($props, "ItemDeclareCurrency");
     $preAlert->Province = parent::getValue($props, "Province");
     $preAlert->ReceiptCountry = parent::getValue($props, "ReceiptCountry");
     $preAlert->ServiceTypeCode = parent::getValue($props, "ServiceTypeCode");
     $preAlert->ShipperOrderNo = parent::getValue($props, "ShipperOrderNo");
     $preAlert->TaxMode = parent::getValue($props, "TaxMode");
     $preAlert->UserCode = parent::getValue($props, "UserCode");
     $preAlert->WarehouseCode = parent::getValue($props, "WarehouseCode");
     $preAlert->WarehouseOperateMode = parent::getValue($props, "WarehouseOperateMode");
     if (isset($props['ITEMS'])) {
         foreach ($props['ITEMS'] as $item) {
             $preAlert->ITEMS[] = Item::create($item);
         }
     }
     $preAlert->ValueAddedServiceType = parent::getValue($props, "ValueAddedServiceType");
     return $preAlert;
 }