Page 1 of 1

[ANGULAR] what is the best way to fetch the data from API and load the calendar with monthly data.

Posted: Thu Jan 20, 2022 11:44 am
by ashokkumar.b

I want to fetch API data anad load the monthly calendar, how to trigger api call with change of month in calendar and store data.


Re: [ANGULAR] what is the best way to fetch the data from API and load the calendar with monthly data.

Posted: Thu Jan 20, 2022 1:16 pm
by Animal

If you are using the provided CrudManager, then https://www.bryntum.com/docs/calendar/api/Calendar/feature/LoadOnDemand would be the way to go.

If you are doing this yourself, listen for this event: https://www.bryntum.com/docs/calendar/api/Calendar/view/Calendar#event-dateRangeChange


Re: [ANGULAR] what is the best way to fetch the data from API and load the calendar with monthly data.

Posted: Thu Jan 20, 2022 5:28 pm
by ashokkumar.b

currently I am assigning events, resources and assignments after getting data from API. If that is the case, I believe in this case I can write an event to load api data with CrudManager, and then form the resources, events and assignments.

Can I still use crud manager and get the data outside the CrudManager?


Re: [ANGULAR] what is the best way to fetch the data from API and load the calendar with monthly data.

Posted: Thu Jan 20, 2022 7:19 pm
by Animal

If you are getting the data, don't use CrudManager, just a Project to manage the Stores.


Re: [ANGULAR] what is the best way to fetch the data from API and load the calendar with monthly data.

Posted: Fri Jan 28, 2022 3:58 pm
by ashokkumar.b

thanks Anima, that helps!