Form.php 690 B

12345678910111213141516171819202122232425262728
  1. <?php
  2. namespace Dotdigitalgroup\Email\Block\Adminhtml\Rules\Edit;
  3. class Form extends \Magento\Backend\Block\Widget\Form\Generic
  4. {
  5. /**
  6. * @return \Magento\Backend\Block\Widget\Form\Generic
  7. */
  8. public function _prepareForm()
  9. {
  10. /** @var \Magento\Framework\Data\Form $form */
  11. $form = $this->_formFactory->create(
  12. [
  13. 'data' => [
  14. 'id' => 'edit_form',
  15. 'action' => $this->getData('action'),
  16. 'method' => 'post',
  17. ],
  18. ]
  19. );
  20. $form->setUseContainer(true);
  21. $this->setForm($form);
  22. return parent::_prepareForm();
  23. }
  24. }