Esempio n. 1
0
 /**
  * @param Payment $payment
  * @return \Magento\Sales\Api\Data\OrderPaymentExtensionInterface
  */
 private function getPaymentExtensionAttributes(Payment $payment)
 {
     $extensionAttributes = $payment->getExtensionAttributes();
     if ($extensionAttributes === null) {
         $extensionAttributes = $this->paymentExtensionFactory->create();
         $payment->setExtensionAttributes($extensionAttributes);
     }
     return $extensionAttributes;
 }
 /**
  * {@inheritdoc}
  */
 public function setExtensionAttributes(\Magento\Sales\Api\Data\OrderPaymentExtensionInterface $extensionAttributes)
 {
     $pluginInfo = $this->pluginList->getNext($this->subjectType, 'setExtensionAttributes');
     if (!$pluginInfo) {
         return parent::setExtensionAttributes($extensionAttributes);
     } else {
         return $this->___callPlugins('setExtensionAttributes', func_get_args(), $pluginInfo);
     }
 }