You are here

public function MigrateSourceSpreadsheet::fields in Migrate 7.2

Returns a list of fields available to be mapped from the source query.

Return value

array Keys: machine names of the fields (to be passed to addFieldMapping). Values: Human-friendly descriptions of the fields.

Overrides MigrateSource::fields

File

plugins/sources/spreadsheet.inc, line 193
Define a MigrateSource for importing from spreadsheet files.

Class

MigrateSourceSpreadsheet
Implements MigrateSource, to handle imports from XLS files.

Code

public function fields() {
  $fields = array();
  foreach ($this->fields as $name) {
    $fields[$name] = $name;
  }
  return $fields;
}