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


PHP History::write方法代码示例

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


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

示例1: writeHistory

 private function writeHistory($response, $transactionRequest)
 {
     $id_pedido = (int) $this->module->currentOrder;
     $id_transacao = $response->transactionId;
     $id_status = (int) Configuration::get('PS_OS_BCASH_IN_PROGRESS');
     $status = urldecode($response->descriptionStatus);
     $paymentMethodHelper = new PaymentMethodHelper();
     $pagamento_meio = $paymentMethodHelper->getById(Tools::getValue('payment-method'));
     if (PaymentMethodHelper::isCard($pagamento_meio)) {
         $parcelas = Tools::getValue('card-installment');
     } else {
         $parcelas = 1;
     }
     $history = new History($id_pedido, $id_transacao, $id_status, $status, $pagamento_meio->title, $parcelas);
     $history->write();
 }
开发者ID:payu-br,项目名称:bcash-prestashop-transparente,代码行数:16,代码来源:validation.php

示例2: executeCommand

 private function executeCommand()
 {
     if ($pos = strpos(Request::factory()->getCmd(), ' ')) {
         $method = substr(Request::factory()->getCmd(), 0, $pos);
         $args = substr(Request::factory()->getCmd(), $pos + 1);
     } else {
         $method = Request::factory()->getCmd();
         $args = array();
     }
     $command = new Controller_Command();
     if (method_exists($command, $method)) {
         History::write($_SESSION['login'], Request::factory()->getCmd());
         return call_user_func(array($command, $method), $args);
     } else {
         return View::factory('tables/404');
     }
 }
开发者ID:xingcuntian,项目名称:readmin,代码行数:17,代码来源:Index.php

示例3: writeHistory

 private function writeHistory($orderId, $transactionId)
 {
     $email = Configuration::get(self::prefix . 'EMAIL');
     $token = Configuration::get(self::prefix . 'TOKEN');
     $consultation = new Consultation($email, $token);
     $consultation->enableSandBox(Configuration::get(self::prefix . 'SANDBOX'));
     try {
         $response = $consultation->searchByTransaction($transactionId);
         $id_pedido = $response->transacao->id_pedido;
         $id_transacao = $transactionId;
         $id_status = $this->getStatus($response->transacao->cod_status);
         $status = $response->transacao->status;
         $pagamento_meio = $response->transacao->meio_pagamento;
         $parcelas = $response->transacao->parcelas;
         $valor_original = $response->transacao->valor_original;
         $valor_loja = $response->transacao->valor_loja;
         $taxa = $valor_original - $valor_loja;
         $history = new History($id_pedido, $id_transacao, $id_status, $status, $pagamento_meio, $parcelas, $valor_original, $valor_loja, $taxa);
         $history->write();
     } catch (ValidationException $e) {
         $this->logHistoryFail($orderId, $transactionId, $statusId, $e);
     } catch (ConnectionException $e) {
         $this->logHistoryFail($orderId, $transactionId, $statusId, $e);
     }
 }
开发者ID:payu-br,项目名称:bcash-prestashop-transparente,代码行数:25,代码来源:notification.php

示例4: writeNewOrderStatus

 static function writeNewOrderStatus($orderId, $novoStatus)
 {
     $oldHistory = self::getLastByOrder($orderId);
     $history = new History($oldHistory['id_pedido'], $oldHistory['id_transacao'], $novoStatus['id'], $novoStatus['status'], $oldHistory['pagamento_meio'], $oldHistory['parcelas'], $oldHistory['valor_original'], $oldHistory['valor_loja'], $oldHistory['taxa']);
     $history->write();
 }
开发者ID:payu-br,项目名称:bcash-prestashop-transparente,代码行数:6,代码来源:History.php


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