Updates for static analysis

This commit is contained in:
David Bomba 2023-08-06 17:56:26 +10:00
parent e76b650a0b
commit 81bad287ca
3 changed files with 6 additions and 6 deletions

View File

@ -47,9 +47,9 @@ use Illuminate\Contracts\Translation\HasLocalePreference;
* @property string|null $logo
* @property string|null $phone
* @property string|null $routing_id
* @property string $balance
* @property string $paid_to_date
* @property string $credit_balance
* @property float $balance
* @property float $paid_to_date
* @property float $credit_balance
* @property int|null $last_login
* @property int|null $industry_id
* @property int|null $size_id

View File

@ -56,7 +56,7 @@ use Illuminate\Database\Eloquent\SoftDeletes;
* @property float $exchange_rate
* @property int $currency_id
* @property int|null $exchange_currency_id
* @property \App\Models\Paymentable $paymentables
* @property \App\Models\Paymentable $paymentable
* @property object|null $meta
* @property string|null $custom_value1
* @property string|null $custom_value2

View File

@ -171,6 +171,7 @@ trait Refundable
$credit_note->save();
if ($data['gateway_refund'] !== false && $total_refund > 0) {
/** @var \App\Models\CompanyGateway $gateway */
$gateway = CompanyGateway::find($this->company_gateway_id);
if ($gateway) {
@ -190,8 +191,7 @@ trait Refundable
$client_balance_adjustment = $this->adjustInvoices($data);
// $credit_note->ledger()->updateCreditBalance($client_balance_adjustment, $ledger_string);
/** @var \App\Models\Client $this->client */
$this->client->paid_to_date -= $data['amount'];
$this->client->save();