function FieldFormSavedCommand::__construct

Same name in other branches
  1. 8.9.x core/modules/quickedit/src/Ajax/FieldFormSavedCommand.php \Drupal\quickedit\Ajax\FieldFormSavedCommand::__construct()

Constructs a FieldFormSavedCommand object.

Parameters

string $data: The re-rendered edited field to pass on to the client side.

array $other_view_modes: The same re-rendered edited field, but in different view modes, for other instances of the same field on the user's page. Keyed by view mode.

Overrides BaseCommand::__construct

File

core/modules/quickedit/src/Ajax/FieldFormSavedCommand.php, line 28

Class

FieldFormSavedCommand
Indicates a field was saved and passes the rerendered field to Quick Edit.

Namespace

Drupal\quickedit\Ajax

Code

public function __construct($data, $other_view_modes = []) {
    parent::__construct('quickeditFieldFormSaved', $data);
    $this->other_view_modes = $other_view_modes;
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.