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


PHP AbstractElement::__construct方法代码示例

本文整理汇总了PHP中Magento\Framework\Data\Form\Element\AbstractElement::__construct方法的典型用法代码示例。如果您正苦于以下问题:PHP AbstractElement::__construct方法的具体用法?PHP AbstractElement::__construct怎么用?PHP AbstractElement::__construct使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Magento\Framework\Data\Form\Element\AbstractElement的用法示例。


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

示例1: __construct

 /**
  * @param \Magento\Framework\Data\Form\Element\Factory $factoryElement
  * @param \Magento\Framework\Data\Form\Element\CollectionFactory $factoryCollection
  * @param \Magento\Framework\Escaper $escaper
  * @param \Magento\Backend\Helper\Data $adminhtmlData
  * @param \Magento\Framework\View\Asset\Repository $assetRepo
  * @param array $data
  */
 public function __construct(\Magento\Framework\Data\Form\Element\Factory $factoryElement, \Magento\Framework\Data\Form\Element\CollectionFactory $factoryCollection, \Magento\Framework\Escaper $escaper, \Magento\Backend\Helper\Data $adminhtmlData, \Magento\Framework\View\Asset\Repository $assetRepo, $data = array())
 {
     $this->_adminhtmlData = $adminhtmlData;
     $this->_assetRepo = $assetRepo;
     parent::__construct($factoryElement, $factoryCollection, $escaper, $data);
     $this->setType('file');
 }
开发者ID:aiesh,项目名称:magento2,代码行数:15,代码来源:File.php

示例2: __construct

 /**
  * @param Factory $factoryElement
  * @param CollectionFactory $factoryCollection
  * @param Escaper $escaper
  * @param array $data
  */
 public function __construct(Factory $factoryElement, CollectionFactory $factoryCollection, Escaper $escaper, $data = array())
 {
     parent::__construct($factoryElement, $factoryCollection, $escaper, $data);
     $this->setType('select');
     $this->setExtType('multiple');
     $this->setSize(10);
 }
开发者ID:,项目名称:,代码行数:13,代码来源:

示例3: __construct

 /**
  * @param Factory $factoryElement
  * @param CollectionFactory $factoryCollection
  * @param Escaper $escaper
  * @param array $data
  */
 public function __construct(Factory $factoryElement, CollectionFactory $factoryCollection, Escaper $escaper, $data = [])
 {
     parent::__construct($factoryElement, $factoryCollection, $escaper, $data);
     $this->setType('select');
     $this->setExtType('combobox');
     $this->_prepareOptions();
 }
开发者ID:shabbirvividads,项目名称:magento2,代码行数:13,代码来源:Select.php

示例4: __construct

 /**
  * @param \Magento\Framework\Data\Form\Element\Factory $factoryElement
  * @param \Magento\Framework\Data\Form\Element\CollectionFactory $factoryCollection
  * @param \Magento\Framework\Escaper $escaper
  * @param array $data
  */
 public function __construct(\Magento\Framework\Data\Form\Element\Factory $factoryElement, \Magento\Framework\Data\Form\Element\CollectionFactory $factoryCollection, \Magento\Framework\Escaper $escaper, $data = [])
 {
     parent::__construct($factoryElement, $factoryCollection, $escaper, $data);
     $this->setType('file');
     $this->setExtType('imagefile');
     $this->setAutosubmit(false);
     $this->setData('autoSubmit', false);
 }
开发者ID:kidaa30,项目名称:magento2-platformsh,代码行数:14,代码来源:Imagefile.php

示例5: __construct

 /**
  * @param \Magento\Framework\Data\Form\Element\Factory $factoryElement
  * @param \Magento\Framework\Data\Form\Element\CollectionFactory $factoryCollection
  * @param \Magento\Framework\Escaper $escaper
  * @param \Magento\Framework\View\Asset\Repository $assetRepo
  * @param \Magento\Backend\Model\UrlFactory $backendUrlFactory
  * @param \Magento\Catalog\Helper\Data $catalogData
  * @param \Magento\Framework\File\Size $fileConfig
  * @param array $data
  */
 public function __construct(\Magento\Framework\Data\Form\Element\Factory $factoryElement, \Magento\Framework\Data\Form\Element\CollectionFactory $factoryCollection, \Magento\Framework\Escaper $escaper, \Magento\Framework\View\Asset\Repository $assetRepo, \Magento\Backend\Model\UrlFactory $backendUrlFactory, \Magento\Catalog\Helper\Data $catalogData, \Magento\Framework\File\Size $fileConfig, array $data = array())
 {
     parent::__construct($factoryElement, $factoryCollection, $escaper, $data);
     $this->_assetRepo = $assetRepo;
     $this->_url = $backendUrlFactory->create();
     $this->_catalogHelperData = $catalogData;
     $this->_fileConfig = $fileConfig;
     $this->_maxFileSize = $this->_getFileMaxSize();
 }
开发者ID:aiesh,项目名称:magento2,代码行数:19,代码来源:BaseImage.php

示例6: __construct

 /**
  * @param Factory $factoryElement
  * @param CollectionFactory $factoryCollection
  * @param Escaper $escaper
  * @param array $data
  */
 public function __construct(Factory $factoryElement, CollectionFactory $factoryCollection, Escaper $escaper, $data = [])
 {
     parent::__construct($factoryElement, $factoryCollection, $escaper, $data);
     $this->_renderer = Form::getFieldsetRenderer();
     $this->setType('fieldset');
     if (isset($data['advancedSection'])) {
         $this->setAdvancedLabel($data['advancedSection']);
     }
 }
开发者ID:IlyaGluschenko,项目名称:protection,代码行数:15,代码来源:Fieldset.php

示例7: __construct

 /**
  * @param Factory $factoryElement
  * @param CollectionFactory $factoryCollection
  * @param Escaper $escaper
  * @param TimezoneInterface $localeDate
  * @param array $data
  */
 public function __construct(Factory $factoryElement, CollectionFactory $factoryCollection, Escaper $escaper, TimezoneInterface $localeDate, $data = [])
 {
     $this->localeDate = $localeDate;
     parent::__construct($factoryElement, $factoryCollection, $escaper, $data);
     $this->setType('text');
     $this->setExtType('textfield');
     if (isset($data['value'])) {
         $this->setValue($data['value']);
     }
 }
开发者ID:IlyaGluschenko,项目名称:test001,代码行数:17,代码来源:Date.php

示例8: __construct

 /**
  * @param Factory $factoryElement
  * @param CollectionFactory $factoryCollection
  * @param Escaper $escaper
  * @param array $data
  */
 public function __construct(Factory $factoryElement, CollectionFactory $factoryCollection, Escaper $escaper, $data = [])
 {
     parent::__construct($factoryElement, $factoryCollection, $escaper, $data);
     $this->setType('textarea');
     $this->setExtType('textarea');
     if (!$this->getRows()) {
         $this->setRows(self::DEFAULT_ROWS);
     }
     if (!$this->getCols()) {
         $this->setCols(self::DEFAULT_COLS);
     }
 }
开发者ID:nja78,项目名称:magento2,代码行数:18,代码来源:Textarea.php

示例9: __construct

 /**
  * @param \Magento\Framework\Data\Form\Element\Factory $factoryElement
  * @param \Magento\Framework\Data\Form\Element\CollectionFactory $factoryCollection
  * @param \Magento\Framework\Escaper $escaper
  * @param \Magento\Store\Model\StoreManagerInterface $storeManager
  * @param \Magento\Framework\Locale\CurrencyInterface $localeCurrency
  * @param array $data
  */
 public function __construct(\Magento\Framework\Data\Form\Element\Factory $factoryElement, \Magento\Framework\Data\Form\Element\CollectionFactory $factoryCollection, \Magento\Framework\Escaper $escaper, \Magento\Store\Model\StoreManagerInterface $storeManager, \Magento\Framework\Locale\CurrencyInterface $localeCurrency, array $data = [])
 {
     $this->localeCurrency = $localeCurrency;
     $this->storeManager = $storeManager;
     parent::__construct($factoryElement, $factoryCollection, $escaper, $data);
 }
开发者ID:IlyaGluschenko,项目名称:protection,代码行数:14,代码来源:Tax.php

示例10: __construct

 /**
  * @param \Magento\Framework\Data\Form\Element\Factory $factoryElement
  * @param \Magento\Framework\Data\Form\Element\CollectionFactory $factoryCollection
  * @param \Magento\Framework\Escaper $escaper
  * @param UrlInterface $urlBuilder
  * @param array $data
  */
 public function __construct(\Magento\Framework\Data\Form\Element\Factory $factoryElement, \Magento\Framework\Data\Form\Element\CollectionFactory $factoryCollection, \Magento\Framework\Escaper $escaper, UrlInterface $urlBuilder, $data = [])
 {
     $this->_urlBuilder = $urlBuilder;
     parent::__construct($factoryElement, $factoryCollection, $escaper, $data);
     $this->setType('file');
 }
开发者ID:IlyaGluschenko,项目名称:test001,代码行数:13,代码来源:Image.php

示例11: __construct

 /**
  * @param Factory $factoryElement
  * @param CollectionFactory $factoryCollection
  * @param Escaper $escaper
  * @param array $data
  */
 public function __construct(Factory $factoryElement, CollectionFactory $factoryCollection, Escaper $escaper, $data = [])
 {
     parent::__construct($factoryElement, $factoryCollection, $escaper, $data);
     $this->setType('text');
     $this->setLineCount(2);
 }
开发者ID:pradeep-wagento,项目名称:magento2,代码行数:12,代码来源:Multiline.php

示例12: __construct

 /**
  * @param \Magento\Framework\Data\Form\Element\Factory $factoryElement
  * @param \Magento\Framework\Data\Form\Element\CollectionFactory $factoryCollection
  * @param \Magento\Framework\Escaper $escaper
  * @param \Magento\Catalog\Helper\Product $helper
  * @param \Magento\Framework\Locale\Format $localeFormat
  * @param array $data
  */
 public function __construct(\Magento\Framework\Data\Form\Element\Factory $factoryElement, \Magento\Framework\Data\Form\Element\CollectionFactory $factoryCollection, \Magento\Framework\Escaper $escaper, \Magento\Framework\Locale\Format $localeFormat, array $data = [])
 {
     $this->localeFormat = $localeFormat;
     parent::__construct($factoryElement, $factoryCollection, $escaper, $data);
 }
开发者ID:nja78,项目名称:magento2,代码行数:13,代码来源:Tax.php

示例13: __construct

 public function __construct(\Magento\Framework\View\LayoutInterface $layout, Factory $factoryElement, CollectionFactory $factoryCollection, Escaper $escaper, array $data = [])
 {
     $this->layout = $layout;
     $this->setType('hidden');
     parent::__construct($factoryElement, $factoryCollection, $escaper, $data);
 }
开发者ID:Doability,项目名称:magento2dev,代码行数:6,代码来源:Messages.php

示例14: __construct

 /**
  * @param \Magento\Framework\Data\Form\Element\Factory $factoryElement
  * @param \Magento\Framework\Data\Form\Element\CollectionFactory $factoryCollection
  * @param Escaper $escaper
  * @param array $data
  */
 public function __construct(\Magento\Framework\Data\Form\Element\Factory $factoryElement, \Magento\Framework\Data\Form\Element\CollectionFactory $factoryCollection, Escaper $escaper, $data = [])
 {
     parent::__construct($factoryElement, $factoryCollection, $escaper, $data);
     $this->setType('custom_container');
 }
开发者ID:Doability,项目名称:magento2dev,代码行数:11,代码来源:CustomContainer.php

示例15: __construct

 /**
  * @param \Magento\Framework\Data\Form\Element\Factory $factoryElement
  * @param \Magento\Framework\Data\Form\Element\CollectionFactory $factoryCollection
  * @param \Magento\Framework\Escaper $escaper
  * @param \Magento\Framework\View\LayoutInterface $layout
  * @param \Magento\Store\Model\StoreManagerInterface $storeManager
  * @param array $data
  */
 public function __construct(\Magento\Framework\Data\Form\Element\Factory $factoryElement, \Magento\Framework\Data\Form\Element\CollectionFactory $factoryCollection, \Magento\Framework\Escaper $escaper, \Magento\Framework\View\LayoutInterface $layout, \Magento\Store\Model\StoreManagerInterface $storeManager, $data = array())
 {
     $this->_layout = $layout;
     $this->_storeManager = $storeManager;
     parent::__construct($factoryElement, $factoryCollection, $escaper, $data);
 }
开发者ID:aiesh,项目名称:magento2,代码行数:14,代码来源:Gallery.php


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