mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-06-01 10:04:34 -04:00
Working on recurring invoices + reminders
This commit is contained in:
parent
84ec6b35cd
commit
f8f8da830e
@ -37,7 +37,7 @@ class RecurringInvoicesCron
|
||||
public function handle() : void
|
||||
{
|
||||
/* Get all invoices where the send date is less than NOW + 30 minutes() */
|
||||
info("Sending recurring invoices {now()}");
|
||||
info("Sending recurring invoices {Carbon::now()->format('Y-m-d h:i:s')}");
|
||||
|
||||
if (! config('ninja.db.multi_db_enabled')) {
|
||||
|
||||
|
@ -66,6 +66,9 @@ class ReminderJob implements ShouldQueue
|
||||
|
||||
if ($invoice->isPayable()) {
|
||||
|
||||
$reminder_template = $invoice->calculateTemplate();
|
||||
$invoice->service()->touchReminder($this->reminder_template)->save();
|
||||
|
||||
$invoice->invitations->each(function ($invitation) use ($invoice) {
|
||||
$email_builder = (new InvoiceEmail())->build($invitation);
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user