mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-07-09 03:14:30 -04:00
minor fixes
This commit is contained in:
parent
f996da294d
commit
fa635a7ef0
@ -84,8 +84,6 @@ class TemplateEmail extends Mailable
|
|||||||
else
|
else
|
||||||
$email_from_name = $this->company->present()->name();
|
$email_from_name = $this->company->present()->name();
|
||||||
|
|
||||||
nlog($email_from_name);
|
|
||||||
|
|
||||||
$this->from(config('mail.from.address'), $email_from_name);
|
$this->from(config('mail.from.address'), $email_from_name);
|
||||||
|
|
||||||
if (strlen($settings->bcc_email) > 1)
|
if (strlen($settings->bcc_email) > 1)
|
||||||
|
@ -89,6 +89,8 @@ class AutoBillInvoice extends AbstractService
|
|||||||
return $this->invoice;
|
return $this->invoice;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
nlog("Gateway present - adding gateway fee");
|
||||||
|
|
||||||
/* $gateway fee */
|
/* $gateway fee */
|
||||||
$this->invoice = $this->invoice->service()->addGatewayFee($gateway_token->gateway, $gateway_token->gateway_type_id, $amount)->save();
|
$this->invoice = $this->invoice->service()->addGatewayFee($gateway_token->gateway, $gateway_token->gateway_type_id, $amount)->save();
|
||||||
|
|
||||||
@ -105,6 +107,8 @@ class AutoBillInvoice extends AbstractService
|
|||||||
'fee_invoice_id' => $this->invoice->id,
|
'fee_invoice_id' => $this->invoice->id,
|
||||||
]);
|
]);
|
||||||
|
|
||||||
|
nlog("Payment hash created => {$payment_hash->id}");
|
||||||
|
|
||||||
$payment = $gateway_token->gateway
|
$payment = $gateway_token->gateway
|
||||||
->driver($this->client)
|
->driver($this->client)
|
||||||
->setPaymentHash($payment_hash)
|
->setPaymentHash($payment_hash)
|
||||||
|
@ -82,6 +82,8 @@ class DeletePayment
|
|||||||
|
|
||||||
$net_deletable = $paymentable_invoice->pivot->amount - $paymentable_invoice->pivot->refunded;
|
$net_deletable = $paymentable_invoice->pivot->amount - $paymentable_invoice->pivot->refunded;
|
||||||
|
|
||||||
|
nlog("net deletable amount - refunded = {$net_deletable}");
|
||||||
|
|
||||||
$paymentable_invoice->service()
|
$paymentable_invoice->service()
|
||||||
->updateBalance($net_deletable)
|
->updateBalance($net_deletable)
|
||||||
->updatePaidToDate($net_deletable * -1)
|
->updatePaidToDate($net_deletable * -1)
|
||||||
@ -103,8 +105,6 @@ class DeletePayment
|
|||||||
$paymentable_invoice->service()->setStatus(Invoice::STATUS_PARTIAL)->save();
|
$paymentable_invoice->service()->setStatus(Invoice::STATUS_PARTIAL)->save();
|
||||||
}
|
}
|
||||||
|
|
||||||
//fire event for this credit
|
|
||||||
//
|
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user