當前位置: 首頁>>代碼示例>>PHP>>正文


PHP DataObject::getAdditionalData方法代碼示例

本文整理匯總了PHP中Magento\Framework\DataObject::getAdditionalData方法的典型用法代碼示例。如果您正苦於以下問題:PHP DataObject::getAdditionalData方法的具體用法?PHP DataObject::getAdditionalData怎麽用?PHP DataObject::getAdditionalData使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在Magento\Framework\DataObject的用法示例。


在下文中一共展示了DataObject::getAdditionalData方法的3個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: assignData

 public function assignData(DataObject $data)
 {
     $additional_data = new DataObject($data->getAdditionalData());
     $info_instance = $this->getInfoInstance();
     $info_instance->setAdditionalInformation('ticket', $additional_data->getData('ticket_response_ticket'));
     $info_instance->setAdditionalInformation('hmac', $additional_data->getData('ticket_response_monetra_resp_hmacsha256'));
     $info_instance->setAdditionalInformation('sequence', $additional_data->getData('ticket_request_sequence'));
     $info_instance->setAdditionalInformation('timestamp', $additional_data->getData('ticket_request_timestamp'));
     return $this;
 }
開發者ID:monetra,項目名稱:monetra_magento2,代碼行數:10,代碼來源:ClientTicket.php

示例2: assignData

 /**
  * Assign corresponding data
  *
  * @param \Magento\Framework\DataObject|mixed $data
  * @return $this
  * @throws LocalizedException
  */
 public function assignData(\Magento\Framework\DataObject $data)
 {
     $additionalData = $data->getAdditionalData();
     if (!is_array($data->getAdditionalData())) {
         return $this;
     }
     $additionalData = new DataObject($additionalData);
     $infoInstance = $this->getInfoInstance();
     $infoInstance->setAdditionalInformation('payment_method_nonce', $additionalData->getData('payment_method_nonce'));
     return $this;
 }
開發者ID:pradeep-wagento,項目名稱:magento2,代碼行數:18,代碼來源:PayPal.php

示例3: assignData

 /**
  * Assign corresponding data
  *
  * @param \Magento\Framework\DataObject|mixed $data
  * @return $this
  * @throws LocalizedException
  */
 public function assignData(\Magento\Framework\DataObject $data)
 {
     $additionalData = $data->getAdditionalData();
     if (!is_array($data->getAdditionalData())) {
         return $this;
     }
     $additionalData = new DataObject($additionalData);
     $infoInstance = $this->getInfoInstance();
     if ($this->getConfigData('fraudprotection') > 0) {
         $infoInstance->setAdditionalInformation('device_data', $additionalData->getData('device_data'));
     }
     $infoInstance->setAdditionalInformation('cc_last4', $additionalData->getData('cc_last4'));
     $infoInstance->setAdditionalInformation('cc_token', $additionalData->getData('cc_token'));
     $infoInstance->setAdditionalInformation('payment_method_nonce', $additionalData->getData('payment_method_nonce'));
     $infoInstance->setCcLast4($additionalData->getData('cc_last4'));
     $infoInstance->setCcType($additionalData->getData('cc_type'));
     $infoInstance->setCcExpMonth($additionalData->getData('cc_exp_month'));
     $infoInstance->setCcExpYear($additionalData->getData('cc_exp_year'));
     return $this;
 }
開發者ID:pradeep-wagento,項目名稱:magento2,代碼行數:27,代碼來源:PaymentMethod.php


注:本文中的Magento\Framework\DataObject::getAdditionalData方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。