mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2024-09-20 08:21:34 +02:00
Fixes for missing invites for recurring invitations
This commit is contained in:
parent
6eab259568
commit
5371bed25b
@ -63,6 +63,19 @@ class CreateRecurringInvitations extends AbstractService
|
||||
info($e->getMessage());
|
||||
}
|
||||
|
||||
if ($this->entity->invitations()->count() == 0) {
|
||||
|
||||
$invitation = $this->invitation_class::where('company_id', $this->entity->company_id)
|
||||
->where($this->entity_id_name, $this->entity->id)
|
||||
->withTrashed()
|
||||
->first();
|
||||
|
||||
if ($invitation)
|
||||
$invitation->restore();
|
||||
|
||||
}
|
||||
|
||||
|
||||
return $this->entity;
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user