Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Match between 2 dates #87

Open
indieocean opened this issue Nov 20, 2017 · 1 comment
Open

Match between 2 dates #87

indieocean opened this issue Nov 20, 2017 · 1 comment

Comments

@indieocean
Copy link

Is there a way to match if the recurrence is between two dates? Begin - End Date

Let's says you have a recurrence for every month and you want to show the recurrences for that specific month. Right now the matches only accepts one date.

@bradisson
Copy link

bradisson commented Dec 15, 2017

Once you define your schedule rule, you can get/set the start and end date of the recurrence.

In your case you have

var recur = moment().recur().every(15).dayOfMonth() (occure every 15th day of every month)

Then you can set start and end date to the begining and the end of the month

var decemberOccurrence = recur.startDate("12/01/2017").endDate("12/31/2017").all()

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants