1
0
mirror of https://github.com/invoiceninja/invoiceninja.git synced 2024-11-10 13:12:50 +01:00

Fixes for import json

This commit is contained in:
David Bomba 2021-06-08 22:58:46 +10:00
parent f7e91cabd4
commit 9585974b66

View File

@ -164,17 +164,18 @@ class CompanyImport implements ShouldQueue
$this->backup_file = json_decode(base64_decode($this->backup_file));
// nlog($this->backup_file);
$this->checkUserCount();
if(array_key_exists('import_settings', $this->request_array) && $this->request_array['import_settings'] == 'true') {
$this->checkUserCount()->preFlightChecks()->importSettings();
$this->preFlightChecks()->importSettings();
}
if(array_key_exists('import_data', $this->request_array) && $this->request_array['import_data'] == 'true') {
try{
$this->checkUserCount()
->preFlightChecks()
$this->preFlightChecks()
->purgeCompanyData()
->importData();