0
當我想編輯劍道網格內的日期並不在IE中顯示日期時間選擇器,而其鍍鉻做工精細MVC劍道網格顯示完整的日期在IE編輯模式下僅
@(Html.Kendo().Grid<Models.Person>().Name("people")
.DataSource(dataSource => dataSource
.Ajax()
.Model(model =>
{
model.Id(m => m.PersonID);
model.Field(f => f.Name);
})
.Read(read => read.Action("GetPeople", "Home").Data("extraData"))
.Update(up => up.Action("UpdatePerson", "Home"))
)
.Columns(columns =>
{
columns.Bound(c => c.PersonID);
columns.Bound(c => c.Name);
columns.Bound(k => k.BirthDate).Format("{0:dd.MM.yyyy}");
columns.Command(cmd => cmd.Edit());
})
.Events(ev => ev.DataBound("db"))
)
see result 我使用ASP.NET5 RC1 MVC
<script src="~/lib/kendo-ui/js/cultures/kendo.culture.es-MX.min.js"></script>
<script>
kendo.culture("es-MX");
</script>
模型.....
public class Person
{
public int PersonID { get; set; }
public string Name { get; set; }
[DataType(DataType.Date)]
public Nullable<DateTime> BirthDate { get; set; }
}