public function EntityQueryMapImportForm::form in GraphQL 8.3
Gets the actual form array to be built.
Overrides EntityForm::form
See also
\Drupal\Core\Entity\EntityForm::processForm()
\Drupal\Core\Entity\EntityForm::afterBuild()
File
- src/
Form/ EntityQueryMapImportForm.php, line 18
Class
- EntityQueryMapImportForm
- Form controller for GraphQL query map forms.
Namespace
Drupal\graphql\FormCode
public function form(array $form, FormStateInterface $formStaet) {
$form = parent::form($form, $formStaet);
$form['query_map_json'] = [
'#type' => 'file',
'#title' => $this
->t('Query map'),
'#description' => $this
->t('Upload a query map .json file.'),
];
$form['actions'] = [
'#type' => 'actions',
];
$form['actions']['submit'] = [
'#type' => 'submit',
'#value' => $this
->t('Submit'),
];
return $form;
}