Full Calendar MVC

I use fullcalendar plugin with mvc.
I knew my MVC API is working and return data. But I do not see the return data on the calendar.
What did i do wrong in Event Push in Jquery?


<script>
        function Can() {
            $('#calendar').fullCalendar({
                header:
                {
                        left: 'prev,next today',
                        center: 'title',
                        right: 'month,basicWeek,basicDay'
                    },
                buttonText: {
                    today: 'today',
                    month: 'month',
                    week: 'week',
                    day: 'day'
                },
                views: {
                    basicWeek: {
                        type: 'basic',
                        duration: { months: 3 },
                        rows: 8
                    }
                },
                events: function (start, end, timezone, callback) {
                    $.ajax({
                        url: '/Park/bookinglist',
                        type: "Post",
                        dataType: "JSON",
                        success: function (result) {
                         var events = [];
                         $.each(result, function (i, data) {
                             //alert(data.ParkProductInventoryCustomNo);
                               events.push(
                               {
                                   title: "test",
                                   description: data.ParkProductInventoryCustomNo,
                                   start: moment(data.CheckIn).format('YYYY-MM-DD'),
                                   end: moment(data.CheckOut).format('YYYY-MM-DD'),
                                   backgroundColor: "#9501fc",
                                   borderColor: "#fc0101"
                               });
                            });
                            callback(events);
                        }
                    });
                },
                eventRender: function (event, element) {
                    element.qtip(
                    {
                        content: event.description
                    });
                },
                editable: false
            });
        }
</script>

Open in new window

LVL 1
ITsolutionWizardAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Robb HillSenior .Net Full Stack DeveloperCommented:
Put some alerts in your call so you can see where it executes.

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Robb HillSenior .Net Full Stack DeveloperCommented:
success: function (data) {                        
var events = $.map(data.d, function (item, i) {
   var event = new Object();
   //load up event
   return event;
});
});

Open in new window

ITsolutionWizardAuthor Commented:
sorry I don't get it.
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
.NET MVC

From novice to tech pro — start learning today.