mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-07-09 03:14:30 -04:00
Fixes for recurring ivnoices
This commit is contained in:
parent
bfc412f18e
commit
a6cedef7d8
@ -52,7 +52,7 @@ class SubscriptionCron
|
|||||||
->whereNotNull('subscription_id')
|
->whereNotNull('subscription_id')
|
||||||
->cursor();
|
->cursor();
|
||||||
|
|
||||||
$invoices->each(function ($invoice) {
|
$invoices->each(function (Invoice $invoice) {
|
||||||
$subscription = $invoice->subscription;
|
$subscription = $invoice->subscription;
|
||||||
|
|
||||||
$body = [
|
$body = [
|
||||||
@ -80,7 +80,7 @@ class SubscriptionCron
|
|||||||
->whereNotNull('subscription_id')
|
->whereNotNull('subscription_id')
|
||||||
->cursor();
|
->cursor();
|
||||||
|
|
||||||
$invoices->each(function ($invoice) {
|
$invoices->each(function (Invoice $invoice) {
|
||||||
$subscription = $invoice->subscription;
|
$subscription = $invoice->subscription;
|
||||||
|
|
||||||
$body = [
|
$body = [
|
||||||
|
@ -94,7 +94,7 @@ class VersionCheck implements ShouldQueue
|
|||||||
|
|
||||||
Client::doesntHave('contacts')
|
Client::doesntHave('contacts')
|
||||||
->cursor()
|
->cursor()
|
||||||
->each(function ($client) {
|
->each(function (Client $client) {
|
||||||
|
|
||||||
$new_contact = ClientContactFactory::create($client->company_id, $client->user_id);
|
$new_contact = ClientContactFactory::create($client->company_id, $client->user_id);
|
||||||
$new_contact->client_id = $client->id;
|
$new_contact->client_id = $client->id;
|
||||||
|
@ -76,7 +76,7 @@ class InventoryNotificationObject
|
|||||||
'settings' => $this->product->company->settings,
|
'settings' => $this->product->company->settings,
|
||||||
'whitelabel' => $this->product->company->account->isPaid() ? true : false,
|
'whitelabel' => $this->product->company->account->isPaid() ? true : false,
|
||||||
'text_body' => $content,
|
'text_body' => $content,
|
||||||
'template' => $this->company->account->isPremium() ? 'email.template.admin_premium' : 'email.template.admin',
|
'template' => $this->product->company->account->isPremium() ? 'email.template.admin_premium' : 'email.template.admin',
|
||||||
];
|
];
|
||||||
|
|
||||||
return $data;
|
return $data;
|
||||||
|
@ -122,7 +122,6 @@ use Laracasts\Presenter\PresentableTrait;
|
|||||||
* @property-read \Illuminate\Database\Eloquent\Collection<int, \App\Models\Backup> $history
|
* @property-read \Illuminate\Database\Eloquent\Collection<int, \App\Models\Backup> $history
|
||||||
* @property-read \Illuminate\Database\Eloquent\Collection<int, \App\Models\RecurringInvoiceInvitation> $invitations
|
* @property-read \Illuminate\Database\Eloquent\Collection<int, \App\Models\RecurringInvoiceInvitation> $invitations
|
||||||
* @property-read \Illuminate\Database\Eloquent\Collection<int, \App\Models\Invoice> $invoices
|
* @property-read \Illuminate\Database\Eloquent\Collection<int, \App\Models\Invoice> $invoices
|
||||||
* @method static \Illuminate\Database\Eloquent\Builder|BaseModel company()
|
|
||||||
* @property bool $is_proforma
|
* @property bool $is_proforma
|
||||||
* @mixin \Eloquent
|
* @mixin \Eloquent
|
||||||
*/
|
*/
|
||||||
@ -295,6 +294,9 @@ class RecurringInvoice extends BaseModel
|
|||||||
return $this->hasManyThrough(Backup::class, Activity::class);
|
return $this->hasManyThrough(Backup::class, Activity::class);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @return \Illuminate\Database\Eloquent\Relations\BelongsTo<Company>
|
||||||
|
*/
|
||||||
public function company(): \Illuminate\Database\Eloquent\Relations\BelongsTo
|
public function company(): \Illuminate\Database\Eloquent\Relations\BelongsTo
|
||||||
{
|
{
|
||||||
return $this->belongsTo(Company::class);
|
return $this->belongsTo(Company::class);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user