laravel-calendar-events
laravel-calendar-events copied to clipboard
Work with multiple events
Hi, I was looking to use your excellent package but I don't understand how you can implement a search with multiple events.
I explain: you have provided this method:
$event->getEventsBetween('2021-01-05', '2021-01-15');
With this I can retrieve all the recurrences between two dates of that particular event.
But what if I have multiple events with multiple recurrences each and I want to retrieve all the events (or recurrences of those events) beetwen two dates?
Something like this:
$collectionOfEvents->getEventsBetween('2021-01-05', '2021-01-15');
I also would like to ask you if you could provide an example with laravel and an interaction with a db.
Thank you in advance :)
Try default Eloquent where clause for multiple events.
Are there any examples of such a query? For example, most calendar implementations just show a month/week/day at time, which fetches through specific dates (that current month for example). How can you create a query that accounts for events created in the past, that are recurring, and should show up in the current set of dates?