protected function _prepareForm()
    {
        /** @var \Magento\Framework\Data\Form $form */
        $form = $this->_formFactory->create(
            ['data' => ['id' => 'edit_form', 'action' => $this->getData('action')]]
        );

        $thesaurusTypes = [
            ['value' => ThesaurusInterface::TYPE_SYNONYM, 'label' => __('Synonym')],
            ['value' => ThesaurusInterface::TYPE_EXPANSION, 'label' => __('Expansion')],
        ];

        $fieldset = $form->addFieldset('base_fieldset', ['legend' => __('Type')]);

        $fieldset->addField(
            'type',
            'select',
            [
                'name' => 'type',
                'label' => __('Thesaurus Type'),
                'title' => __('Thesaurus Type'),
                'values' => $thesaurusTypes,
            ]
        );

        $form->setUseContainer(true);
        $this->setForm($form);

        return parent::_prepareForm();
    }
protected function _prepareForm()
    {
        /** @var \Magento\Framework\Data\Form $form */
        $form = $this->_formFactory->create(
            ['data' => ['id' => 'edit_form', 'action' => $this->getData('action')]]
        );

        $thesaurusTypes = [
            ['value' => ThesaurusInterface::TYPE_SYNONYM, 'label' => __('Synonym')],
            ['value' => ThesaurusInterface::TYPE_EXPANSION, 'label' => __('Expansion')],
        ];

        $fieldset = $form->addFieldset('base_fieldset', ['legend' => __('Type')]);

        $fieldset->addField(
            'type',
            'select',
            [
                'name' => 'type',
                'label' => __('Thesaurus Type'),
                'title' => __('Thesaurus Type'),
                'values' => $thesaurusTypes,
            ]
        );

        $form->setUseContainer(true);
        $this->setForm($form);

        return parent::_prepareForm();
    }
protected function _prepareForm ( ) { /** @var \Magento\Framework\Data\Form $form */ $ form = $ this -> _formFactory -> create ( [ 'data' => [ 'id' => 'edit_form' , 'action' => $ this -> getData ( 'action' ) ] ] ) ; $ thesaurusTypes = [ [ 'value' => ThesaurusInterface :: TYPE_SYNONYM , 'label' => __ ( 'Synonym' ) ] , [ 'value' => ThesaurusInterface :: TYPE_EXPANSION , 'label' => __ ( 'Expansion' ) ] , ] ; $ fieldset = $ form -> addFieldset ( 'base_fieldset' , [ 'legend' => __ ( 'Type' ) ] ) ; $ fieldset -> addField ( 'type' , 'select' , [ 'name' => 'type' , 'label' => __ ( 'Thesaurus Type' ) , 'title' => __ ( 'Thesaurus Type' ) , 'values' => $ thesaurusTypes , ] ) ; $ form -> setUseContainer ( true ) ; $ this -> setForm ( $ form ) ; return parent :: _prepareForm ( ) ; }
Prepare form fields

@SuppressWarnings(PHPMD.CamelCaseMethodName)

@return Form
Prepare form fields