mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2024-11-08 20:22:42 +01:00
Minor fixes
This commit is contained in:
parent
056490fd8f
commit
6bb1f75292
@ -432,15 +432,20 @@ class Import implements ShouldQueue
|
||||
}
|
||||
}
|
||||
|
||||
$rules = (new UpdateCompanyRequest())->rules();
|
||||
// $rules = (new UpdateCompanyRequest())->rules();
|
||||
|
||||
unset($rules['expense_mailbox']);
|
||||
|
||||
$validator = Validator::make($data, $rules);
|
||||
// unset($rules['expense_mailbox']);
|
||||
// unset($rules['e_invoice']);
|
||||
// unset($rules['smtp_port']);
|
||||
// unset($rules['settings']);
|
||||
|
||||
if ($validator->fails()) {
|
||||
throw new MigrationValidatorFailed(json_encode($validator->errors()));
|
||||
}
|
||||
// $validator = Validator::make($data, $rules);
|
||||
|
||||
// nlog($validator->errors());
|
||||
|
||||
// if ($validator->fails()) {
|
||||
// throw new MigrationValidatorFailed(json_encode($validator->errors()));
|
||||
// }
|
||||
|
||||
if (isset($data['account_id'])) {
|
||||
unset($data['account_id']);
|
||||
|
@ -455,12 +455,7 @@ class BaseDriver extends AbstractPaymentDriver
|
||||
$new_balance = $invoice->balance;
|
||||
|
||||
if (floatval($new_balance) - floatval($balance) != 0) {
|
||||
$adjustment = $new_balance - $balance;
|
||||
|
||||
$invoice
|
||||
->ledger()
|
||||
->updateInvoiceBalance($adjustment, 'Adjustment for adding gateway fee **Base Driver**');
|
||||
|
||||
$adjustment = $new_balance - $balance;
|
||||
$invoice->client->service()->calculateBalance();
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user