public static function GetObjectFromSoapObject($objSoapObject) { $objToReturn = new InventoryLocation(); if (property_exists($objSoapObject, 'InventoryLocationId')) { $objToReturn->intInventoryLocationId = $objSoapObject->InventoryLocationId; } if (property_exists($objSoapObject, 'InventoryModel') && $objSoapObject->InventoryModel) { $objToReturn->InventoryModel = InventoryModel::GetObjectFromSoapObject($objSoapObject->InventoryModel); } if (property_exists($objSoapObject, 'Location') && $objSoapObject->Location) { $objToReturn->Location = Location::GetObjectFromSoapObject($objSoapObject->Location); } if (property_exists($objSoapObject, 'Quantity')) { $objToReturn->intQuantity = $objSoapObject->Quantity; } if (property_exists($objSoapObject, 'CreatedByObject') && $objSoapObject->CreatedByObject) { $objToReturn->CreatedByObject = UserAccount::GetObjectFromSoapObject($objSoapObject->CreatedByObject); } if (property_exists($objSoapObject, 'CreationDate')) { $objToReturn->dttCreationDate = new QDateTime($objSoapObject->CreationDate); } if (property_exists($objSoapObject, 'ModifiedByObject') && $objSoapObject->ModifiedByObject) { $objToReturn->ModifiedByObject = UserAccount::GetObjectFromSoapObject($objSoapObject->ModifiedByObject); } if (property_exists($objSoapObject, 'ModifiedDate')) { $objToReturn->strModifiedDate = $objSoapObject->ModifiedDate; } if (property_exists($objSoapObject, '__blnRestored')) { $objToReturn->__blnRestored = $objSoapObject->__blnRestored; } return $objToReturn; }
public static function GetArrayFromSoapArray($objSoapArray) { $objArrayToReturn = array(); foreach ($objSoapArray as $objSoapObject) { array_push($objArrayToReturn, InventoryModel::GetObjectFromSoapObject($objSoapObject)); } return $objArrayToReturn; }
public static function GetObjectFromSoapObject($objSoapObject) { $objToReturn = new InventoryModelCustomFieldHelper(); if (property_exists($objSoapObject, 'InventoryModel') && $objSoapObject->InventoryModel) { $objToReturn->InventoryModel = InventoryModel::GetObjectFromSoapObject($objSoapObject->InventoryModel); } if (property_exists($objSoapObject, '__blnRestored')) { $objToReturn->__blnRestored = $objSoapObject->__blnRestored; } return $objToReturn; }