Skip to content
......@@ -303,17 +303,20 @@ class JsonapiResourceConfigForm extends EntityForm {
$overrides_form['overrides']['fields'] = [
'#type' => 'details',
'#title' => $this->t('Fields'),
'#description' => $this->t('Override configuration for the resource fields.'),
'#open' => TRUE,
];
$markup = '';
$markup .= '<dl>';
$markup .= '<dt>' . t('Disabled') . '</dt>';
$markup .= '<dd>' . t('Check this if you want to disable this field completely. Disabling required fields will cause problems when writing to the resource.') . '</dd>';
$markup .= '<dt>' . t('Alias') . '</dt>';
$markup .= '<dd>' . t('Overrides the field name with a custom name. Example: Change "field_tags" to "tags".') . '</dd>';
$markup .= '<dt>' . t('Enhancer') . '</dt>';
$markup .= '<dd>' . t('Select an enhancer to manipulate the public output coming in and out.') . '</dd>';
$markup .= '</dl>';
$overrides_form['overrides']['fields']['info'] = [
'#theme' => 'item_list',
'#items' => [
$this->t('<strong>Disabled</strong>: Check this if you want to disable this field completely. Disabling required fields will cause problems when writing to the resource.'),
$this->t('<strong>Alias</strong>: Overrides the field name with a custom name. Example: Change "field_tags" to "tags".'),
$this->t('<strong>Enhancer</strong>: Select an enhancer to manipulate the public output coming in and out.'),
],
'#markup' => $markup,
];
$overrides_form['overrides']['fields']['resourceFields'] = [
......@@ -375,7 +378,7 @@ class JsonapiResourceConfigForm extends EntityForm {
$overrides_form['disabled'] = [
'#type' => 'checkbox',
'#title' => $this->t('Disabled'),
'#title_display' => 'hidden',
'#title_display' => 'invisible',
'#default_value' => $resource_field['disabled'],
];
$overrides_form['fieldName'] = [
......