Asp.net mvc 4 默认情况下,剑道网格中不显示任何列,当我从ColumnMenu中选择column时,是否只在网格中显示所选列的数据?

Asp.net mvc 4 默认情况下,剑道网格中不显示任何列,当我从ColumnMenu中选择column时,是否只在网格中显示所选列的数据?,asp.net-mvc-4,kendo-grid,Asp.net Mvc 4,Kendo Grid,这是我的网格代码 @(Html.Kendo().Grid()) .Name(“网格”).HtmlAttributes(新的{style=“height:600px;”) .EnableCustomBinding(真) .列(列=> { columns.Bound(p=>p.VendorCode).Title(“供应商代码”).Width(150).HeaderHtmlAttributes(新的{style=“font-weight:bold;”); columns.Bound(p=>p.Ven

这是我的网格代码

@(Html.Kendo().Grid())
.Name(“网格”).HtmlAttributes(新的{style=“height:600px;”)
.EnableCustomBinding(真)
.列(列=>
{
columns.Bound(p=>p.VendorCode).Title(“供应商代码”).Width(150).HeaderHtmlAttributes(新的{style=“font-weight:bold;”);
columns.Bound(p=>p.VendorName).Title(“供应商名称”).Width(250).HeaderHtmlAttributes(新的{style=“font-weight:bold;”);
columns.Bound(p=>p.BuyerName).Title(“买方名称”).Width(150).HeaderHtmlAttributes(新的{style=“font-weight:bold;”“});
columns.Bound(p=>p.CommodityCode).Title(“商品代码”).Width(200).HeaderHtmlAttributes(新的{style=“font-weight:bold;”);
columns.Bound(p=>p.IncludeInReport).Title(“包含在报告中”).Width(180).HeaderHtmlAttributes(新的{style=“font-weight:bold;”);
})
.ToolBar(ToolBar=>
{
toolbar.Create().HtmlAttributes(新的{@class=“btn btn info”});
toolbar.Custom().Text(“下载模板”).Name(“Vtemplate”).Action(“DownloadVendorBlank_模板”,“设置”).HtmlAttributes(新建{Id=“Vtemplate”,title=“下载通过excel导入数据的模板”,@class=“btn btn info”});
toolbar.Custom().Text(“导入Excel”).Name(“导入Excel”).HtmlAttributes(新的{Id=“导入Excel”,title=“通过Excel导入供应商”,@class=“btn btn info”});
})
.Excel(Excel=>Excel
.FileName(“Vendors.xlsx”)
.可过滤(真)
)
.Editable(可编辑=>Editable.Mode(GridEditMode.InLine))
.Pageable(Pageable=>Pageable
.刷新(真)
.页面大小(真)
.按钮计数(5))
.Scrollable(排序=>sorting.Enabled(true))
.可调整大小(m=>m.Columns(true))
.column菜单()
.Reorderable(m=>m.Columns(true))
.可过滤()
.DataSource(DataSource=>DataSource
.Ajax()
.ServerOperation(错误)
.Events(Events=>Events.Error(“错误处理程序”))
.Read(Read=>Read.Action(“供应商读取”、“设置”))
)
)
默认情况下,在网格中隐藏/(不显示)列,然后必须在每列设置.Hidden(true)

i、 e-columns.Bound(c=> c、 国家)。标题(“国家”)。宽度(150)。隐藏(真)

当您在列菜单过滤器中看到复选框列表时,您可以再次选择该列作为网格中的视图。

默认情况下,在网格中隐藏/(不显示)列,然后您必须在每列设置.Hidden(true)

i、 e-columns.Bound(c=> c、 国家)。标题(“国家”)。宽度(150)。隐藏(真)

当您在列菜单过滤器中看到复选框列表时,您可以再次选择该列作为网格中的视图