mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-05-24 02:14:21 -04:00
Fixes for Github Actions
This commit is contained in:
parent
fcbef56e46
commit
9941d72d31
2
.env.ci
2
.env.ci
@ -5,7 +5,7 @@ APP_DEBUG=true
|
||||
APP_URL=http://ninja.test
|
||||
MULTI_DB_ENABLED=false
|
||||
# database
|
||||
DB_CONNECTION=db-ninja-01
|
||||
DB_CONNECTION=mysql
|
||||
DB_DATABASE1=ninja
|
||||
DB_USERNAME1=root
|
||||
DB_PASSWORD1=ninja
|
||||
|
@ -511,7 +511,7 @@ class SubscriptionService
|
||||
|
||||
$total_payable = $pro_rata_refund_amount + $pro_rata_charge_amount + $this->subscription->price;
|
||||
|
||||
return $this->proRataInvoice($last_invoice, $target_subscription);
|
||||
return $this->proRataInvoice($last_invoice, $target_subscription, $recurring_invoice->client_id);
|
||||
|
||||
}
|
||||
|
||||
@ -614,7 +614,7 @@ nlog("handle plan change");
|
||||
* @param Subscription $target
|
||||
* @return Invoice
|
||||
*/
|
||||
private function proRataInvoice($last_invoice, $target)
|
||||
private function proRataInvoice($last_invoice, $target, $client_id)
|
||||
{
|
||||
$subscription_repo = new SubscriptionRepository();
|
||||
$invoice_repo = new InvoiceRepository();
|
||||
@ -626,7 +626,7 @@ nlog("handle plan change");
|
||||
$invoice->line_items = array_merge($subscription_repo->generateLineItems($target), $this->calculateProRataRefundItems($last_invoice));
|
||||
|
||||
$data = [
|
||||
'client_id' => $last_invoice->client_id,
|
||||
'client_id' => $client_id,
|
||||
'quantity' => 1,
|
||||
'date' => now()->format('Y-m-d'),
|
||||
];
|
||||
|
@ -46,7 +46,7 @@ return [
|
||||
'prefix' => '',
|
||||
'prefix_indexes' => true,
|
||||
'strict' => env('DB_STRICT', false),
|
||||
'engine' => 'InnoDB ROW_FORMAT=COMPRESSED KEY_BLOCK_SIZE=8',
|
||||
// 'engine' => 'InnoDB ROW_FORMAT=COMPRESSED KEY_BLOCK_SIZE=8',
|
||||
],
|
||||
|
||||
'sqlite' => [
|
||||
|
Loading…
x
Reference in New Issue
Block a user