public function checkUserEditPermissions($type, $model, $block = null, $params = array()) { if (parent::checkUserEditPermissions($type, $model, $block, $params)) { return Mage::getSingleton('admin/session')->isAllowed('catalog/products'); } return false; }
public function checkUserEditPermissions($type, $model, $block = null, $params = array()) { if (parent::checkUserEditPermissions($type, $model, $block, $params)) { return Mage::getSingleton('admin/session')->isAllowed('sales/checkoutagreement'); } return false; }
public function checkUserEditPermissions($type) { if (parent::checkUserEditPermissions($type)) { return Mage::getSingleton('admin/session')->isAllowed('cms/page/save'); } return false; }
/** * Return whether the current user has edit permissions over the grid * * @return bool */ public function hasUserEditPermissions() { if (!is_null($this->_typeModel)) { return $this->_typeModel->checkUserEditPermissions($this->getGridType()); } return false; }
public function checkUserEditPermissions($type, $model, $block = null, $params = array()) { if (parent::checkUserEditPermissions($type, $model, $block, $params)) { if (Mage::registry('use_pending_filter') === true || isset($params['additional']['use_pending_filter'])) { return Mage::getSingleton('admin/session')->isAllowed('catalog/reviews_ratings/reviews/pending'); } else { return Mage::getSingleton('admin/session')->isAllowed('catalog/reviews_ratings/reviews/all'); } } return false; }
public function checkUserEditPermissions($type, $model, $block = null, $params = array()) { if (parent::checkUserEditPermissions($type, $model, $block, $params)) { if (!is_null($block)) { $classType = $block->getClassType(); } elseif (isset($params['additional']['class_type'])) { $classType = $params['additional']['class_type']; } else { $classType = null; } switch ($classType) { case Mage_Tax_Model_Class::TAX_CLASS_TYPE_CUSTOMER: return Mage::getSingleton('admin/session')->isAllowed('sales/tax/classes_customer'); case Mage_Tax_Model_Class::TAX_CLASS_TYPE_PRODUCT: return Mage::getSingleton('admin/session')->isAllowed('sales/tax/classes_product'); } } return false; }
/** * Return whether the current user has edit permissions over the grid * * @param Mage_Adminhtml_Block_Widget_Grid $grid Grid block instance * @return bool */ public function hasUserEditPermissions($grid) { if (!is_null($this->_typeModel)) { return $this->_typeModel->checkUserEditPermissions($this->getBlockType(), $this, $grid); } else { return $this->checkUserActionPermission(self::GRID_ACTION_EDIT_COLUMNS_VALUES); } return false; }