Exemplo n.º 1
0
 /**
  * {@inheritdoc}
  */
 public function isScopeGlobal()
 {
     $pluginInfo = $this->pluginList->getNext($this->subjectType, 'isScopeGlobal');
     if (!$pluginInfo) {
         return parent::isScopeGlobal();
     } else {
         return $this->___callPlugins('isScopeGlobal', func_get_args(), $pluginInfo);
     }
 }
 /**
  * Retrieve label of attribute scope
  *
  * GLOBAL | WEBSITE | STORE
  *
  * @param EavAttribute $attribute
  * @return string
  */
 public function getScopeLabel(EavAttribute $attribute)
 {
     $html = '';
     if (!$attribute || $this->storeManager->isSingleStoreMode() || $attribute->getFrontendInput() === AttributeInterface::FRONTEND_INPUT) {
         return $html;
     }
     if ($attribute->isScopeGlobal()) {
         $html .= __('[GLOBAL]');
     } elseif ($attribute->isScopeWebsite()) {
         $html .= __('[WEBSITE]');
     } elseif ($attribute->isScopeStore()) {
         $html .= __('[STORE VIEW]');
     }
     return $html;
 }