I have been stuck with this problem without much luck. I've gone down multiple paths and done google search but can’t seem to find a solution that works. Any help would be greatly appreciated.
I am using Kendo MVC grid wired up for CRUD.
@model IEnumerable<CustomerModels>
@(Html.Kendo().Grid(Model)
.Name("grid")
.Columns(columns =>
{
columns.Bound(Customer => Customer.Name);
columns.Bound(Customer => Customer.Number);
columns.Bound(Customer => Customer.Phone);
columns.Bound(Customer => Customer.DOB).Format("{0:d}").EditorTemplateName("Date");
columns.Command(command => { command.Edit(); });
})
.DataSource(dataSource => dataSource
.Ajax()
.PageSize(20)
.Read(read => read.Action("FilterMenuCustomization_Read", "Home"))
.Model(model => { model.Id(c => c.Phone); model.Field(c=>c.DOB);})
.Update(update => update.Action("FilterMenuCustomization_Update", "Home"))
)
.Pageable()
.Sortable()
)
When i try to edit the date field using Date Picker or even without any change to existing date, If i try to submit It gives me Error message as "DOB is not valid date".
Ex. 25/07/2013
I have included Culture and EditorTemplates as mentioned in some of the solutions i found on internet, But no help.
Any idea as to what i am doing wrong?
I am using Kendo MVC grid wired up for CRUD.
@model IEnumerable<CustomerModels>
@(Html.Kendo().Grid(Model)
.Name("grid")
.Columns(columns =>
{
columns.Bound(Customer => Customer.Name);
columns.Bound(Customer => Customer.Number);
columns.Bound(Customer => Customer.Phone);
columns.Bound(Customer => Customer.DOB).Format("{0:d}").EditorTemplateName("Date");
columns.Command(command => { command.Edit(); });
})
.DataSource(dataSource => dataSource
.Ajax()
.PageSize(20)
.Read(read => read.Action("FilterMenuCustomization_Read", "Home"))
.Model(model => { model.Id(c => c.Phone); model.Field(c=>c.DOB);})
.Update(update => update.Action("FilterMenuCustomization_Update", "Home"))
)
.Pageable()
.Sortable()
)
When i try to edit the date field using Date Picker or even without any change to existing date, If i try to submit It gives me Error message as "DOB is not valid date".
Ex. 25/07/2013
I have included Culture and EditorTemplates as mentioned in some of the solutions i found on internet, But no help.
Any idea as to what i am doing wrong?