Ejemplo n.º 1
0
 function displaySucceedingOD()
 {
     $ODHistoryList = new SoapObject(NCCBIZ . "ODHistoryList.php", "urn:Object");
     if (!($xmlStr = $ODHistoryList->getSucceedingODList($this->formArray["odID"]))) {
         $this->tpl->set_block("rptsTemplate", "SucceedingODList", "SucceedingODListBlock");
         $this->tpl->set_var("SucceedingODListBlock", "");
     } else {
         if (!($domDoc = domxml_open_mem($xmlStr))) {
             $this->tpl->set_block("rptsTemplate", "SucceedingODList", "SucceedingODListBlock");
             $this->tpl->set_var("SucceedingODListBlock", "");
         } else {
             $odHistoryRecords = new ODHistoryRecords();
             $odHistoryRecords->parseDomDocument($domDoc);
             $arrayList = $odHistoryRecords->getArrayList();
             if (count($arrayList)) {
                 $this->tpl->set_block("rptsTemplate", "SucceedingODDBEmpty", "SucceedingODDBEmptyBlock");
                 $this->tpl->set_var("SucceedingODDBEmptyBlock", "");
                 $this->tpl->set_block("rptsTemplate", "SucceedingODList", "SucceedingODListBlock");
                 $this->tpl->set_block("SucceedingODList", "SucceedingODPersonList", "SucceedingODPersonListBlock");
                 $this->tpl->set_block("SucceedingODList", "SucceedingODCompanyList", "SucceedingODCompanyListBlock");
                 foreach ($arrayList as $key => $value) {
                     $ODDetails = new SoapObject(NCCBIZ . "ODDetails.php", "urn:Object");
                     if (!($xmlStr = $ODDetails->getOD($value->getPresentODID()))) {
                         // error xml
                     } else {
                         if (!($domDoc = domxml_open_mem($xmlStr))) {
                             // error domdoc
                         } else {
                             $succeedingOD = new OD();
                             $succeedingOD->parseDomDocument($domDoc);
                             $this->tpl->set_var("odID", $succeedingOD->getOdID());
                             $this->tpl->set_var("transactionCode", $value->getTransactionCode());
                             $oValue = $succeedingOD->owner;
                             $pOwnerStr = "";
                             if (count($oValue->personArray)) {
                                 foreach ($oValue->personArray as $pKey => $pValue) {
                                     $this->tpl->set_var("personID", $pValue->getPersonID());
                                     $this->tpl->set_var("OwnerPerson", $pValue->getFullName());
                                     $this->tpl->parse("SucceedingODPersonListBlock", "SucceedingODPersonList", true);
                                 }
                             }
                             if (count($oValue->companyArray)) {
                                 foreach ($oValue->companyArray as $cKey => $cValue) {
                                     $this->tpl->set_var("companyID", $cValue->getCompanyID());
                                     $this->tpl->set_var("OwnerCompany", $cValue->getCompanyName());
                                     $this->tpl->parse("SucceedingODCompanyListBlock", "SucceedingODCompanyList", true);
                                 }
                             }
                             if (count($oValue->personArray) || count($oValue->companyArray)) {
                                 $this->tpl->set_var("none", "");
                             } else {
                                 $this->tpl->set_var("none", "none");
                             }
                             if ($succeedingOD->locationAddress != "") {
                                 $this->tpl->set_var("locationAddress", $succeedingOD->locationAddress->getFullAddress());
                             }
                             $this->tpl->set_var("landArea", number_format($succeedingOD->getLandArea(), 2, '.', ','));
                         }
                     }
                     $this->tpl->set_var("odID", $value->getPresentODID());
                     $this->tpl->parse("SucceedingODListBlock", "SucceedingODList", true);
                     $this->tpl->set_var("SucceedingODPersonListBlock", "");
                     $this->tpl->set_var("SucceedingODCompanyListBlock", "");
                 }
             }
         }
     }
 }
Ejemplo n.º 2
0
 function displaySucceedingOD()
 {
     $ODHistoryList = new SoapObject(NCCBIZ . "ODHistoryList.php", "urn:Object");
     if (!($xmlStr = $ODHistoryList->getSucceedingODList($this->formArray["odID"]))) {
         $this->tpl->set_var("succeedingARPNumber", "");
         $this->tpl->set_var("succeedingUpdateCode", "");
     } else {
         if (!($domDoc = domxml_open_mem($xmlStr))) {
             $this->tpl->set_var("succeedingARPNumber", "");
             $this->tpl->set_var("succeedingUpdateCode", "");
         } else {
             $odHistoryRecords = new ODHistoryRecords();
             $odHistoryRecords->parseDomDocument($domDoc);
             $arrayList = $odHistoryRecords->getArrayList();
             if (count($arrayList)) {
                 $value = $arrayList[0];
                 $ODDetails = new SoapObject(NCCBIZ . "ODDetails.php", "urn:Object");
                 if (!($xmlStr = $ODDetails->getOD($value->getPresentODID()))) {
                     $this->tpl->set_var("succeedingARPNumber", "");
                     $this->tpl->set_var("succeedingUpdateCode", "");
                 } else {
                     if (!($domDoc = domxml_open_mem($xmlStr))) {
                         $this->tpl->set_var("succeedingARPNumber", "");
                         $this->tpl->set_var("succeedingUpdateCode", "");
                     } else {
                         $succeedingOD = new OD();
                         $succeedingOD->parseDomDocument($domDoc);
                         $succeedingODID = $succeedingOD->getOdID();
                         $succeedingAFS = $this->getAFSDetails($succeedingODID);
                         $this->tpl->set_var("succeedingARPNumber", $succeedingAFS->getARPNumber());
                         $this->tpl->set_var("succeedingUpdateCode", $value->getTransactionCode());
                     }
                 }
             }
         }
     }
 }
 function displayPrecedingOD()
 {
     $ODHistoryList = new SoapObject(NCCBIZ . "ODHistoryList.php", "urn:Object");
     if (!($xmlStr = $ODHistoryList->getPrecedingODList($this->formArray["odID"]))) {
         $this->tpl->set_var("precedingUpdateCode", "");
         $this->tpl->set_var("precedingARPNumber", "");
         $this->tpl->set_var("precedingAssessedValue", "");
     } else {
         if (!($domDoc = domxml_open_mem($xmlStr))) {
             $this->tpl->set_var("precedingUpdateCode", "");
             $this->tpl->set_var("precedingARPNumber", "");
             $this->tpl->set_var("precedingAssessedValue", "");
         } else {
             $odHistoryRecords = new ODHistoryRecords();
             $odHistoryRecords->parseDomDocument($domDoc);
             $arrayList = $odHistoryRecords->getArrayList();
             if (count($arrayList)) {
                 $value = $arrayList[0];
                 $ODDetails = new SoapObject(NCCBIZ . "ODDetails.php", "urn:Object");
                 if (!($xmlStr = $ODDetails->getOD($value->getPreviousODID()))) {
                     $this->tpl->set_var("precedingUpdateCode", "");
                     $this->tpl->set_var("precedingARPNumber", "");
                     $this->tpl->set_var("precedingAssessedValue", "");
                 } else {
                     if (!($domDoc = domxml_open_mem($xmlStr))) {
                         $this->tpl->set_var("precedingUpdateCode", "");
                         $this->tpl->set_var("precedingARPNumber", "");
                         $this->tpl->set_var("precedingAssessedValue", "");
                     } else {
                         $precedingOD = new OD();
                         $precedingOD->parseDomDocument($domDoc);
                         $precedingODID = $precedingOD->getOdID();
                         $precedingAFS = $this->getAFSDetails($precedingODID);
                         $this->tpl->set_var("precedingUpdateCode", $value->getTransactionCode());
                         $this->tpl->set_var("precedingARPNumber", $precedingAFS->getARPNumber());
                         $this->tpl->set_var("precedingAssessedValue", number_format($precedingAFS->getTotalAssessedValue(), 2, ".", ","));
                         // get previous owner of Auctioned property
                         $owner = $precedingOD->owner;
                         if (is_array($owner->personArray)) {
                             foreach ($owner->personArray as $p) {
                                 $ownerNamesArray[] = $p->getLastName() . ", " . $p->getFirstName() . " " . substr($p->getMiddleName(), 0, 1) . ".";
                             }
                         }
                         if (is_array($owner->companyArray)) {
                             foreach ($owner->companyArray as $c) {
                                 $ownerNamesArray[] = $c->getCompanyName();
                             }
                         }
                         if (is_array($ownerNamesArray)) {
                             $ownerNamesString = implode("<br>", $ownerNamesArray);
                             unset($ownerNamesArray);
                             $this->tpl->set_var("ownerNames", $ownerNamesString);
                         } else {
                             $this->tpl->set_var("ownerNames", "");
                         }
                     }
                 }
             }
         }
     }
 }