Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Getting Cron Expression from Later.js

We are storing schedules as cron expressions in database. The schedules are modified in a web page and I'm using Later.js for this. Works great to parse the Cron expression. Now I would like to output the modified schedule to a Cron expression that can be stored in database.

Is there any "toCronExpression" function in Later.js?

I know I can read the properties of the schedule object and output them myself but I was hoping for a built in function.

like image 923
Andreas Avatar asked Mar 02 '17 07:03

Andreas


1 Answers

There is currently no such functionality to generate cron expressions in Later.js. All cron-related functionality has to do with parsing cron expressions, not generating them. You can confirm this by looking at all usages of the word cron in the master branch of the Later.js repository on GitHub. Here is a link to the search:

https://github.com/bunkat/later/search?p=1&q=cron&type=&utf8=%E2%9C%93

like image 78
JMA Avatar answered Nov 07 '22 15:11

JMA