James Cole
4 years ago
No known key found for this signature in database
GPG Key ID: BDE6667570EADBD5
3 changed files with
4 additions and
4 deletions
-
app/Services/CSV/Conversion/Routine/LineProcessor.php
-
app/Services/Shared/Configuration/Configuration.php
-
app/Services/Shared/Import/Routine/ApiSubmitter.php
|
|
|
@ -125,13 +125,13 @@ class LineProcessor |
|
|
|
Log::debug('Local mapping (will not be printed)'); |
|
|
|
// the role might change because of the mapping.
|
|
|
|
$role = $this->getRoleForColumn($columnIndex, $mapped); |
|
|
|
$appendValue = config(sprintf('csv_importer.import_roles.%s.append_value', $originalRole)); |
|
|
|
$appendValue = config(sprintf('csv.import_roles.%s.append_value', $originalRole)); |
|
|
|
|
|
|
|
if (null === $appendValue) { |
|
|
|
$appendValue = false; |
|
|
|
} |
|
|
|
|
|
|
|
Log::debug(sprintf('Append value config: %s', sprintf('csv_importer.import_roles.%s.append_value', $originalRole))); |
|
|
|
Log::debug(sprintf('Append value config: %s', sprintf('csv.import_roles.%s.append_value', $originalRole))); |
|
|
|
|
|
|
|
$columnValue = new ColumnValue; |
|
|
|
$columnValue->setValue($value); |
|
|
|
|
|
|
|
@ -331,7 +331,7 @@ class Configuration |
|
|
|
// some roles have been given a new name some time in the past.
|
|
|
|
$role = $classicRoleNames[$role] ?? $role; |
|
|
|
|
|
|
|
$config = config(sprintf('csv_importer.import_roles.%s', $role)); |
|
|
|
$config = config(sprintf('csv.import_roles.%s', $role)); |
|
|
|
if (null !== $config) { |
|
|
|
$object->roles[] = $role; |
|
|
|
} |
|
|
|
|
|
|
|
@ -197,7 +197,7 @@ class ApiSubmitter |
|
|
|
private function searchField(string $field, string $value): int |
|
|
|
{ |
|
|
|
// search for the exact description and not just a part of it:
|
|
|
|
$searchModifier = config(sprintf('csv_importer.search_modifier.%s', $field)); |
|
|
|
$searchModifier = config(sprintf('csv.search_modifier.%s', $field)); |
|
|
|
$query = sprintf('%s:"%s"', $searchModifier, $value); |
|
|
|
|
|
|
|
Log::debug(sprintf('Going to search for %s:%s using query %s', $field, $value, $query)); |
|
|
|
|