当前位置: 首页>>代码示例>>PHP>>正文


PHP Payment::setPaymentDate方法代码示例

本文整理汇总了PHP中Payment::setPaymentDate方法的典型用法代码示例。如果您正苦于以下问题:PHP Payment::setPaymentDate方法的具体用法?PHP Payment::setPaymentDate怎么用?PHP Payment::setPaymentDate使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Payment的用法示例。


在下文中一共展示了Payment::setPaymentDate方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: Main


//.........这里部分代码省略.........
                 $idleReceipt->setPreviousReceiptNumber($idleReceiptArray["previousReceiptNumber"]);
                 $idleReceipt->setPreviousReceiptDate($idleReceiptArray["previousReceiptDate_year"] . "-" . putPreZero($idleReceiptArray["previousReceiptDate_month"] . "-" . putPreZero($idleReceiptArray["previousReceiptDate_day"])));
                 $idleReceipt->setCityTreasurer($this->formArray["cityTreasurer"]);
                 $idleReceipt->setDeputyTreasurer($this->formArray["deputyTreasurer"]);
                 $idleReceipt->setStatus("");
                 $idleReceipt->setDomDocument();
                 $domDoc = $idleReceipt->getDomDocument();
                 $xmlStr = $domDoc->dump_mem(true);
                 if (!($idleReceiptIDArray[$idleReceiptIDArrayIndex] = $ReceiptEncode->saveReceipt($xmlStr))) {
                     exit("error save idle receipt");
                 }
                 $receiptIDArray[] = $idleReceiptIDArray[$idleReceiptIDArrayIndex];
                 $idleReceiptIDArrayIndex++;
             }
             $lineCtr = 0;
             $basicReceiptIDArrayIndex = 0;
             $sefReceiptIDArrayIndex = 0;
             $idleReceiptIDArrayIndex = 0;
             if (is_array($this->formArray["payment"])) {
                 foreach ($this->formArray["payment"] as $formPaymentArray) {
                     $payment = new Payment();
                     $payment->setTdID($formPaymentArray["tdID"]);
                     $payment->setDueID($formPaymentArray["dueID"]);
                     $payment->setDueType($formPaymentArray["dueType"]);
                     $payment->setBacktaxTDID($formPaymentArray["backtaxTDID"]);
                     $payment->setTaxDue($formPaymentArray["taxDue"]);
                     $payment->setAdvancedPaymentDiscount($formPaymentArray["advancedPaymentDiscount"]);
                     $payment->setEarlyPaymentDiscount($formPaymentArray["earlyPaymentDiscount"]);
                     $payment->setPenalty($formPaymentArray["penalty"]);
                     $payment->setAmnesty($formPaymentArray["amnesty"]);
                     $payment->setBalanceDue($formPaymentArray["balanceDue"]);
                     $payment->setAmountPaid($formPaymentArray["amountPaid"]);
                     $payment->setDueDate($formPaymentArray["dueDate"]);
                     $payment->setPaymentDate($formPaymentArray["paymentDate"]);
                     $payment->setOwnerID($formPaymentArray["ownerID"]);
                     $payment->setDomDocument();
                     $domDoc = $payment->getDomDocument();
                     $xmlStr = $domDoc->dump_mem(true);
                     if (!($paymentID = $PaymentEncode->savePayment($xmlStr))) {
                         exit("error save payment");
                     }
                     //  basicCollection
                     if (is_array($formPaymentArray["basicReceipt"])) {
                         $basicReceiptID = $basicReceiptIDArray[$basicReceiptIDArrayIndex];
                         foreach ($formPaymentArray["basicReceipt"] as $basicCollectionArray) {
                             $basicCollection = new Collection();
                             $basicCollection->setPaymentID($paymentID);
                             $basicCollection->setReceiptID($basicReceiptID);
                             $basicCollection->setTaxType($basicCollectionArray["taxType"]);
                             $basicCollection->setTaxDue($basicCollectionArray["taxDue"]);
                             $basicCollection->setAdvancedPaymentDiscount($basicCollectionArray["advancedPaymentDiscount"]);
                             $basicCollection->setEarlyPaymentDiscount($basicCollectionArray["earlyPaymentDiscount"]);
                             $basicCollection->setPenalty($basicCollectionArray["penalty"]);
                             $basicCollection->setAmnesty($basicCollectionArray["amnesty"]);
                             $basicCollection->setBalanceDue($basicCollectionArray["balanceDue"]);
                             $basicCollection->setAmountPaid($basicCollectionArray["amountPaid"]);
                             $basicCollection->setDomDocument();
                             $domDoc = $basicCollection->getDomDocument();
                             $xmlStr = $domDoc->dump_mem(true);
                             if (!($basicCollectionID = $CollectionEncode->saveCollection($xmlStr))) {
                                 exit("error save basic collection");
                             }
                         }
                     }
                     //  sefCollection
                     if (is_array($formPaymentArray["sefReceipt"])) {
开发者ID:armic,项目名称:erpts,代码行数:67,代码来源:PaymentEncode.php

示例2: getPaymentById

 public function getPaymentById($payId)
 {
     $stmh = $this->db->prepare("SELECT * from Payment WHERE paymentId = :id");
     $sid = intval($payId);
     $stmh->bindParam(':id', $sid);
     $stmh->execute();
     $stmh->setFetchMode(\PDO::FETCH_ASSOC);
     if ($row = $stmh->fetch()) {
         $paymentData = new Payment();
         $paymentData->setPaymentDate($row['paymentDate']);
         $paymentData->setHours($row['hours']);
         $paymentData->setPaymentId($row['paymentId']);
         $paymentData->setPaymentAmount($row['paymentAmount']);
         $paymentData->setCustomerId($row['customerId']);
         return $paymentData;
     } else {
         return new Payment();
     }
 }
开发者ID:pnaika,项目名称:php_globalParkingSystem,代码行数:19,代码来源:SqliteRepository.php

示例3: Main

 function Main()
 {
     global $_POST;
     $this->tpl->set_var("uname", $this->user["uname"]);
     $this->tpl->set_var("today", date("F j, Y"));
     $this->setPageDetailPerms();
     $this->formArray["formAction"] = $_POST["formAction"];
     switch ($this->formArray["formAction"]) {
         case "applyPayment":
             // show owner
             $RPTOPDetails = new SoapObject(NCCBIZ . "RPTOPDetails.php", "urn:Object");
             if (!($xmlStr = $RPTOPDetails->getRPTOP($this->formArray["rptopID"]))) {
                 exit("xml failed");
             } else {
                 //echo($xmlStr);
                 if (!($domDoc = domxml_open_mem($xmlStr))) {
                     $this->tpl->set_block("rptsTemplate", "OwnerListTable", "OwnerListTableBlock");
                     $this->tpl->set_var("OwnerListTableBlock", "error xmlDoc");
                 } else {
                     $rptop = new RPTOP();
                     $rptop->parseDomDocument($domDoc);
                     //print_r($rptop);
                     if (is_object($rptop->owner)) {
                         //$RPTOPEncode = new SoapObject(NCCBIZ."RPTOPEncode.php", "urn:Object");
                         if (is_a($rptop->owner, "Owner")) {
                             $this->formArray["ownerID"] = $rptop->owner->getOwnerID();
                             $xmlStr = $rptop->owner->domDocument->dump_mem(true);
                             if (!$xmlStr) {
                                 $this->tpl->set_block("rptsTemplate", "OwnerListTable", "OwnerListTableBlock");
                                 $this->tpl->set_var("OwnerListTableBlock", "");
                             } else {
                                 if (!($domDoc = domxml_open_mem($xmlStr))) {
                                     $this->tpl->set_block("rptsTemplate", "OwnerListTable", "OwnerListTableBlock");
                                     $this->tpl->set_var("OwnerListTableBlock", "error xmlDoc");
                                 } else {
                                     $this->displayOwnerList($domDoc);
                                 }
                             }
                         } else {
                             $this->tpl->set_block("rptsTemplate", "PersonList", "PersonListBlock");
                             $this->tpl->set_var("PersonListBlock", "");
                             $this->tpl->set_block("rptsTemplate", "CompanyList", "CompanyListBlock");
                             $this->tpl->set_var("CompanyListBlock", "");
                         }
                     }
                 }
             }
             // gather payments
             $this->tdArray = $_POST["td"];
             if (is_array($this->tdArray)) {
                 foreach ($this->tdArray as $tdID => $tdElementArray) {
                     // grab dueID from tdID
                     $dueID = $dueType = $tdElementArray["dueType"];
                     // start: the following 'for' loop is an un_number_format sweep added February 10, 2005
                     foreach ($tdElementArray as $tdElementKey => $tdElementValue) {
                         $tdElementArray[$tdElementKey] = un_number_format($tdElementValue);
                     }
                     // end: un_number_format sweep loop of February 10, 2005
                     foreach ($tdElementArray as $tdElementKey => $tdElementValue) {
                         switch ($tdElementKey) {
                             case "amountPaid":
                                 if ($tdElementValue > 0) {
                                     $payment = new Payment();
                                     $payment->setPaymentID("");
                                     $payment->setTdID($tdID);
                                     $payment->setDueID($tdElementArray["dueID"]);
                                     $payment->setDueType($tdElementArray["dueType"]);
                                     $payment->setBacktaxTDID("");
                                     $payment->setTaxDue($tdElementArray["taxDue"]);
                                     $payment->setAdvancedPaymentDiscount($tdElementArray["advancedPaymentDiscount"]);
                                     $payment->setEarlyPaymentDiscount($tdElementArray["earlyPaymentDiscount"]);
                                     $payment->setPenalty($tdElementArray["penalty"]);
                                     $payment->setAmnesty($tdElementArray["amnesty"]);
                                     $payment->setBalanceDue($tdElementArray["balance"]);
                                     $payment->setAmountPaid(un_number_format($tdElementArray["amountPaid"]));
                                     $payment->setDueDate(date("Y-m-d", strtotime($tdElementArray["dueDate"])));
                                     $payment->setPaymentDate(date("Y-m-d", strtotime("now")));
                                     $payment->setOwnerID($this->formArray["ownerID"]);
                                     $payment->setTdNumber($this->getTDNumberFromPayment($tdID, ""));
                                     $payment->setBasicReceipt($this->initReceipt($payment, "basic"));
                                     $payment->setSefReceipt($this->initReceipt($payment, "sef"));
                                     $payment->setIdleReceipt($this->initReceipt($payment, "idle"));
                                     $this->paymentArrayList[] = $payment;
                                 }
                                 break;
                             case "btTD":
                                 if (is_array($tdElementValue)) {
                                     $btTDArray = $tdElementValue;
                                     foreach ($btTDArray as $backtaxTDID => $btTDElementArray) {
                                         if ($btTDElementArray["amountPaid"] > 0) {
                                             $payment = new Payment();
                                             $payment->setPaymentID("");
                                             $payment->setTdID("");
                                             $payment->setDueID($btTDElementArray["dueID"]);
                                             $payment->setDueType($btTDElementArray["dueType"]);
                                             $payment->setBacktaxTDID($backtaxTDID);
                                             $payment->setTaxDue($btTDElementArray["taxDue"]);
                                             $payment->setAdvancedPaymentDiscount($btTDElementArray["advancedPaymentDiscount"]);
                                             $payment->setEarlyPaymentDiscount($btTDElementArray["earlyPaymentDiscount"]);
                                             $payment->setPenalty($btTDElementArray["penalty"]);
//.........这里部分代码省略.........
开发者ID:armic,项目名称:erpts,代码行数:101,代码来源:PaymentReceiptDetails.php


注:本文中的Payment::setPaymentDate方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。