You are here

protected function Exporter::getRepeatableFieldValues in GatherContent 8.5

Moves field values into an array.

Parameters

\Drupal\Core\Field\FieldItemListInterface $fieldItemList: The list of field values.

Return value

array Field values in an array.

1 call to Exporter::getRepeatableFieldValues()
Exporter::processSetFields in gathercontent_upload/src/Export/Exporter.php
Set value of the field.

File

gathercontent_upload/src/Export/Exporter.php, line 749

Class

Exporter
Class for handling import/update logic from GatherContent to Drupal.

Namespace

Drupal\gathercontent_upload\Export

Code

protected function getRepeatableFieldValues(FieldItemListInterface $fieldItemList) : array {
  $fieldValues = $fieldItemList
    ->getValue();
  $values = [];
  foreach ($fieldValues as $fieldValue) {
    $values[] = $fieldValue['value'];
  }
  return $values;
}