Merge pull request #12205 from Godmartinz/sc19675_add_remote_to_importer
Adds remote field to the user importer
This commit is contained in:
commit
d13a237000
4 changed files with 14232 additions and 14228 deletions
|
@ -77,6 +77,7 @@ abstract class Importer
|
||||||
'manager_first_name' => 'manager first name',
|
'manager_first_name' => 'manager first name',
|
||||||
'manager_last_name' => 'manager last name',
|
'manager_last_name' => 'manager last name',
|
||||||
'min_amt' => 'minimum quantity',
|
'min_amt' => 'minimum quantity',
|
||||||
|
'remote' => 'remote',
|
||||||
];
|
];
|
||||||
/**
|
/**
|
||||||
* Map of item fields->csv names
|
* Map of item fields->csv names
|
||||||
|
@ -288,6 +289,7 @@ abstract class Importer
|
||||||
'department_id' => '',
|
'department_id' => '',
|
||||||
'username' => $this->findCsvMatch($row, 'username'),
|
'username' => $this->findCsvMatch($row, 'username'),
|
||||||
'activated' => $this->fetchHumanBoolean($this->findCsvMatch($row, 'activated')),
|
'activated' => $this->fetchHumanBoolean($this->findCsvMatch($row, 'activated')),
|
||||||
|
'remote' => $this->fetchHumanBoolean(($this->findCsvMatch($row, 'remote'))),
|
||||||
];
|
];
|
||||||
|
|
||||||
// Maybe we're lucky and the user already exists.
|
// Maybe we're lucky and the user already exists.
|
||||||
|
|
|
@ -57,6 +57,7 @@ class UserImporter extends ItemImporter
|
||||||
$this->item['employee_num'] = $this->findCsvMatch($row, 'employee_num');
|
$this->item['employee_num'] = $this->findCsvMatch($row, 'employee_num');
|
||||||
$this->item['department_id'] = $this->createOrFetchDepartment($this->findCsvMatch($row, 'department'));
|
$this->item['department_id'] = $this->createOrFetchDepartment($this->findCsvMatch($row, 'department'));
|
||||||
$this->item['manager_id'] = $this->fetchManager($this->findCsvMatch($row, 'manager_first_name'), $this->findCsvMatch($row, 'manager_last_name'));
|
$this->item['manager_id'] = $this->fetchManager($this->findCsvMatch($row, 'manager_first_name'), $this->findCsvMatch($row, 'manager_last_name'));
|
||||||
|
$this->item['remote'] =($this->fetchHumanBoolean($this->findCsvMatch($row, 'remote')) ==1 ) ? '1' : 0;
|
||||||
|
|
||||||
$user_department = $this->findCsvMatch($row, 'department');
|
$user_department = $this->findCsvMatch($row, 'department');
|
||||||
if ($this->shouldUpdateField($user_department)) {
|
if ($this->shouldUpdateField($user_department)) {
|
||||||
|
|
28456
public/js/dist/all.js
vendored
28456
public/js/dist/all.js
vendored
File diff suppressed because it is too large
Load diff
|
@ -194,6 +194,7 @@
|
||||||
{id: 'state', text: 'State' },
|
{id: 'state', text: 'State' },
|
||||||
{id: 'country', text: 'Country' },
|
{id: 'country', text: 'Country' },
|
||||||
{id: 'zip', text: 'ZIP' },
|
{id: 'zip', text: 'ZIP' },
|
||||||
|
{id: 'remote', text: 'Remote'},
|
||||||
|
|
||||||
],
|
],
|
||||||
customFields: this.customFields,
|
customFields: this.customFields,
|
||||||
|
|
Loading…
Add table
Reference in a new issue