当前位置: 首页>>代码示例>>PHP>>正文


PHP Helper\AbstractHelper类代码示例

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


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

示例1: testUrlDecode

 /**
  * @covers \Magento\Framework\App\Helper\AbstractHelper::urlEncode
  * @covers \Magento\Framework\App\Helper\AbstractHelper::urlDecode
  */
 public function testUrlDecode()
 {
     $data = uniqid();
     $result = $this->helper->urlEncode($data);
     $this->urlBuilderMock->expects($this->once())->method('sessionUrlVar')->with($this->equalTo($data))->will($this->returnValue($result));
     $this->assertNotContains('&', $result);
     $this->assertNotContains('%', $result);
     $this->assertNotContains('+', $result);
     $this->assertNotContains('=', $result);
     $this->assertEquals($result, $this->helper->urlDecode($result));
 }
开发者ID:,项目名称:,代码行数:15,代码来源:

示例2: __construct

 /**
  * Initialize dependencies.
  *
  * @param \Magento\Framework\App\Helper\Context $context
  * @param \Magento\Store\Model\StoreManagerInterface $storeManager,
  * @param \Ves\Brand\Model\ResourceModel\Group\Collection $groupCollection
  */
 public function __construct(\Magento\Framework\App\Helper\Context $context, \Magento\Store\Model\StoreManagerInterface $storeManager, \Ves\Brand\Model\Group $groupCollection, \Magento\Cms\Model\Template\FilterProvider $filterProvider)
 {
     parent::__construct($context);
     $this->_filterProvider = $filterProvider;
     $this->_storeManager = $storeManager;
     $this->_groupCollection = $groupCollection;
 }
开发者ID:vasuscoin,项目名称:brand,代码行数:14,代码来源:Data.php

示例3: __construct

 /**
  * @param \Magento\Framework\App\Helper\Context $context
  * @param \Magento\Eav\Model\Config $eavConfig
  * @param Data $catalogData
  * @param \Magento\Framework\Escaper $escaper
  */
 public function __construct(\Magento\Framework\App\Helper\Context $context, \Magento\Eav\Model\Config $eavConfig, Data $catalogData, \Magento\Framework\Escaper $escaper)
 {
     $this->_eavConfig = $eavConfig;
     $this->_catalogData = $catalogData;
     $this->_escaper = $escaper;
     parent::__construct($context);
 }
开发者ID:pradeep-wagento,项目名称:magento2,代码行数:13,代码来源:Output.php

示例4: __construct

 /**
  * @param Context $context
  * @param \Magento\Braintree\Helper\Data $paymentHelper
  * @param BraintreeCustomer $braintreeCustomerAdapter
  * @param \Magento\Backend\Model\Session\Quote $sessionQuote
  */
 public function __construct(Context $context, \Magento\Braintree\Helper\Data $paymentHelper, BraintreeCustomer $braintreeCustomerAdapter, \Magento\Backend\Model\Session\Quote $sessionQuote)
 {
     parent::__construct($context);
     $this->paymentHelper = $paymentHelper;
     $this->braintreeCustomerAdapter = $braintreeCustomerAdapter;
     $this->sessionQuote = $sessionQuote;
 }
开发者ID:pradeep-wagento,项目名称:magento2,代码行数:13,代码来源:Createorder.php

示例5: __construct

 /**
  * @param \Magento\Framework\App\Helper\Context $context
  * @param \Magento\Framework\Registry $coreRegistry
  * @param \Magento\Framework\ObjectManager\ConfigInterface $config
  */
 public function __construct(\Magento\Framework\App\Helper\Context $context, \Magento\Framework\Registry $coreRegistry, \Magento\Framework\ObjectManager\ConfigInterface $config, \Magento\Backend\App\ConfigInterface $backendConfig)
 {
     $this->_coreRegistry = $coreRegistry;
     $this->_preferences = $config->getPreferences();
     $this->addDevToolData($this->preferencesKey, $this->_preferences);
     parent::__construct($context);
 }
开发者ID:dineshmalekar,项目名称:Magento2-Developer-Debug-Tool,代码行数:12,代码来源:Data.php

示例6: __construct

 /**
  * Constructor
  * gi
  * @param ObjectManagerInterface $objectManager
  * @param Config                 $config
  * @param Context                $context
  */
 public function __construct(ObjectManagerInterface $objectManager, Config $config, Context $context)
 {
     $this->objectManager = $objectManager;
     $this->moduleManager = $context->getModuleManager();
     $this->config = $config;
     return parent::__construct($context);
 }
开发者ID:Doability,项目名称:magento2dev,代码行数:14,代码来源:Data.php

示例7: __construct

 /**
  * @param Context $context
  */
 public function __construct(\Magento\Framework\App\Helper\Context $context, \Magento\Framework\Encryption\EncryptorInterface $encryptor, \Magento\Payment\Model\Config $config, \Magento\Framework\Config\DataInterface $dataStorage)
 {
     parent::__construct($context);
     $this->_encryptor = $encryptor;
     $this->_config = $config;
     $this->_dataStorage = $dataStorage;
 }
开发者ID:pivulic,项目名称:adyen-magento2,代码行数:10,代码来源:Data.php

示例8: __construct

 public function __construct(\Magento\Framework\App\Helper\Context $context, \Magento\Catalog\Model\ResourceModel\Category\CollectionFactory $categoryCollectionFactory, \Magento\Backend\Model\UrlInterface $backendUrl, \Magento\Store\Model\StoreManagerInterface $storeManager)
 {
     parent::__construct($context);
     $this->_backendUrl = $backendUrl;
     $this->_storeManager = $storeManager;
     $this->_categoryCollectionFactory = $categoryCollectionFactory;
 }
开发者ID:mrtuvn,项目名称:m2ce.dev,代码行数:7,代码来源:Data.php

示例9: __construct

 /**
  * @param \Magento\Framework\App\Helper\Context $context
  * @param \Magento\Core\Helper\Data $coreData
  * @param \Magento\Framework\App\Config\ScopeConfigInterface $scopeConfig
  * @param \Magento\Store\Model\StoreManagerInterface $storeManager
  */
 public function __construct(\Magento\Framework\App\Helper\Context $context, \Magento\Core\Helper\Data $coreData, \Magento\Framework\App\Config\ScopeConfigInterface $scopeConfig, \Magento\Store\Model\StoreManagerInterface $storeManager)
 {
     $this->_coreData = $coreData;
     $this->_scopeConfig = $scopeConfig;
     $this->_storeManager = $storeManager;
     parent::__construct($context);
 }
开发者ID:aiesh,项目名称:magento2,代码行数:13,代码来源:Data.php

示例10: __construct

 /**
  * Constructor
  *
  * @param \Magento\Framework\App\Helper\Context $context
  * @param \Magento\Framework\View\DesignInterface $design
  * @param \Magento\Framework\Stdlib\DateTime\TimezoneInterface $localeDate
  * @param \Magento\Framework\View\Result\PageFactory $resultPageFactory
  */
 public function __construct(\Magento\Framework\App\Helper\Context $context, \Magento\Framework\View\DesignInterface $design, \Magento\Framework\Stdlib\DateTime\TimezoneInterface $localeDate, \Magento\Framework\View\Result\PageFactory $resultPageFactory)
 {
     $this->_design = $design;
     $this->_localeDate = $localeDate;
     $this->resultPageFactory = $resultPageFactory;
     parent::__construct($context);
 }
开发者ID:magefan,项目名称:module-blog,代码行数:15,代码来源:Page.php

示例11: __construct

 /**
  * @param \Magento\Framework\App\Helper\Context $context
  * @param \Magento\Store\Model\StoreManagerInterface $storeManager
  * @param \Ebizmarts\MageMonkey\Model\Logger\Magemonkey $logger
  * @param \Magento\Customer\Api\GroupRepositoryInterface $groupRepositoryInterface
  */
 public function __construct(\Magento\Framework\App\Helper\Context $context, \Magento\Store\Model\StoreManagerInterface $storeManager, \Ebizmarts\MageMonkey\Model\Logger\Magemonkey $logger, \Magento\Customer\Api\GroupRepositoryInterface $groupRepositoryInterface)
 {
     $this->_storeManager = $storeManager;
     $this->_mlogger = $logger;
     $this->_groupRepositoryInterface = $groupRepositoryInterface;
     parent::__construct($context);
 }
开发者ID:kost08,项目名称:magento2-magemonkey,代码行数:13,代码来源:Data.php

示例12: __construct

 /**
  * @param \Magento\Framework\App\Helper\Context $context
  * @param \Magento\MediaStorage\Model\File\Storage\DatabaseFactory $dbStorageFactory
  * @param \Magento\MediaStorage\Model\File\Storage\File $fileStorage
  * @param Filesystem $filesystem
  */
 public function __construct(\Magento\Framework\App\Helper\Context $context, \Magento\MediaStorage\Model\File\Storage\DatabaseFactory $dbStorageFactory, \Magento\MediaStorage\Model\File\Storage\File $fileStorage, Filesystem $filesystem)
 {
     $this->_filesystem = $filesystem;
     $this->_dbStorageFactory = $dbStorageFactory;
     $this->_fileStorage = $fileStorage;
     parent::__construct($context);
 }
开发者ID:shabbirvividads,项目名称:magento2,代码行数:13,代码来源:Database.php

示例13: __construct

 /**
  * @param Context $context
  * @param StoreManagerInterface $storeManager
  * @param Filesystem $filesystem
  * @param string $imageDir
  */
 public function __construct(Context $context, StoreManagerInterface $storeManager, Filesystem $filesystem, $imageDir = 'design/image')
 {
     parent::__construct($context);
     $this->storeManager = $storeManager;
     $this->mediaDirectory = $filesystem->getDirectoryWrite(DirectoryList::MEDIA);
     $this->imageDir = $imageDir;
 }
开发者ID:BlackIkeEagle,项目名称:magento2-continuousphp,代码行数:13,代码来源:Config.php

示例14: __construct

 /**
  * @param \Magento\Framework\App\Helper\Context $context
  * @param \Magento\Store\Model\StoreManagerInterface $storeManager
  * @param Filesystem $filesystem
  * @param \Magento\Captcha\Model\CaptchaFactory $factory
  */
 public function __construct(\Magento\Framework\App\Helper\Context $context, \Magento\Store\Model\StoreManagerInterface $storeManager, Filesystem $filesystem, \Magento\Captcha\Model\CaptchaFactory $factory)
 {
     $this->_storeManager = $storeManager;
     $this->_filesystem = $filesystem;
     $this->_factory = $factory;
     parent::__construct($context);
 }
开发者ID:shabbirvividads,项目名称:magento2,代码行数:13,代码来源:Data.php

示例15: __construct

 public function __construct(Context $context, \Magento\Checkout\Model\Session $session, \Magento\Quote\Model\Quote $quote, \Magento\Quote\Model\QuoteManagement $quoteManagement)
 {
     $this->session = $session;
     $this->quote = $quote;
     $this->quoteManagement = $quoteManagement;
     parent::__construct($context);
 }
开发者ID:craigchristenson,项目名称:magento2-2checkout,代码行数:7,代码来源:Checkout.php


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