annotate modules/contrib/migrate_tools/src/Form/MigrationGroupAddForm.php @ 7:848c88cfe644

More layout
author Chris Cannam
date Fri, 05 Jan 2018 13:59:44 +0000
parents 4c8ae668cc8c
children
rev   line source
Chris@0 1 <?php
Chris@0 2
Chris@0 3 namespace Drupal\migrate_tools\Form;
Chris@0 4
Chris@0 5 use Drupal\Core\Form\FormStateInterface;
Chris@0 6
Chris@0 7 /**
Chris@0 8 * Class MigrationGroupAddForm.
Chris@0 9 *
Chris@0 10 * Provides the add form for our migration_group entity.
Chris@0 11 *
Chris@0 12 * @package Drupal\migrate_tools\Form
Chris@0 13 *
Chris@0 14 * @ingroup migrate_tools
Chris@0 15 */
Chris@0 16 class MigrationGroupAddForm extends MigrationGroupFormBase {
Chris@0 17
Chris@0 18 /**
Chris@0 19 * Returns the actions provided by this form.
Chris@0 20 *
Chris@0 21 * For our add form, we only need to change the text of the submit button.
Chris@0 22 *
Chris@0 23 * @param array $form
Chris@0 24 * An associative array containing the structure of the form.
Chris@0 25 * @param \Drupal\Core\Form\FormStateInterface $form_state
Chris@0 26 * An associative array containing the current state of the form.
Chris@0 27 *
Chris@0 28 * @return array
Chris@0 29 * An array of supported actions for the current entity form.
Chris@0 30 */
Chris@0 31 protected function actions(array $form, FormStateInterface $form_state) {
Chris@0 32 $actions = parent::actions($form, $form_state);
Chris@0 33 $actions['submit']['#value'] = $this->t('Create Migration Group');
Chris@0 34 return $actions;
Chris@0 35 }
Chris@0 36
Chris@0 37 }