本文整理汇总了PHP中TD::getTaxBeginsWithTheYear方法的典型用法代码示例。如果您正苦于以下问题:PHP TD::getTaxBeginsWithTheYear方法的具体用法?PHP TD::getTaxBeginsWithTheYear怎么用?PHP TD::getTaxBeginsWithTheYear使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类TD
的用法示例。
在下文中一共展示了TD::getTaxBeginsWithTheYear方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: setDetails
//.........这里部分代码省略.........
$receivedFrom = $personArray[0]->getFirstName() . " " . $personArray[0]->getMiddleName() . " " . $personArray[0]->getLastName() . " et al.";
} else {
$receivedFrom = $personArray[0]->getFirstName() . " " . $personArray[0]->getMiddleName() . " " . $personArray[0]->getLastName();
}
} else {
if (is_array($companyArray)) {
if (count($companyArray) > 1) {
$receivedFrom = $companyArray[0]->getCompanyName() . " et al.";
} else {
$receivedFrom = $companyArray[0]->getCompanyName();
}
}
}
$formValues['receivedFrom'] = $receivedFrom;
}
//end if ($ctr > 0)
# tax dues are defined from TDNumber and taxableYear
# compute for taxes; to create dues obj pass tdID and due date (where due date is beginning of taxable year) -- 14 Aug 2003
// $taxDue = new Dues($id,$dateDue,$assessedValue);
$taxDue = new Dues();
/* if(!$taxDue->create($id,$dateDue)){
$taxDue->setBasic($assessedValue);
$taxDue->setSEF($assessedValue);
# check if land is idle, if yes, set assessed value
if($taxDue->getIdleStatus() == 1){
$taxDue->setIdle($assessedValue);
$idleStatus = 1;
}else{
$taxDue->setIdle(0);
$idleStatus = 0;
}
}
*/
$dateDue = $td->getTaxBeginsWithTheYear();
$taxDue = new Dues($id, $dateDue);
if (!$taxDue->create($id, $dateDue)) {
$taxDue->setBasic($assessedValue);
$taxDue->setSEF($assessedValue);
$taxDue->setIsDiscount(0);
# check if land is idle, if yes, set assessed value
# getIdleStatus -- temporary function
if ($taxDue->getIdleStatus() == 1) {
#echo("idle<br>");
$taxDue->setIdle($assessedValue);
}
} else {
$taxDue->setIsDiscount($dateDue == date("Y") && date("n") <= $taxDue->discountPeriod && $taxDue->getPaymentMode() == "Annual");
}
$paymentPeriod = $_POST['paymentPeriod'];
# set amnesty to object
//$amnesty = $_POST['amnesty'];
//$taxDue->setAmnesty($amnesty=="Yes");
// $taxDue->store();
$totalTaxDue = $taxDue->getTotalDue($paymentPeriod);
$totalAmount = $taxDue->getTotalDue($paymentPeriod);
// $paymentPeriod= "Annual";
/* if(isset($_POST['paymentPeriod'])){
$paymentPeriod = $_POST['paymentPeriod'];
}*/
$formValues['paymentPeriod'] = $paymentPeriod;
$this->tpl->set_var($formValues);
## Compute taxes and set the page values
//$totalTaxDue = $taxDue->getTotalDue($paymentPeriod);
$interest = $taxDue->getPctPenalty();
if ($interest > 0 && $paymentPeriod != "Annual") {
示例2: recordReceipt
//.........这里部分代码省略.........
$payments[4]->setPenalty("0");
$payments[4]->setDueID("000");
$payments[4]->setDueType("backtaxTD-pd1185,backtaxTDID=" . $backtaxTD->getBacktaxTDID());
$payments[4]->setReceiptNum($varValues['receiptNo']);
$payments[4]->storeRecord();
$collections->addPayment($payments[4]);
//$taxDue->reapplyPayments();
//$taxDue->store();
//print_r($payments);
if (!$proceed) {
break;
}
}
if (is_array($tdID)) {
foreach ($tdID as $key => $id) {
$td = new TD();
$td->selectRecord($id);
# get assessed value and use it to compute taxes -- 07 Aug 2003
$propertyType = $td->getPropertyType();
$propertyID = $td->getPropertyID();
$assessedValue = number_format($td->getAssessedValue(), 2, ".", "");
$tdNum = $td->getTaxDeclarationNumber();
$collections->setTDNum($tdNum);
# get the specific due by using the tdNum and the date on the RPTOP
$rptop = new RPTOP();
# changed to taxableYear & selected record using rptopID instead of rptopNum
if ($rptop->selectRecord($varValues['rptopID'])) {
$dueDate = $rptop->getTaxableYear();
} else {
# did not find due date in POST
// if there is no valid RPTOP provided, then just use the dueDate
$dueDate = $varValues['dueDate'];
}
$dueDate = $td->getTaxBeginsWithTheYear();
$taxDue = new Dues($id, $dueDate);
/*$taxDue = new Dues();*/
if (!$taxDue->create($id, $dueDate)) {
$taxDue->setBasic($assessedValue);
$taxDue->setSEF($assessedValue);
# check if land is idle, if yes, set assessed value
if ($taxDue->getIdleStatus() == 1) {
$taxDue->setIdle($assessedValue);
$idleStatus = 1;
} else {
$taxDue->setIdle(0);
$idleStatus = 0;
}
}
$paymentPeriod = $taxDue->getPaymentMode();
if ($taxDue->getPctPenalty() > 0 && $paymentPeriod != "Annual") {
$paymentPeriod = "Annual";
}
$application = $paymentPeriod;
if ($application == "Quarter") {
$application = "Q" . ceil(date("n") / 3);
$taxDue->setPaidQuarters(ceil(date("n") / 3));
}
#echo("b=$basic<br>s=$sef<br>i=$idle");
# if amnesty declared, no interest on late payments, set penalty to 0
if (isset($varValues['amnesty']) || $taxDue->getIsDiscount()) {
$taxDue->setAmnesty("Yes");
$taxDue->resetPenalty();
$interest = 0;
} else {
$taxDue->setAmnesty("No");
$interest = $taxDue->getPctPenalty();
示例3: Main
function Main()
{
switch ($this->formArray["formAction"]) {
case "save":
$DueEncode = new SoapObject(NCCBIZ . "DueEncode.php", "urn:Object");
if ($this->formArray["dueID"] != "") {
$DueDetails = new SoapObject(NCCBIZ . "DueDetails.php", "urn:Object");
if (!($xmlStr = $DueDetails->getDue($this->formArray["dueID"]))) {
$this->tpl->set_block("rptsTemplate", "Table", "TableBlock");
$this->tpl->set_var("TableBlock", "record not found");
} else {
if (!($domDoc = domxml_open_mem($xmlStr))) {
$this->tpl->set_block("rptsTemplate", "Table", "TableBlock");
$this->tpl->set_var("TableBlock", "error xmlDoc");
} else {
$dueArray = $this->setDues();
foreach ($dueArray as $due) {
$doc = $due->getDomDocument();
$xmlStr = $doc->dump_mem(true);
if (!($ret = $DueEncode->updateDue($xmlStr))) {
exit("error update");
}
unset($doc);
unset($xmlStr);
}
}
}
} else {
$dueArray = $this->setDues();
foreach ($dueArray as $due) {
$doc = $due->getDomDocument();
$xmlStr = $doc->dump_mem(true);
if (!($ret = $DueEncode->saveDue($xmlStr))) {
exit("error saving");
}
unset($doc);
unset($xmlStr);
}
}
$this->formArray["dueID"] = $ret;
header("location: DueClose.php" . $this->sess->url("") . $this->sess->add_query(array("rptopID" => $this->formArray["rptopID"])));
exit($ret);
break;
default:
// grab current tax rates from TreasurySettings
$treasurySettings = new TreasurySettings();
$treasurySettings->selectRecord();
$this->formArray["masterBasicTaxRate"] = $treasurySettings->getPctRPTax();
$this->formArray["masterSEFTaxRate"] = $treasurySettings->getPctSEF();
$this->formArray["masterIdleTaxRate"] = $treasurySettings->getPctIdle();
$this->formArray["discountPeriod"] = $treasurySettings->getDiscountPeriod();
$TDDetails = new SoapObject(NCCBIZ . "TDDetails.php", "urn:Object");
if (!($xmlStr = $TDDetails->getTD($this->formArray["tdID"]))) {
// xml failed
} else {
if (!($domDoc = domxml_open_mem($xmlStr))) {
// domDoc empty
} else {
$td = new TD();
$td->parseDomDocument($domDoc);
$this->formArray["afsID"] = $td->getAfsID();
$this->formArray["taxDeclarationNumber"] = $td->getTaxDeclarationNumber();
$this->formArray["taxBeginsWithTheYear"] = $td->getTaxBeginsWithTheYear();
}
}
unset($xmlStr);
unset($domDoc);
$AFSDetails = new SoapObject(NCCBIZ . "AFSDetails.php", "urn:Object");
if (!($xmlStr = $AFSDetails->getAFS($this->formArray["afsID"]))) {
// xml failed
} else {
if (!($domDoc = domxml_open_mem($xmlStr))) {
// domDoc empty
} else {
$afs = new AFS();
$afs->parseDomDocument($domDoc);
$this->formArray["assessedValue"] = $afs->getTotalAssessedValue();
$this->formArray["taxability"] = $afs->getTaxability();
$this->formArray["effectivity"] = $afs->getEffectivity();
$this->formArray["propertyType"] = $td->getPropertyType();
$this->formArray["idle"] = "No";
if ($td->getPropertyType() == "Land") {
if (is_array($afs->landArray)) {
// if land is stripped
if (count($afs->landArray) > 1) {
foreach ($afs->landArray as $land) {
if ($land->getIdle() == "Yes") {
$this->formArray["idle"] = "Yes";
break;
}
}
} else {
$this->formArray["idle"] = $afs->landArray[0]->getIdle();
}
}
}
if ($this->formArray["idle"] == "") {
$this->formArray["idle"] = "No";
}
}
//.........这里部分代码省略.........
示例4: displayTDDetails
function displayTDDetails()
{
$afsID = $this->formArray["afsID"];
$TDDetails = new SoapObject(NCCBIZ . "TDDetails.php", "urn:Object");
if (!($xmlStr = $TDDetails->getTD("", $afsID, "", ""))) {
// error xml
} else {
if (!($domDoc = domxml_open_mem($xmlStr))) {
// error domDoc
} else {
$td = new TD();
$td->parseDomDocument($domDoc);
$this->formArray["taxDeclarationNumber"] = $td->getTaxDeclarationNumber();
$this->formArray["memoranda"] = $td->getMemoranda();
$this->formArray["cancelsTDNumber"] = $td->getCancelsTDNumber();
$this->formArray["previousOwner"] = $td->getPreviousOwner();
$this->formArray["previousAssessedValue"] = $td->getPreviousAssessedValue();
$this->formArray["taxBeginsWithTheYear"] = $td->getTaxBeginsWithTheYear();
//edited May 28,2008 cityMunicipalAssessor
if (is_numeric($td->getCityMunicipalAssessor())) {
$cityMunicipalAssessor = new Person();
$cityMunicipalAssessor->selectRecord($td->cityMunicipalAssessor);
$this->formArray["cityAssessor"] = $cityMunicipalAssessor->getFullName();
} else {
$this->formArray["cityAssessor"] = $td->getCityMunicipalAssessor;
}
$this->formArray["propertyType"] = $td->getPropertyType();
}
}
}