本文整理匯總了PHP中Magento\Backend\Block\Widget\Form\Container::__construct方法的典型用法代碼示例。如果您正苦於以下問題:PHP Container::__construct方法的具體用法?PHP Container::__construct怎麽用?PHP Container::__construct使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類Magento\Backend\Block\Widget\Form\Container
的用法示例。
在下文中一共展示了Container::__construct方法的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: __construct
/**
* @param \Magento\Backend\Block\Widget\Context $context
* @param \Magento\Framework\Registry $registry
* @param \Magento\Sales\Model\Config $salesConfig
* @param \Magento\Sales\Helper\Reorder $reorderHelper
* @param array $data
*/
public function __construct(\Magento\Backend\Block\Widget\Context $context, \Magento\Framework\Registry $registry, \Magento\Sales\Model\Config $salesConfig, \Magento\Sales\Helper\Reorder $reorderHelper, array $data = [])
{
$this->_reorderHelper = $reorderHelper;
$this->_coreRegistry = $registry;
$this->_salesConfig = $salesConfig;
parent::__construct($context, $data);
}
示例2: __construct
/**
* Constructor
*
* @param \Magento\Backend\Block\Widget\Context $context
* @param \Magento\Framework\Registry $registry
* @param GroupRepositoryInterface $groupRepository
* @param GroupManagementInterface $groupManagement
* @param array $data
*/
public function __construct(\Magento\Backend\Block\Widget\Context $context, \Magento\Framework\Registry $registry, GroupRepositoryInterface $groupRepository, GroupManagementInterface $groupManagement, array $data = [])
{
$this->coreRegistry = $registry;
$this->groupRepository = $groupRepository;
$this->groupManagement = $groupManagement;
parent::__construct($context, $data);
}
示例3: __construct
/**
* Constructor
*
* @param \Magento\Backend\Block\Widget\Context $context Current context
* @param \Magento\Framework\Registry $registry The registry
* @param array $data Block parameters
*/
public function __construct(\Magento\Backend\Block\Widget\Context $context, \Magento\Framework\Registry $registry, array $data = [])
{
$this->coreRegistry = $registry;
$this->_mode = "create";
parent::__construct($context, $data);
$this->setFormActionUrl($this->getUrl('*/*/create'));
}
示例4: __construct
/**
* @param \Magento\Backend\Block\Widget\Context $context
* @param \Magento\Review\Model\ReviewFactory $reviewFactory
* @param \Magento\Review\Helper\Action\Pager $reviewActionPager
* @param \Magento\Framework\Registry $registry
* @param array $data
*/
public function __construct(\Magento\Backend\Block\Widget\Context $context, \Magento\Review\Model\ReviewFactory $reviewFactory, \Magento\Review\Helper\Action\Pager $reviewActionPager, \Magento\Framework\Registry $registry, array $data = [])
{
$this->_coreRegistry = $registry;
$this->_reviewActionPager = $reviewActionPager;
$this->_reviewFactory = $reviewFactory;
parent::__construct($context, $data);
}
示例5: __construct
/**
* Constructor
*
* @param \Magento\Backend\Block\Widget\Context $context
* @param \Magento\Framework\Registry $registry
* @param CustomerAccountServiceInterface $customerAccountService
* @param \Magento\Customer\Helper\View $viewHelper
* @param array $data
*/
public function __construct(\Magento\Backend\Block\Widget\Context $context, \Magento\Framework\Registry $registry, CustomerAccountServiceInterface $customerAccountService, \Magento\Customer\Helper\View $viewHelper, array $data = array())
{
$this->_coreRegistry = $registry;
$this->_customerAccountService = $customerAccountService;
$this->_viewHelper = $viewHelper;
parent::__construct($context, $data);
}
示例6: __construct
/**
* constructor
*
* @param Registry $registry
* @param FormConfig $formConfig
* @param Entity $entity
* @param Attribute $attribute
* @param Context $context
* @param array $data
*/
public function __construct(Registry $registry, FormConfig $formConfig, Entity $entity, Attribute $attribute, Context $context, array $data = [])
{
$this->coreRegistry = $registry;
$this->formConfig = $formConfig;
$this->entity = $entity;
$this->attribute = $attribute;
parent::__construct($context, $data);
}
示例7: __construct
/**
* Constructor
*
* @param \Magento\Backend\Block\Widget\Context $context
* @param \Magento\Framework\Registry $registry
* @param AccountManagementInterface $customerAccountManagement
* @param CustomerRepositoryInterface $customerRepository
* @param \Magento\Customer\Helper\View $viewHelper
* @param array $data
*/
public function __construct(\Magento\Backend\Block\Widget\Context $context, \Magento\Framework\Registry $registry, AccountManagementInterface $customerAccountManagement, CustomerRepositoryInterface $customerRepository, \Magento\Customer\Helper\View $viewHelper, array $data = [])
{
$this->_coreRegistry = $registry;
$this->customerAccountManagement = $customerAccountManagement;
$this->customerRepository = $customerRepository;
$this->_viewHelper = $viewHelper;
parent::__construct($context, $data);
}
示例8: __construct
/**
* Initialize form
* Add standard buttons
* Add "Save and Continue" button.
*
* @param \Magento\Framework\Registry $registry
* @param \Magento\Backend\Block\Widget\Context $context
*/
public function __construct(\Magento\Framework\Registry $registry, \Magento\Backend\Block\Widget\Context $context)
{
$this->registry = $registry;
$this->_objectId = 'id';
$this->_blockGroup = 'Dotdigitalgroup_Email';
$this->_controller = 'adminhtml_rules';
$data = [];
parent::__construct($context, $data);
$this->addButton('save_and_continue_edit', ['class' => 'save', 'label' => __('Save and Continue Edit'), 'onclick' => 'editForm.submit($(\'edit_form\').action + \'back/edit/\')'], 10);
}
示例9: __construct
/**
* @param Context $context
* @param Registry $registry
* @param \Wirecard\CheckoutPage\Helper\Data $dataHelper
* @param array $data
*/
public function __construct(Context $context, Registry $registry, \Wirecard\CheckoutPage\Helper\Data $dataHelper, array $data = [])
{
parent::__construct($context, $data);
$this->_coreRegistry = $registry;
$this->_dataHelper = $dataHelper;
$this->_objectId = 'id';
$this->_controller = 'adminhtml_fundtransfer';
$this->_blockGroup = 'Wirecard_CheckoutPage';
$this->buttonList->remove('save');
$this->buttonList->add('sendrequest', ['label' => $this->_dataHelper->__('Submit Transfer'), 'class' => 'save', 'onclick' => 'jQuery("#edit_form").submit();'], -100, 0, 'footer');
}
示例10: __construct
/**
* @param \Magento\Backend\Block\Template\Context|\Magento\Backend\Block\Widget\Context $context
* @param \Magento\Framework\ObjectManagerInterface $manager
* @param array $data
* @SuppressWarnings(PHPMD.ExcessiveParameterList)
*/
public function __construct(\Magento\Backend\Block\Widget\Context $context, \Magento\Framework\ObjectManagerInterface $manager, array $data = [])
{
$this->_blockGroup = 'Shockwavemk_Mail_Base';
$this->_controller = 'adminhtml_mail';
$this->_mode = 'edit';
$this->_request = $context->getRequest();
$mailId = $this->_request->getParam('id');
$this->_mail = $manager->get('\\Shockwavemk\\Mail\\Base\\Model\\Mail');
$this->_mail->load($mailId);
parent::__construct($context, $data);
}
示例11: __construct
public function __construct(\Ess\M2ePro\Block\Adminhtml\Magento\Context\Widget $context, array $data = [])
{
$this->helperFactory = $context->getHelperFactory();
$this->modelFactory = $context->getModelFactory();
$this->activeRecordFactory = $context->getActiveRecordFactory();
$this->parentFactory = $context->getParentFactory();
$this->css = $context->getCss();
$this->jsPhp = $context->getJsPhp();
$this->js = $context->getJs();
$this->jsTranslator = $context->getJsTranslator();
$this->jsUrl = $context->getJsUrl();
parent::__construct($context, $data);
}
示例12: __construct
/**
* Constructor
*
* @param \Magento\Backend\Block\Widget\Context $context
* @param \Magento\Framework\Registry $registry
* @param SlideritemsRepositoryInterface $slideritemsRepository
* @param array $data
*/
public function __construct(\Magento\Backend\Block\Widget\Context $context, \Magento\Framework\Registry $registry, SlideritemsRepositoryInterface $slideritemsRepository, array $data = [])
{
$this->coreRegistry = $registry;
$this->slideritemsRepository = $slideritemsRepository;
parent::__construct($context, $data);
}
示例13: __construct
/**
* @param \Magento\Backend\Block\Widget\Context $context
* @param \Magento\Backend\Model\Auth\Session $backendSession
* @param \Magento\Framework\Registry $registry
* @param array $data
*/
public function __construct(\Magento\Backend\Block\Widget\Context $context, \Magento\Backend\Model\Auth\Session $backendSession, \Magento\Framework\Registry $registry, array $data = array())
{
$this->_backendSession = $backendSession;
$this->_coreRegistry = $registry;
parent::__construct($context, $data);
}
示例14: __construct
/**
* @param \Magento\Backend\Block\Widget\Context $context
* @param \Magento\Review\Model\RatingFactory $ratingFactory
* @param \Magento\Framework\Registry $registry
* @param array $data
*/
public function __construct(\Magento\Backend\Block\Widget\Context $context, \Magento\Review\Model\RatingFactory $ratingFactory, \Magento\Framework\Registry $registry, array $data = array())
{
$this->_ratingFactory = $ratingFactory;
$this->_coreRegistry = $registry;
parent::__construct($context, $data);
}
示例15: __construct
/**
* Initialize dependencies.
*
* @param \Magento\Backend\Block\Widget\Context $context
* @param \Magento\Framework\Registry $registry
* @param \Magento\Integration\Helper\Data $integrationHelper
* @param array $data
*/
public function __construct(\Magento\Backend\Block\Widget\Context $context, \Magento\Framework\Registry $registry, \Magento\Integration\Helper\Data $integrationHelper, array $data = array())
{
$this->_registry = $registry;
$this->_integrationHelper = $integrationHelper;
parent::__construct($context, $data);
}