mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-07-09 03:14:30 -04:00
Enforce subdomain mode when migrating
This commit is contained in:
parent
41b4812c50
commit
5121a02b4d
@ -102,6 +102,7 @@ trait GenerateMigrationResources
|
|||||||
'custom_surcharge_taxes1' => $this->account->custom_invoice_taxes1,
|
'custom_surcharge_taxes1' => $this->account->custom_invoice_taxes1,
|
||||||
'custom_surcharge_taxes2' => $this->account->custom_invoice_taxes2,
|
'custom_surcharge_taxes2' => $this->account->custom_invoice_taxes2,
|
||||||
'subdomain' => $this->account->subdomain,
|
'subdomain' => $this->account->subdomain,
|
||||||
|
'portal_mode' => 'subdomain',
|
||||||
'size_id' => $this->account->size_id,
|
'size_id' => $this->account->size_id,
|
||||||
'enable_modules' => $this->account->enabled_modules,
|
'enable_modules' => $this->account->enabled_modules,
|
||||||
'custom_fields' => $this->account->custom_fields,
|
'custom_fields' => $this->account->custom_fields,
|
||||||
@ -552,13 +553,14 @@ trait GenerateMigrationResources
|
|||||||
{
|
{
|
||||||
|
|
||||||
$credits = [];
|
$credits = [];
|
||||||
|
$export_credits = collect([]);
|
||||||
|
|
||||||
$export_credits = Invoice::where('account_id', $this->account->id)
|
// $export_credits = Invoice::where('account_id', $this->account->id)
|
||||||
->where('balance', '<', '0')
|
// ->where('balance', '<', '0')
|
||||||
->where('invoice_type_id', '=', INVOICE_TYPE_STANDARD)
|
// ->where('invoice_type_id', '=', INVOICE_TYPE_STANDARD)
|
||||||
->where('is_public', true)
|
// ->where('is_public', true)
|
||||||
->withTrashed()
|
// ->withTrashed()
|
||||||
->get();
|
// ->get();
|
||||||
|
|
||||||
info("get credit notes => " . $export_credits->count());
|
info("get credit notes => " . $export_credits->count());
|
||||||
|
|
||||||
@ -613,7 +615,7 @@ trait GenerateMigrationResources
|
|||||||
$invoices = [];
|
$invoices = [];
|
||||||
|
|
||||||
$export_invoices = Invoice::where('account_id', $this->account->id)
|
$export_invoices = Invoice::where('account_id', $this->account->id)
|
||||||
->where('amount', '>=', 0)
|
// ->where('amount', '>=', 0)
|
||||||
->where('invoice_type_id', INVOICE_TYPE_STANDARD)
|
->where('invoice_type_id', INVOICE_TYPE_STANDARD)
|
||||||
->where('is_recurring', false)
|
->where('is_recurring', false)
|
||||||
->withTrashed()
|
->withTrashed()
|
||||||
|
Loading…
x
Reference in New Issue
Block a user