public function WSConnectorGraphQL::getOptionsForm in Web Service Data 2.0.x
Same name and namespace in other branches
- 8 src/Plugin/WSConnector/WSConnectorGraphQL.php \Drupal\wsdata\Plugin\WSConnector\WSConnectorGraphQL::getOptionsForm()
Return the settings form provided by the connector.
Overrides WSConnectorSimpleHTTP::getOptionsForm
File
- src/
Plugin/ WSConnector/ WSConnectorGraphQL.php, line 87
Class
- WSConnectorGraphQL
- HTTP Connector.
Namespace
Drupal\wsdata\Plugin\WSConnectorCode
public function getOptionsForm($options = []) {
$form = parent::getOptionsForm($options);
$form['query'] = [
'#type' => 'textarea',
'#title' => $this
->t('GraphQL Query'),
'#required' => TRUE,
];
$form['operationName'] = [
'#type' => 'textfield',
'#title' => $this
->t('Operation Name (optional)'),
];
$form['variables'] = [
'#type' => 'textarea',
'#title' => $this
->t('GraphQL Variables (optional)'),
];
return $form;
}