mirror of
https://github.com/snipe/snipe-it.git
synced 2026-05-05 22:25:34 +00:00
Add the company/suppliers to the cache. This fixes some issues with duplicate items existing
This commit is contained in:
@ -275,6 +275,7 @@ class ObjectImportCommand extends Command {
|
||||
|
||||
$company = new Company();
|
||||
$company->name = $asset_company_name;
|
||||
$this->companies->add($company);
|
||||
|
||||
if(!$this->option('testrun')) {
|
||||
if ($company->save()) {
|
||||
@ -406,6 +407,7 @@ class ObjectImportCommand extends Command {
|
||||
$supplier = new Supplier();
|
||||
$supplier->name = $supplier_name;
|
||||
$supplier->user_id = 1;
|
||||
$this->suppliers->add($supplier);
|
||||
|
||||
if(!$this->option('testrun')) {
|
||||
if ($supplier->save()) {
|
||||
|
||||
Reference in New Issue
Block a user