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


PHP Mage_Sales_Model_Order::queueNewOrderEmail方法代码示例

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


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

示例1: queueNewOrderEmail

 /**
  * Queue email with new order data
  *
  * @param bool $forceMode if true then email will be sent regardless of the fact that it was already sent previously
  *
  * @return Mage_Sales_Model_Order
  * @throws Exception
  */
 public function queueNewOrderEmail($forceMode = false)
 {
     if (Mage::helper('customweb_subscription/cart')->isOrderSubscription($this) || Mage::registry('customweb_subscription_recurring_order') === true) {
         $this->sendNewSubscriptionOrderEmail();
     } else {
         parent::queueNewOrderEmail($forceMode);
     }
 }
开发者ID:xiaoguizhidao,项目名称:extensiongsd,代码行数:16,代码来源:Order.php

示例2: _registerPaymentAuthorization

 /**
  * Register authorized payment
  */
 protected function _registerPaymentAuthorization()
 {
     $this->_importPaymentInformation();
     $this->_order->getPayment()->setPreparedMessage($this->_createIpnComment(''))->setTransactionId($this->getRequestData('txn_id'))->setParentTransactionId($this->getRequestData('parent_txn_id'))->setCurrencyCode($this->getRequestData('mc_currency'))->setIsTransactionClosed(0)->registerAuthorizationNotification($this->getRequestData('mc_gross'));
     if (!$this->_order->getEmailSent()) {
         $this->_order->queueNewOrderEmail();
     }
     $this->_order->save();
 }
开发者ID:quyip8818,项目名称:Mag,代码行数:12,代码来源:Ipn.php

示例3: paymentSaleCompleted

 /**
  * Mark transaction as completed
  *
  * @param \PayPal\Api\WebhookEvent $webhookEvent
  */
 protected function paymentSaleCompleted(\PayPal\Api\WebhookEvent $webhookEvent)
 {
     $paymentResource = $webhookEvent->getResource();
     $parentTransactionId = $paymentResource->parent_payment;
     $payment = $this->_order->getPayment();
     $payment->setTransactionId($paymentResource->id)->setCurrencyCode($paymentResource->amount->currency)->setParentTransactionId($parentTransactionId)->setIsTransactionClosed(true)->registerCaptureNotification($paymentResource->amount->total, true);
     $this->_order->save();
     // notify customer
     $invoice = $payment->getCreatedInvoice();
     if ($invoice && !$this->_order->getEmailSent()) {
         $this->_order->queueNewOrderEmail()->addStatusHistoryComment(Mage::helper('iways_paypalplus')->__('Notified customer about invoice #%s.', $invoice->getIncrementId()))->setIsCustomerNotified(true)->save();
     }
 }
开发者ID:sickdaflip,项目名称:Iways_PayPalPlus-1.4.5,代码行数:18,代码来源:Event.php

示例4: queueNewOrderEmail

 public function queueNewOrderEmail($forceMode = false)
 {
     $isDelete = false;
     if (!Mage::registry('ait_send_order_email')) {
         Mage::register('ait_send_order_email', 1);
         // aitoc code
         $isDelete = true;
     }
     $oResult = parent::queueNewOrderEmail($forceMode);
     if ($isDelete) {
         Mage::unregister('ait_send_order_email');
         // aitoc code
     }
     return $oResult;
 }
开发者ID:kiutisuperking,项目名称:eatsmartboxdev,代码行数:15,代码来源:FrontSalesOrder.php

示例5: _processSale

 /**
  * Processes payment confirmation, creates invoice if necessary, updates order status,
  * sends order confirmation to customer
  *
  * @param string $status
  * @param string $msg Order history message
  */
 protected function _processSale($status, $msg)
 {
     switch ($status) {
         case self::MONEYBOOKERS_STATUS_SUCCESS:
             $this->_createInvoice();
             $this->_order->setState(Mage_Sales_Model_Order::STATE_PROCESSING, true, $msg);
             // save transaction ID
             $this->_order->getPayment()->setLastTransId($this->getEventData('mb_transaction_id'));
             // send new order email
             $this->_order->queueNewOrderEmail();
             $this->_order->setEmailSent(true);
             break;
         case self::MONEYBOOKERS_STATUS_PENDING:
             $this->_order->setState(Mage_Sales_Model_Order::STATE_PENDING_PAYMENT, true, $msg);
             // save transaction ID
             $this->_order->getPayment()->setLastTransId($this->getEventData('mb_transaction_id'));
             break;
     }
     $this->_order->save();
 }
开发者ID:chucky515,项目名称:Magento-CE-Mirror,代码行数:27,代码来源:Event.php

示例6: _processOrder

 /**
  * Operate with order using information from silent post
  *
  * @param Mage_Sales_Model_Order $order
  */
 protected function _processOrder(Mage_Sales_Model_Order $order)
 {
     $response = $this->getResponse();
     $payment = $order->getPayment();
     $payment->setTransactionId($response->getPnref())->setIsTransactionClosed(0);
     $canSendNewOrderEmail = true;
     if ($response->getResult() == self::RESPONSE_CODE_FRAUDSERVICE_FILTER || $response->getResult() == self::RESPONSE_CODE_DECLINED_BY_FILTER) {
         $canSendNewOrderEmail = false;
         $fraudMessage = $this->_getFraudMessage() ? $response->getFraudMessage() : $response->getRespmsg();
         $payment->setIsTransactionPending(true)->setIsFraudDetected(true)->setAdditionalInformation('paypal_fraud_filters', $fraudMessage);
     }
     if ($response->getAvsdata() && strstr(substr($response->getAvsdata(), 0, 2), 'N')) {
         $payment->setAdditionalInformation('paypal_avs_code', substr($response->getAvsdata(), 0, 2));
     }
     if ($response->getCvv2match() && $response->getCvv2match() != 'Y') {
         $payment->setAdditionalInformation('paypal_cvv2_match', $response->getCvv2match());
     }
     switch ($response->getType()) {
         case self::TRXTYPE_AUTH_ONLY:
             $payment->registerAuthorizationNotification($payment->getBaseAmountAuthorized());
             break;
         case self::TRXTYPE_SALE:
             $payment->registerCaptureNotification($payment->getBaseAmountAuthorized());
             break;
     }
     $order->save();
     try {
         if ($canSendNewOrderEmail) {
             $order->queueNewOrderEmail();
         }
         Mage::getModel('sales/quote')->load($order->getQuoteId())->setIsActive(false)->save();
     } catch (Exception $e) {
         Mage::throwException(Mage::helper('paypal')->__('Can not send new order email.'));
     }
 }
开发者ID:xiaoguizhidao,项目名称:blingjewelry-prod,代码行数:40,代码来源:Payflowlink.php

示例7: _queueNewOrderEmail

 /**
  * If a new email can be sent for the order, queue it to be sent.
  *
  * @param Mage_Sales_Model_Order
  * @return self
  */
 protected function _queueNewOrderEmail(Mage_Sales_Model_Order $order)
 {
     if ($order->getCanSendNewEmailFlag()) {
         try {
             $order->queueNewOrderEmail();
         } catch (Exception $e) {
             $this->_logger->warning('Unable to queue new order email.', $this->_logContext->getMetaData(__CLASS__, [], $e));
         }
     }
     return $this;
 }
开发者ID:WinstonN,项目名称:magento-retail-order-management,代码行数:17,代码来源:Multishipping.php


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