コード例 #1
0
 public static function GetSoapObjectFromObject($objObject, $blnBindRelatedObjects)
 {
     if ($objObject->objParentPagerIndividual) {
         $objObject->objParentPagerIndividual = ParentPagerIndividual::GetSoapObjectFromObject($objObject->objParentPagerIndividual, false);
     } else {
         if (!$blnBindRelatedObjects) {
             $objObject->intParentPagerIndividualId = null;
         }
     }
     if ($objObject->objParentPagerStation) {
         $objObject->objParentPagerStation = ParentPagerStation::GetSoapObjectFromObject($objObject->objParentPagerStation, false);
     } else {
         if (!$blnBindRelatedObjects) {
             $objObject->intParentPagerStationId = null;
         }
     }
     if ($objObject->objParentPagerPeriod) {
         $objObject->objParentPagerPeriod = ParentPagerPeriod::GetSoapObjectFromObject($objObject->objParentPagerPeriod, false);
     } else {
         if (!$blnBindRelatedObjects) {
             $objObject->intParentPagerPeriodId = null;
         }
     }
     if ($objObject->objDropoffByParentPagerIndividual) {
         $objObject->objDropoffByParentPagerIndividual = ParentPagerIndividual::GetSoapObjectFromObject($objObject->objDropoffByParentPagerIndividual, false);
     } else {
         if (!$blnBindRelatedObjects) {
             $objObject->intDropoffByParentPagerIndividualId = null;
         }
     }
     if ($objObject->objPickupByParentPagerIndividual) {
         $objObject->objPickupByParentPagerIndividual = ParentPagerIndividual::GetSoapObjectFromObject($objObject->objPickupByParentPagerIndividual, false);
     } else {
         if (!$blnBindRelatedObjects) {
             $objObject->intPickupByParentPagerIndividualId = null;
         }
     }
     if ($objObject->dttDateIn) {
         $objObject->dttDateIn = $objObject->dttDateIn->__toString(QDateTime::FormatSoap);
     }
     if ($objObject->dttDateOut) {
         $objObject->dttDateOut = $objObject->dttDateOut->__toString(QDateTime::FormatSoap);
     }
     return $objObject;
 }
コード例 #2
0
 public static function GetSoapArrayFromArray($objArray)
 {
     if (!$objArray) {
         return null;
     }
     $objArrayToReturn = array();
     foreach ($objArray as $objObject) {
         array_push($objArrayToReturn, ParentPagerPeriod::GetSoapObjectFromObject($objObject, true));
     }
     return unserialize(serialize($objArrayToReturn));
 }