Ejemplo n.º 1
0
 /**
  * {@inheritdoc}
  */
 public function deleteById($attributeId)
 {
     /** @var \Magento\Eav\Model\Entity\Attribute $attribute */
     $attribute = $this->attributeFactory->create();
     $this->eavResource->load($attribute, $attributeId);
     if (!$attribute->getAttributeId()) {
         throw new NoSuchEntityException(__('Attribute with id "%1" does not exist.', $attributeId));
     }
     $this->delete($attribute);
     return true;
 }
Ejemplo n.º 2
0
 /**
  * {@inheritdoc}
  */
 public function load(\Magento\Framework\Model\AbstractModel $object, $value, $field = null)
 {
     $pluginInfo = $this->pluginList->getNext($this->subjectType, 'load');
     if (!$pluginInfo) {
         return parent::load($object, $value, $field);
     } else {
         return $this->___callPlugins('load', func_get_args(), $pluginInfo);
     }
 }