mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2024-11-10 13:12:50 +01:00
Fixes for recurring
This commit is contained in:
parent
d9c6ce1f4c
commit
03e9bf0bc7
@ -45,27 +45,27 @@ class Kernel extends ConsoleKernel
|
|||||||
{
|
{
|
||||||
|
|
||||||
//$schedule->job(new RecurringInvoicesCron)->hourly();
|
//$schedule->job(new RecurringInvoicesCron)->hourly();
|
||||||
$schedule->job(new VersionCheck)->daily();
|
$schedule->job(new VersionCheck)->daily()->withoutOverlapping();
|
||||||
|
|
||||||
$schedule->command('ninja:check-data')->daily();
|
$schedule->command('ninja:check-data')->daily()->withoutOverlapping();
|
||||||
|
|
||||||
$schedule->job(new ReminderJob)->daily();
|
$schedule->job(new ReminderJob)->daily()->withoutOverlapping();
|
||||||
|
|
||||||
$schedule->job(new CompanySizeCheck)->daily();
|
$schedule->job(new CompanySizeCheck)->daily()->withoutOverlapping();
|
||||||
|
|
||||||
$schedule->job(new UpdateExchangeRates)->daily();
|
$schedule->job(new UpdateExchangeRates)->daily()->withoutOverlapping();
|
||||||
|
|
||||||
$schedule->job(new RecurringInvoicesCron)->hourly();
|
$schedule->job(new RecurringInvoicesCron)->hourly()->withoutOverlapping();
|
||||||
|
|
||||||
/* Run hosted specific jobs */
|
/* Run hosted specific jobs */
|
||||||
if (Ninja::isHosted()) {
|
if (Ninja::isHosted()) {
|
||||||
$schedule->job(new AdjustEmailQuota())->daily();
|
$schedule->job(new AdjustEmailQuota())->daily()->withoutOverlapping();
|
||||||
$schedule->job(new SendFailedEmails())->daily();
|
$schedule->job(new SendFailedEmails())->daily()->withoutOverlapping();
|
||||||
}
|
}
|
||||||
/* Run queue's in shared hosting with this*/
|
/* Run queue's in shared hosting with this*/
|
||||||
if (Ninja::isSelfHost()) {
|
if (Ninja::isSelfHost()) {
|
||||||
$schedule->command('queue:work')->everyMinute()->withoutOverlapping();
|
$schedule->command('queue:work')->everyMinute()->withoutOverlapping();
|
||||||
$schedule->command('queue:restart')->everyFiveMinutes(); //we need to add this as we are seeing cached queues mess up the system on first load.
|
$schedule->command('queue:restart')->everyFiveMinutes()->withoutOverlapping(); //we need to add this as we are seeing cached queues mess up the system on first load.
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -61,6 +61,7 @@ class ClientContact extends Authenticatable implements HasLocalePreference
|
|||||||
'updated_at' => 'timestamp',
|
'updated_at' => 'timestamp',
|
||||||
'created_at' => 'timestamp',
|
'created_at' => 'timestamp',
|
||||||
'deleted_at' => 'timestamp',
|
'deleted_at' => 'timestamp',
|
||||||
|
'last_login' => 'timestamp',
|
||||||
];
|
];
|
||||||
|
|
||||||
protected $hidden = [
|
protected $hidden = [
|
||||||
|
@ -99,6 +99,8 @@ class RecurringInvoice extends BaseModel
|
|||||||
'amount',
|
'amount',
|
||||||
'partial',
|
'partial',
|
||||||
'frequency_id',
|
'frequency_id',
|
||||||
|
'next_send_date',
|
||||||
|
'remaining_cycles',
|
||||||
];
|
];
|
||||||
|
|
||||||
protected $casts = [
|
protected $casts = [
|
||||||
|
@ -136,6 +136,7 @@ class RecurringInvoiceTransformer extends EntityTransformer
|
|||||||
'remaining_cycles' => (int) $invoice->remaining_cycles,
|
'remaining_cycles' => (int) $invoice->remaining_cycles,
|
||||||
'recurring_dates' => (array) $invoice->recurringDates(),
|
'recurring_dates' => (array) $invoice->recurringDates(),
|
||||||
'auto_bill' => (string) $invoice->auto_bill,
|
'auto_bill' => (string) $invoice->auto_bill,
|
||||||
|
'auto_bill_enabled' => (bool) $invoice->auto_bill_enabled,
|
||||||
'due_date_days' => (string) $invoice->due_date_days ?: '',
|
'due_date_days' => (string) $invoice->due_date_days ?: '',
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
@ -48,7 +48,8 @@ class AddIsPublicToDocumentsTable extends Migration
|
|||||||
});
|
});
|
||||||
|
|
||||||
Schema::table('recurring_invoices', function ($table) {
|
Schema::table('recurring_invoices', function ($table) {
|
||||||
$table->boolean('auto_bill')->default(0);
|
$table->string('auto_bill')->default('off');
|
||||||
|
$table->boolean('auto_bill_enabled')->default(0);
|
||||||
$table->unsignedInteger('design_id')->nullable();
|
$table->unsignedInteger('design_id')->nullable();
|
||||||
$table->boolean('uses_inclusive_taxes')->default(0);
|
$table->boolean('uses_inclusive_taxes')->default(0);
|
||||||
$table->string('custom_surcharge1')->nullable();
|
$table->string('custom_surcharge1')->nullable();
|
||||||
|
Loading…
Reference in New Issue
Block a user