Merge pull request #7249 from turbo124/v5-stable

v5.3.64
This commit is contained in:
David Bomba 2022-03-01 21:45:31 +11:00 committed by GitHub
commit bded894b32
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
13 changed files with 137034 additions and 136480 deletions

View File

@ -1 +1 @@
5.3.63 5.3.64

View File

@ -480,11 +480,11 @@ class CheckData extends Command
LEFT JOIN paymentables LEFT JOIN paymentables
ON ON
payments.id = paymentables.payment_id payments.id = paymentables.payment_id
WHERE paymentable_type = 'App\\Models\\Credit' WHERE paymentable_type = ?
AND paymentables.deleted_at is NULL AND paymentables.deleted_at is NULL
AND payments.is_deleted = 0 AND payments.is_deleted = 0
AND payments.client_id = ?; AND payments.client_id = ?;
"), [$client->id] ); "), [App\Models\Credit::class, $client->id] );
return $results; return $results;
} }
@ -507,7 +507,7 @@ class CheckData extends Command
$this->wrong_paid_to_dates++; $this->wrong_paid_to_dates++;
$this->logMessage($client->present()->name.' id = # '.$client->id." - Paid to date does not match Client Paid To Date = {$client->paid_to_date} - Invoice Payments = {$total_paid_to_date}"); $this->logMessage($client->present()->name.' id = # '.$client->id." - Client Paid To Date = {$client->paid_to_date} != Invoice Payments = {$total_paid_to_date} - {$_client->payments_applied} + {$credits_used_for_payments[0]->credit_payment}");
$this->isValid = false; $this->isValid = false;

View File

@ -46,6 +46,8 @@ class CSVIngest implements ShouldQueue {
public array $request; public array $request;
public $tries = 1;
public function __construct( array $request, Company $company ) { public function __construct( array $request, Company $company ) {
$this->company = $company; $this->company = $company;
$this->request = $request; $this->request = $request;

View File

@ -362,6 +362,7 @@ class Import implements ShouldQueue
) { ) {
$data['settings']['invoice_design_id'] = 1; $data['settings']['invoice_design_id'] = 1;
} }
$data['settings']['email_sending_method'] = 'default';
$data = $this->transformCompanyData($data); $data = $this->transformCompanyData($data);
@ -374,9 +375,6 @@ class Import implements ShouldQueue
$data['subdomain'] = MultiDB::randomSubdomainGenerator(); $data['subdomain'] = MultiDB::randomSubdomainGenerator();
} }
else {
$data['email_sending_method'] = 'default';
}
$rules = (new UpdateCompanyRequest())->rules(); $rules = (new UpdateCompanyRequest())->rules();

View File

@ -99,6 +99,6 @@ class ClientService
{ {
$this->client->save(); $this->client->save();
return $this->client; return $this->client->fresh();
} }
} }

View File

@ -145,10 +145,23 @@ class DeletePayment
$multiplier = -1; $multiplier = -1;
$paymentable_credit->service() $paymentable_credit->service()
->updateBalance($paymentable_credit->pivot->amount*$multiplier) ->updateBalance($paymentable_credit->pivot->amount*$multiplier*-1)
->updatePaidToDate($paymentable_credit->pivot->amount*-1) ->updatePaidToDate($paymentable_credit->pivot->amount*$multiplier)
->setStatus(Credit::STATUS_SENT) ->setStatus(Credit::STATUS_SENT)
->save(); ->save();
$this->payment
->client
->service()
->updatePaidToDate(($paymentable_credit->pivot->amount)*-1)
->save();
//01-03-2022
// $paymentable_credit->service()
// ->updateBalance($paymentable_credit->pivot->amount*$multiplier)
// ->updatePaidToDate($paymentable_credit->pivot->amount*-1)
// ->setStatus(Credit::STATUS_SENT)
// ->save();
}); });
} }

View File

@ -412,7 +412,10 @@ class SubscriptionService
->orderBy('id', 'desc') ->orderBy('id', 'desc')
->first(); ->first();
if(!$last_invoice){ if($recurring_invoice->invoices()->count() == 0){
$pro_rata_refund_amount = 0;
}
elseif(!$last_invoice){
$is_credit = true; $is_credit = true;

View File

@ -14,8 +14,8 @@ return [
'require_https' => env('REQUIRE_HTTPS', true), 'require_https' => env('REQUIRE_HTTPS', true),
'app_url' => rtrim(env('APP_URL', ''), '/'), 'app_url' => rtrim(env('APP_URL', ''), '/'),
'app_domain' => env('APP_DOMAIN', 'invoicing.co'), 'app_domain' => env('APP_DOMAIN', 'invoicing.co'),
'app_version' => '5.3.63', 'app_version' => '5.3.64',
'app_tag' => '5.3.63', 'app_tag' => '5.3.64',
'minimum_client_version' => '5.0.16', 'minimum_client_version' => '5.0.16',
'terms_version' => '1.0.1', 'terms_version' => '1.0.1',
'api_secret' => env('API_SECRET', ''), 'api_secret' => env('API_SECRET', ''),

90402
public/main.foss.dart.js vendored

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

85958
public/main.html.dart.js vendored

File diff suppressed because one or more lines are too long

85128
public/main.next.dart.js vendored

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long