Scheduler : No Data transferred when Update

2 posts, 0 answers
  1. Bruno
    Bruno avatar
    7 posts
    Member since:
    Jan 2013

    Posted 12 Jun 2017 Link to this post

    Hi,

    I've create a task sheduler. Read and create are working fine ( data are created in database with a generated Guid: oid) but when I try to update my task I've got an Internal error 500 visible on my Chrome developper console. In effect No data are sent !

    Did I forgot something?

    Please see my code:

    @(Html.Kendo().Scheduler<Elearning.ViewModels.TasksViewModel>()
    .Name("scheduler")
    .Date(DateTime.Today)
    .StartTime(new DateTime(DateTime.Now.Year, DateTime.Now.Month, DateTime.Now.Day, 6, 0, 0))
    .DateHeaderTemplate("<span class='k-link k-nav-day'>#=kendo.toString(date, 'ddd dd/M')#</span>")
    .Height(480)
    .Views(views =>
    {
        views.DayView();
        views.WorkWeekView(workWeekView => workWeekView.Selected(true));
        views.WeekView();
        views.MonthView();
        //views.AgendaView();
        //views.TimelineView();
    })
            .Resources(resource =>
            {
                resource.Add(m => m.CoursID)
                    .Title("Leçon")
                    .DataTextField("Text")
                    .DataValueField("Value")
                    .DataColorField("Group.Name")
                    .BindTo(Model.Lessons);
            })
                    .DataSource(d => d
                        .Model(m => {
                            m.Id(f => f.oid);
                            m.Field(f => f.oid).DefaultValue(new Guid());
                            m.Field(f => f.Title);
                            m.Field(f => f.Start);
                            m.Field(f => f.End);
                            m.Field(f => f.StartTimezone);
                            m.Field(f => f.EndTimezone);
                            m.Field(f => f.IsAllDay);
                            m.Field(f => f.Description);
                            m.Field(f => f.RecurrenceRule);
                            m.Field(f => f.RecurrenceException);
                            m.Field(f => f.RecurrenceID);
                            m.Field(f => f.UtilisateurID).DefaultValue(UserContext.CurrentUser.oid);
                            m.Field(f => f.CoursID);
                        })
                      .Read("Read", "Tasks")
                      .Create("Create", "Tasks")
                      .Update("Update", "Tasks")
                      .Destroy("Destroy", "Tasks")
                      )
       
                )
  2. Plamen
    Admin
    Plamen avatar
    2960 posts

    Posted 14 Jun 2017 Link to this post

    Hello,

    From the provided code it is not clear what may be breaking the functionality at your side. You can check for several working examples at our local demos or at our ui-for-aspnet-mvc-examples repository and check what is different in your case.

    Regards,
    Plamen
    Progress Telerik
    Try our brand new, jQuery-free Angular 2 components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
Back to Top