protected function addRemoveFromAllTemplates($eventType)
    {
        // Check current user authorization
        if (null !== $response = $this->checkAuth($this->resourceCode, array(), AccessManager::UPDATE)) {
            return $response;
        }

        try {
            if (null !== $object = $this->getExistingObject()) {
                $event = new FeatureEvent($object);

                $this->dispatch($eventType, $event);
            }
        } catch (\Exception $ex) {
            // Any error
            return $this->errorPage($ex);
        }

        return $this->redirectToListTemplate();
    }
protected function addRemoveFromAllTemplates($eventType)
    {
        // Check current user authorization
        if (null !== $response = $this->checkAuth($this->resourceCode, array(), AccessManager::UPDATE)) {
            return $response;
        }

        try {
            if (null !== $object = $this->getExistingObject()) {
                $event = new FeatureEvent($object);

                $this->dispatch($eventType, $event);
            }
        } catch (\Exception $ex) {
            // Any error
            return $this->errorPage($ex);
        }

        return $this->redirectToListTemplate();
    }
protected function addRemoveFromAllTemplates ( $ eventType ) { // Check current user authorization if ( null !== $ response = $ this -> checkAuth ( $ this -> resourceCode , array ( ) , AccessManager :: UPDATE ) ) { return $ response ; } try { if ( null !== $ object = $ this -> getExistingObject ( ) ) { $ event = new FeatureEvent ( $ object ) ; $ this -> dispatch ( $ eventType , $ event ) ; } } catch ( \ Exception $ ex ) { // Any error return $ this -> errorPage ( $ ex ) ; } return $ this -> redirectToListTemplate ( ) ; }
Add or Remove from all product templates
Add or Remove from all product templates