increment copyright date to 2022, allow scheduled jobs to support weekly interval, improve dynamic image generation, add defensive logic to router
This commit is contained in:
@ -158,6 +158,14 @@ namespace Oqtane.Infrastructure
|
||||
nextExecution = nextExecution.Date.Add(job.StartDate.Value.TimeOfDay);
|
||||
}
|
||||
break;
|
||||
case "w": // weeks
|
||||
nextExecution = nextExecution.AddDays(job.Interval * 7);
|
||||
if (job.StartDate != null && job.StartDate.Value.TimeOfDay.TotalSeconds != 0)
|
||||
{
|
||||
// set the start time
|
||||
nextExecution = nextExecution.Date.Add(job.StartDate.Value.TimeOfDay);
|
||||
}
|
||||
break;
|
||||
case "M": // months
|
||||
nextExecution = nextExecution.AddMonths(job.Interval);
|
||||
if (job.StartDate != null && job.StartDate.Value.TimeOfDay.TotalSeconds != 0)
|
||||
|
Reference in New Issue
Block a user