0

我正在使用 Html.Kendo().Grid 并且我的列定义如下:

columns.Bound(t => t.DateTimeProperty).ClientTemplate("#= kendo.toString(DateTimeProperty<br>? DateTimeProperty : '" + @T("Common_None") + "', 'MM/dd/yyyy') #").Width(130);

它渲染得很好,但它实际上比正确的一天晚了一天。例如:它会显示 2/24/2013,但实际日期是 2/25/2013。

有什么建议么?

4

1 回答 1

1

The most likely reason for a different date to be shown is the automatic conversion of the browsers and a different timezone. Please check this code-library which demonstrates how to use UTC both on the server and on the client so the same date is displayed and saved.

于 2013-05-06T07:09:30.380 回答