You are here

public function RefreshDirectoryTree::render in Media Directories 8

Same name and namespace in other branches
  1. 3.x modules/media_directories_ui/src/Ajax/RefreshDirectoryTree.php \Drupal\media_directories_ui\Ajax\RefreshDirectoryTree::render()
  2. 2.x modules/media_directories_ui/src/Ajax/RefreshDirectoryTree.php \Drupal\media_directories_ui\Ajax\RefreshDirectoryTree::render()

Implements \Drupal\Core\Ajax\CommandInterface:render().

Overrides CommandInterface::render

File

modules/media_directories_ui/src/Ajax/RefreshDirectoryTree.php, line 42

Class

RefreshDirectoryTree
Class RefreshDirectoryTree.

Namespace

Drupal\media_directories_ui\Ajax

Code

public function render() {
  return [
    'command' => 'refreshDirectoryTree',
    'data' => [
      'selected_directory' => isset($this->selectedDirectory) ? $this->selectedDirectory : MEDIA_DIRECTORY_ROOT,
      'newly_selected_entity_ids' => $this->newlySelectedEntityIds,
    ],
  ];
}