You are here

public function MediaLibrarySelectForm::getValue in Drupal 9

Same name and namespace in other branches
  1. 8 core/modules/media_library/src/Plugin/views/field/MediaLibrarySelectForm.php \Drupal\media_library\Plugin\views\field\MediaLibrarySelectForm::getValue()

Gets the value that's supposed to be rendered.

This api exists so that other modules can easy set the values of the field without having the need to change the render method as well.

Parameters

\Drupal\views\ResultRow $values: An object containing all retrieved values.

string $field: Optional name of the field where the value is stored.

Overrides FieldPluginBase::getValue

1 call to MediaLibrarySelectForm::getValue()
MediaLibrarySelectForm::render in core/modules/media_library/src/Plugin/views/field/MediaLibrarySelectForm.php
Renders the field.

File

core/modules/media_library/src/Plugin/views/field/MediaLibrarySelectForm.php, line 28

Class

MediaLibrarySelectForm
Defines a field that outputs a checkbox and form for selecting media.

Namespace

Drupal\media_library\Plugin\views\field

Code

public function getValue(ResultRow $row, $field = NULL) {
  return '<!--form-item-' . $this->options['id'] . '--' . $row->index . '-->';
}