class ErlStateResetCommand in Entity Reference with Layout 8
Class ErlState.
Hierarchy
- class \Drupal\entity_reference_layout\Ajax\ErlStateResetCommand implements CommandInterface
Expanded class hierarchy of ErlStateResetCommand
1 file declares its use of ErlStateResetCommand
- EntityReferenceLayoutWidget.php in src/
Plugin/ Field/ FieldWidget/ EntityReferenceLayoutWidget.php
File
- src/
Ajax/ ErlStateResetCommand.php, line 10
Namespace
Drupal\entity_reference_layout\AjaxView source
class ErlStateResetCommand implements CommandInterface {
/**
* The wrapper DOM id.
*
* @var string
*/
protected $id;
/**
* Constructs an ErlState instance.
*/
public function __construct($id) {
$this->id = $id;
}
/**
* Render custom ajax command.
*
* @return ajax
* Command function.
*/
public function render() {
return [
'command' => 'resetErlState',
'data' => [
"id" => $this->id,
],
];
}
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
ErlStateResetCommand:: |
protected | property | The wrapper DOM id. | |
ErlStateResetCommand:: |
public | function |
Render custom ajax command. Overrides CommandInterface:: |
|
ErlStateResetCommand:: |
public | function | Constructs an ErlState instance. |