简单的说,Kendo UI 网页对任何可以支持的框架开放javascript
/jQuery
but Kendo UI 服务器包装器/Kendo UI ASP.NET for MVC is for ASP.NET MVC
仅项目。
使用 Kendo UI Web 需要大量额外的编码和处理,而
MVC版本对开发人员更友好并且更易于维护。如果您正在开发 ASP.NET MVC 项目,那么您可以使用服务器包装器简化编码。
Kendo UI Web 可以免费使用,而服务器包装器(ASP.NET MVC 的 Kendo UI)需要为每个开发人员付费许可。
剑道网格的代码差异的简单示例如下:
与服务器包装器
@model IEnumerable<Kendo.Mvc.Examples.Models.ProductViewModel>
@(Html.Kendo().Grid(Model)
.Name("Grid")
.Columns(columns =>
{
columns.Bound(p => p.ProductID).Groupable(false);
columns.Bound(p => p.ProductName);
columns.Bound(p => p.UnitPrice);
columns.Bound(p => p.UnitsInStock);
})
.Groupable()
.Pageable()
.Sortable()
.Scrollable()
.Filterable()
.DataSource(dataSource => dataSource
.Ajax()
.Read(read => read.Action("Products_Read", "Grid"))
)
)
与 Kendo UI Web
<script>
$(document).ready(function() {
$("#grid").kendoGrid({
dataSource: {
data: createRandomData(50),
pageSize: 10
},
groupable: true,
sortable: true,
pageable: {
refresh: true,
pageSizes: true
},
columns: [ {
field: "FirstName",
width: 90,
title: "First Name"
} , {
field: "LastName",
width: 90,
title: "Last Name"
} , {
width: 100,
field: "City"
} , {
field: "Title"
} , {
field: "BirthDate",
title: "Birth Date",
template: '#= kendo.toString(BirthDate,"dd MMMM yyyy") #'
} , {
width: 50,
field: "Age"
} ]
});
});
</script>
您可以检查渲染的网格here http://demos.kendoui.com/web/grid/index.html.
有关更多详细信息服务器包装器 http://www.kendoui.com/server-wrappers/mvc.aspx and Kendo UI 网页 http://www.kendoui.com/web.aspx.