mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2024-11-11 05:32:39 +01:00
Merge pull request #7663 from turbo124/v5-develop
Force delete activities on purge data
This commit is contained in:
commit
c578ad48be
@ -147,7 +147,12 @@ class InvoiceItemExport extends BaseExport
|
||||
if(str_contains($key, "item.")){
|
||||
|
||||
$key = str_replace("item.", "", $key);
|
||||
$item_array[$key] = $item->{$key};
|
||||
|
||||
if(property_exists($item, $key))
|
||||
$item_array[$key] = $item->{$key};
|
||||
else
|
||||
$item_array[$key] = '';
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -180,6 +180,7 @@ class MigrationController extends BaseController
|
||||
$company->vendors()->forceDelete();
|
||||
$company->expenses()->forceDelete();
|
||||
$company->purchase_orders()->forceDelete();
|
||||
$company->all_activities()->forceDelete();
|
||||
|
||||
$settings = $company->settings;
|
||||
|
||||
|
@ -469,6 +469,7 @@ class CompanyImport implements ShouldQueue
|
||||
private function purgeCompanyData()
|
||||
{
|
||||
$this->company->clients()->forceDelete();
|
||||
$this->company->all_activities()->forceDelete();
|
||||
$this->company->products()->forceDelete();
|
||||
$this->company->projects()->forceDelete();
|
||||
$this->company->tasks()->forceDelete();
|
||||
|
@ -301,11 +301,6 @@ class CompanyGateway extends BaseModel
|
||||
|
||||
$fee = $this->calcGatewayFee($amount, $gateway_type_id);
|
||||
|
||||
// if ($fee > 0) {
|
||||
// $fee = Number::formatMoney(round($fee, 2), $client);
|
||||
// $label = ' - '.$fee.' '.ctrans('texts.fee');
|
||||
// }
|
||||
|
||||
if($fee > 0) {
|
||||
|
||||
$fees_and_limits = $this->fees_and_limits->{$gateway_type_id};
|
||||
|
Loading…
Reference in New Issue
Block a user