mirror of
https://github.com/snipe/snipe-it.git
synced 2025-03-05 20:52:15 -08:00
Added created by
Signed-off-by: snipe <snipe@snipe.net>
This commit is contained in:
parent
d7e5fe50eb
commit
54f7917fbe
|
@ -51,6 +51,7 @@ class LocationImporter extends ItemImporter
|
||||||
} else {
|
} else {
|
||||||
$this->log('No Matching Location, Create a new one');
|
$this->log('No Matching Location, Create a new one');
|
||||||
$location = new Location;
|
$location = new Location;
|
||||||
|
$location->created_by = auth()->id();
|
||||||
}
|
}
|
||||||
|
|
||||||
// Pull the records from the CSV to determine their values
|
// Pull the records from the CSV to determine their values
|
||||||
|
@ -65,7 +66,6 @@ class LocationImporter extends ItemImporter
|
||||||
$this->item['ldap_ou'] = trim($this->findCsvMatch($row, 'ldap_ou'));
|
$this->item['ldap_ou'] = trim($this->findCsvMatch($row, 'ldap_ou'));
|
||||||
$this->item['manager'] = trim($this->findCsvMatch($row, 'manager'));
|
$this->item['manager'] = trim($this->findCsvMatch($row, 'manager'));
|
||||||
$this->item['manager_username'] = trim($this->findCsvMatch($row, 'manager_username'));
|
$this->item['manager_username'] = trim($this->findCsvMatch($row, 'manager_username'));
|
||||||
$this->item['created_by'] = auth()->id();
|
|
||||||
|
|
||||||
if ($this->findCsvMatch($row, 'parent_location')) {
|
if ($this->findCsvMatch($row, 'parent_location')) {
|
||||||
$this->item['parent_id'] = $this->createOrFetchLocation(trim($this->findCsvMatch($row, 'parent_location')));
|
$this->item['parent_id'] = $this->createOrFetchLocation(trim($this->findCsvMatch($row, 'parent_location')));
|
||||||
|
|
Loading…
Reference in a new issue