stormseed / daykeep-calendar-quasar

A full event display calendar for the Quasar framework that has multiple viewing formats.
MIT License
270 stars 71 forks source link

Question - Show events in calendar aftter load page f5 using vuex #20

Open silvestreR opened 6 years ago

silvestreR commented 6 years ago

Hi! i have a problem in calendar on display event after reload page f5 and after create new event and close my custom modal. When i create a variable 'events' in data, and set the event object manualy worked perfectly. But, i'm using vuex, and flux is this : I'm call FetchSchedulings from my API in Mounted. Then i set the array of the events, in store. In Computed i return my event list objects they aren't show in my calendar, but if i clicked in other route and return in my route then are load perfectly. whats wrong ?

image

image

before f5. image

After f5 image

thank you!

lucastafarelbs commented 6 years ago

and now, did it work? already managed to solve? @AtSilvestre ?

sirbeagle commented 6 years ago

I wonder if we need to add a watch for eventArray in Calendar.vue. The events array needs to be parsed anytime it changes and it's that parsed version that gets passed to the monthly and multi-day calendars.

silvestreR commented 6 years ago

I solved, putting a 'if' in call to the calendar in my component, so the calendar is rendered only when my data in my events array will exists. thank you for attention and congrats for the component