class MenuEntityCloneForm in Entity Clone 8
Class MenuEntityCloneForm.
Hierarchy
- class \Drupal\entity_clone\EntityClone\Config\ConfigEntityCloneFormBase implements EntityHandlerInterface, EntityCloneFormInterface
- class \Drupal\entity_clone\EntityClone\Config\MenuEntityCloneForm
Expanded class hierarchy of MenuEntityCloneForm
1 file declares its use of MenuEntityCloneForm
- entity_clone.module in ./
entity_clone.module - Contains entity_clone.module.
File
- src/
EntityClone/ Config/ MenuEntityCloneForm.php, line 10
Namespace
Drupal\entity_clone\EntityClone\ConfigView source
class MenuEntityCloneForm extends ConfigEntityCloneFormBase {
/**
* {@inheritdoc}
*/
public function formElement(EntityInterface $entity, $parent = TRUE) {
$form = parent::formElement($entity, $parent);
// Menu entities require special replace pattern.
$form['id']['#machine_name'] += [
'replace_pattern' => '[^a-z0-9-]+',
'replace' => '-',
];
return $form;
}
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
ConfigEntityCloneFormBase:: |
protected | property | The entity type manager. | |
ConfigEntityCloneFormBase:: |
protected | property | The string translation. | |
ConfigEntityCloneFormBase:: |
public static | function |
Instantiates a new instance of this entity handler. Overrides EntityHandlerInterface:: |
|
ConfigEntityCloneFormBase:: |
public | function |
Get all new values provided by the specific form element. Overrides EntityCloneFormInterface:: |
|
ConfigEntityCloneFormBase:: |
public | function | Constructs a new ConfigEntityCloneFormBase. | |
MenuEntityCloneForm:: |
public | function |
Get all specific form element. Overrides ConfigEntityCloneFormBase:: |