コード例 #1
0
ファイル: PayRPTOP2.php プロジェクト: armic/erpts
 function displayBacktaxTD($tdID)
 {
     $BacktaxTDDetails = new SoapObject(NCCBIZ . "BacktaxTDDetails.php", "urn:Object");
     if (!($xmlStr = $BacktaxTDDetails->getBacktaxTD($tdID))) {
         $this->tpl->set_var("BacktaxTDTableBlock", "");
         $this->backtaxTDExists = false;
         return false;
     } else {
         if (!($domDoc = domxml_open_mem($xmlStr))) {
             $this->tpl->set_var("BacktaxTDTableBlock", "");
             $this->backtaxTDExists = false;
             return false;
         } else {
             $backtaxTD = new BacktaxTD();
             $backtaxTD->parseDomDocument($domDoc);
             $backtaxTDID = $backtaxTD->getBacktaxTDID();
             $paidStatus = $backtaxTD->getPaidStatus();
             if ($paidStatus == "PAID") {
                 return false;
             }
             $tdID = $backtaxTD->getTdID();
             $yearRange = $backtaxTD->getStartYear() . " - " . $backtaxTD->getEndYear();
             $totalAssessedValue = $backtaxTD->getAssessedValue();
             $totalBasicTax = $backtaxTD->getBasicTax();
             $totalSEFTax = $backtaxTD->getSefTax();
             $totalPenalties = $backtaxTD->getPenalties();
             $totalIdleTax = $backtaxTD->getIdleTax();
             $totalPaid = $backtaxTD->getPaid();
             $totalBacktaxDue = $backtaxTD->getTotalTaxDue();
             $totalTaxes = 0;
             $totalTaxes += $totalBasicTax;
             $totalTaxes += $totalSEFTax;
             $totalTaxes += $totalPenalties;
             $totalTaxes += $totalIdleTax;
             $this->tpl->set_var("backtaxTDID", $backtaxTDID);
             $this->tpl->set_var("tdID", $tdID);
             $this->tpl->set_var("yearRange", $yearRange);
             $this->tpl->set_var("totalTaxes", number_format($totalTaxes, 2));
             //$this->tpl->set_var("totalBacktaxAssessedValue", number_format($totalAssessedValue,2));
             //$this->tpl->set_var("totalBasicTax", number_format($totalBasicTax,2));
             //$this->tpl->set_var("totalSEFTax", number_format($totalSEFTax,2));
             //$this->tpl->set_var("totalPenalties", number_format($totalPenalties,2));
             //$this->tpl->set_var("totalIdleTax", number_format($totalIdleTax,2));
             $this->tpl->set_var("totalPaid", number_format($totalPaid, 2));
             $this->tpl->set_var("totalBacktaxDue", $totalBacktaxDue);
             $this->tpl->set_var("totalBacktaxDueStr", number_format($totalBacktaxDue, 2));
             $this->tpl->parse("BacktaxTDTableBlock", "BacktaxTDTable", true);
             $this->backtaxTDExists = true;
             return true;
         }
     }
 }