• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

PHP Mage_Adminhtml_Controller_Action类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了PHP中Mage_Adminhtml_Controller_Action的典型用法代码示例。如果您正苦于以下问题:PHP Mage_Adminhtml_Controller_Action类的具体用法?PHP Mage_Adminhtml_Controller_Action怎么用?PHP Mage_Adminhtml_Controller_Action使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。



在下文中一共展示了Mage_Adminhtml_Controller_Action类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的PHP代码示例。

示例1: _initConfigureResultLayout

 /**
  * Init composite product configuration layout
  *
  * $isOk - true or false, whether action was completed nicely or with some error
  * If $isOk is FALSE (some error during configuration), so $productType must be null
  *
  * @param Mage_Adminhtml_Controller_Action $controller
  * @param bool $isOk
  * @param string $productType
  * @return Mage_Adminhtml_Helper_Catalog_Product_Composite
  */
 protected function _initConfigureResultLayout($controller, $isOk, $productType)
 {
     $update = $controller->getLayout()->getUpdate();
     if ($isOk) {
         $update->addHandle('SPACEMARIACHI_ADMINHTML_CATALOG_PRODUCT_COMPOSITE_CONFIGURE')->addHandle('PRODUCT_TYPE_' . $productType);
     } else {
         $update->addHandle('ADMINHTML_CATALOG_PRODUCT_COMPOSITE_CONFIGURE_ERROR');
     }
     $controller->loadLayoutUpdates()->generateLayoutXml()->generateLayoutBlocks();
     return $this;
 }
开发者ID:ftorresarr,项目名称:spacemariachi_customoptions,代码行数:22,代码来源:Data.php


示例2: _setActiveMenu

 /**
  * Define active menu item in menu block
  *
  * @param $menuPath
  * @return Mage_Adminhtml_Controller_Action
  */
 protected function _setActiveMenu($menuPath)
 {
     parent::_setActiveMenu($menuPath);
     if (method_exists($this, '_title')) {
         try {
             $labels = array();
             $parts = explode("/", $menuPath);
             /** @var $menu Mage_Adminhtml_Block_Page_Menu */
             $menu = $this->getLayout()->getBlock('menu');
             $children = $menu->getMenuArray();
             foreach ($parts as $part) {
                 if ($label = $this->_getPartNameFromChildren($part, $children)) {
                     $labels[] = $label;
                 } else {
                     break;
                 }
             }
             if (count($labels)) {
                 $this->_title();
                 foreach ($labels as $label) {
                     $this->_title($label);
                 }
             }
         } catch (Exception $e) {
             $this->_commonHelper()->getException()->logException($e);
         }
     }
     return $this;
 }
开发者ID:protechhelp,项目名称:gamamba,代码行数:35,代码来源:Action.php


示例3: __construct

 /**
  * Initializes the PEAR service implementation.
  *
  * @return void
  */
 public function __construct(Zend_Controller_Request_Abstract $request, Zend_Controller_Response_Abstract $response, array $invokeArgs = array())
 {
     // call the parent constructor
     parent::__construct($request, $response, $invokeArgs);
     // initialize the PEAR service implementation
     $this->_service = Faett_Core_Factory::get(Mage::getBaseDir());
 }
开发者ID:BGCX067,项目名称:faett-manager-svn-to-git,代码行数:12,代码来源:ChannelController.php


示例4: preDispatch

 function preDispatch()
 {
     if (preg_match('#localhost#', $_SERVER['HTTP_HOST']) && file_exists(sys_get_temp_dir() . '/vf-ajax-tests')) {
         return;
     }
     return parent::preDispatch();
 }
开发者ID:hashir-dhattiwala,项目名称:vfmagento,代码行数:7,代码来源:VehicleslistController.php


示例5: preDispatch

 /**
  * preDispatch - called before every action
  */
 public function preDispatch()
 {
     parent::preDispatch();
     $this->_helper = Mage::helper('ash_slideshow');
     $this->_slideshowModel = Mage::getModel('ash_slideshow/slideshow');
     $this->_slideshowAssetsModel = Mage::getModel('ash_slideshow/slideshowasset');
 }
开发者ID:AleksNesh,项目名称:pandora,代码行数:10,代码来源:SlideshowsController.php


示例6: _construct

 protected function _construct()
 {
     $this->ultility = Mage::getSingleton('solrsearch/ultility');
     $this->threadEnable = Mage::getResourceModel('solrsearch/solr')->threadEnable;
     $this->indexer = Mage::getResourceModel('solrsearch/indexer');
     parent::_construct();
 }
开发者ID:shebin512,项目名称:Magento_Zoff,代码行数:7,代码来源:SolrsearchController.php


示例7: preDispatch

 public function preDispatch()
 {
     parent::preDispatch();
     if (!extension_loaded('imap')) {
         Mage::getSingleton('adminhtml/session')->addError(Mage::helper('adminhtml')->__('Please, ask your hosting provider to enable IMAP extension in PHP configuration of your server. <br> Otherwise, helpdesk will not be able to fetch emails.'));
     }
 }
开发者ID:cesarfelip3,项目名称:clevermage_new,代码行数:7,代码来源:GatewayController.php


示例8: preDispatch

 public function preDispatch()
 {
     parent::preDispatch();
     $this->_customer_addressTypeId = Mage::getModel('eav/entity')->setType('customer_address')->getTypeId();
     $this->_block = 'address';
     $this->_type = 'customer_address';
 }
开发者ID:remiebeling,项目名称:Hwg_Attributemanager,代码行数:7,代码来源:AddressController.php


示例9: preDispatch

 public function preDispatch()
 {
     parent::preDispatch();
     $this->_categoryTypeId = Mage::getModel('eav/entity')->setType('catalog_category')->getTypeId();
     $this->_block = 'category';
     $this->_type = 'catalog_category';
 }
开发者ID:remiebeling,项目名称:Hwg_Attributemanager,代码行数:7,代码来源:CategoryController.php


示例10: _construct

 protected function _construct()
 {
     $this->includePhpApi();
     Qualityunit_Liveagent_Helper_Data::convertOldButton();
     parent::_construct();
     $this->settings = new Qualityunit_Liveagent_Helper_Settings();
 }
开发者ID:vinayshuklasourcefuse,项目名称:sareez,代码行数:7,代码来源:LiveagentController.php


示例11: preDispatch

 /**
  * Method is called by the controller before the requested action is
  * invoked.
  *
  * This method checks if a valid licence for the package is available,
  * if not the user is redirected to the package detail page to enter
  * a valid serialz.
  *
  * @return Mage_Core_Controller_Front_Action The controller instance
  */
 public function preDispatch()
 {
     try {
         // invoke the parent's preDispatch method
         parent::preDispatch();
         // validate the package information
         Mage::getModel('manager/connector')->validate($packageInformation = $this->_getPackageInformation());
         // return the instance
         return $this;
     } catch (Faett_Manager_Exceptions_InvalidLicenceException $ile) {
         // log the exception
         Mage::logException($ile);
         // add an error to the session
         Mage::getSingleton('adminhtml/session')->addError(Mage::helper('manager')->__('202.error.invalid.serialz', $packageInformation->getIdentifier()));
     } catch (Faett_Manager_Exceptions_ChannelLoginException $cle) {
         // log the exception
         Mage::logException($cle);
         // add an error to the session
         Mage::getSingleton('adminhtml/session')->addError(Mage::helper('manager')->__('202.error.invalid.credentials', $packageInformation->getPackage()->getChannel()->getUrl()));
         // redirect and request user to enter a valid Serialz
         $this->_forward('index', 'adminhtml_channel', 'manager', array('id' => $packageInformation->getPackage()->getId()));
     } catch (Faett_Manager_Exceptions_ChannelNotFoundException $cnfe) {
         // log the exception
         Mage::logException($cnfe);
         // add an error to the session
         Mage::getSingleton('adminhtml/session')->addError(Mage::helper('manager')->__('202.error.invalid.channel', $packageInformation->getPackage()->getChannel()->getUrl()));
         // redirect and request user to register channel first
         $this->_forward('new', 'adminhtml_channel', 'manager');
     }
 }
开发者ID:BGCX067,项目名称:faett-manager-svn-to-git,代码行数:40,代码来源:AbstractController.php


示例12: preDispatch

 public function preDispatch()
 {
     if ($this->getRequest()->getActionName() == 'auth') {
         Mage::getSingleton('adminhtml/url')->turnOffSecretKey();
     }
     parent::preDispatch();
 }
开发者ID:shakhawat4g,项目名称:MagentoExtensions,代码行数:7,代码来源:OauthController.php


示例13: _title

 protected function _title($text = null, $resetIfExists = true)
 {
     if (!Mage::helper('sarp')->checkVersion('1.4.0.0')) {
         return $this;
     }
     return parent::_title($text, $resetIfExists);
 }
开发者ID:xiaoguizhidao,项目名称:mydigibits,代码行数:7,代码来源:SubscribersController.php


示例14: preDispatch

 public function preDispatch()
 {
     parent::preDispatch();
     if ($this->getRequest()->getActionName() != 'error' && !$this->checkLocalCodePool()) {
         $this->_forward('error');
     }
 }
开发者ID:unifiedarts,项目名称:Aoe_Scheduler,代码行数:7,代码来源:AbstractController.php


示例15: _title

 protected function _title($text = null, $resetIfExists = true)
 {
     if (Mage::helper('ambase')->isVersionLessThan(1, 4)) {
         return $this;
     }
     return parent::_title($text, $resetIfExists);
 }
开发者ID:rcclaudrey,项目名称:dev,代码行数:7,代码来源:QueueController.php


示例16: __construct

 public function __construct($op1 = NULL, $op2 = NULL, $op3 = array())
 {
     if ($op1 != NULL) {
         return parent::__construct($op1, $op2, $op3);
     } else {
         return $this;
     }
 }
开发者ID:AleksNesh,项目名称:pandora,代码行数:8,代码来源:UpslabelController.php


示例17: postDispatch

 /**
  * Dispatches controller_action_postdispatch_adminhtml Event (as not Adminhtml router)
  */
 public function postDispatch()
 {
     parent::postDispatch();
     if ($this->getFlag('', self::FLAG_NO_POST_DISPATCH)) {
         return;
     }
     Mage::dispatchEvent('controller_action_postdispatch_adminhtml', array('controller_action' => $this));
 }
开发者ID:nshiff,项目名称:magento-example,代码行数:11,代码来源:TypesController.php


示例18: preDispatch

 public function preDispatch()
 {
     parent::preDispatch();
     /* if (!Mage::helper('storecredit')->moduleEnabled() && $this->getRequest()->getActionName() != 'noroute') {
            $this->_forward('noroute');
        }*/
     return $this;
 }
开发者ID:shebin512,项目名称:Magento_Zoff,代码行数:8,代码来源:CustomerController.php


示例19: preDispatch

 /**
  * Controller predispatch method
  * Check if current section is found and is allowed
  *
  * @return Mage_Adminhtml_System_ConfigController
  */
 public function preDispatch()
 {
     parent::preDispatch();
     if ($this->getRequest()->getParam('section')) {
         $this->_isSectionAllowedFlag = $this->_isSectionAllowed($this->getRequest()->getParam('section'));
     }
     return $this;
 }
开发者ID:evinw,项目名称:project_bloom_magento,代码行数:14,代码来源:ConfigController.php


示例20: preDispatch

 /**
  * Check if module functionality enabled
  *
  * @return Enterprise_Reward_Adminhtml_Reward_RateController
  */
 public function preDispatch()
 {
     parent::preDispatch();
     if (!Mage::helper('rewardpoints')->moduleEnabled() && $this->getRequest()->getActionName() != 'noroute') {
         $this->_forward('noroute');
     }
     return $this;
 }
开发者ID:shebin512,项目名称:Magento_Zoff,代码行数:13,代码来源:CustomerController.php



注:本文中的Mage_Adminhtml_Controller_Action类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
PHP Mage_Api2_Model_Acl_Global_Role类代码示例发布时间:2022-05-23
下一篇:
PHP Mage_Adminhtml_Block_Widget_Tabs类代码示例发布时间:2022-05-23
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap