public function LeafletMap::getFieldValue in Leaflet 2.0.x
Same name and namespace in other branches
- 8 modules/leaflet_views/src/Plugin/views/style/LeafletMap.php \Drupal\leaflet_views\Plugin\views\style\LeafletMap::getFieldValue()
- 2.1.x modules/leaflet_views/src/Plugin/views/style/LeafletMap.php \Drupal\leaflet_views\Plugin\views\style\LeafletMap::getFieldValue()
Get the raw field value.
Parameters
$index: The index count of the row.
$field: The id of the field.
Overrides StylePluginBase::getFieldValue
1 call to LeafletMap::getFieldValue()
- LeafletMap::render in modules/
leaflet_views/ src/ Plugin/ views/ style/ LeafletMap.php - Renders the View.
File
- modules/
leaflet_views/ src/ Plugin/ views/ style/ LeafletMap.php, line 310
Class
- LeafletMap
- Style plugin to render a View output as a Leaflet map.
Namespace
Drupal\leaflet_views\Plugin\views\styleCode
public function getFieldValue($index, $field) {
$this->view->row_index = $index;
$value = isset($this->view->field[$field]) ? $this->view->field[$field]
->getValue($this->view->result[$index]) : NULL;
unset($this->view->row_index);
return $value;
}