How to pass a onSelectSlot values from Big Calendar

时间:2019-04-08 13:00:15

标签: reactjs graphql

I having a BigCalendar component on my react aplication, i using graphql on the server side, now i'm trying to add a kind of 'reservation' on a day the user select. The big calendar had a {slot} object that returns the Date the use clicked on the calendar, but im having dificulties passing those values to a usable way.

On my calendar component i had the onSelectSlot calling a function with

onSelectSlot={handleClickDay}

That calls the handleClickDay on another file, executing like this

handleClickDay = () => { this.setState({ open: true }) }

Opening a modal to fill a form to my reservation. But i cant find a way to pass that slots object to the modal and save with the form

I need the form to receive the slots day from the slot the user clicked and send that to a mutation with the form the user provide.

0 个答案:

没有答案