1
这里是我的网是什么样子:添加下拉菜单剑道UI电网编辑模式 - C#MVC
@(Html.Kendo().Grid(Model).Name("Short-Grid").TableHtmlAttributes(new { @class = "short-duration-grid" })
.Columns(col =>
{
//Commands btn
col.Command(command =>
{
command.Edit().HtmlAttributes(new { title = "Assign Analyst" }).CancelText("");
command.Custom("Close").HtmlAttributes(new { title = "Close Attack" });
});
col.Bound(c => c.SDHandledBy).Title("User");
})
.Editable(editable => editable.TemplateName("AttackViewModel").Mode(GridEditMode.InLine))
.Scrollable(o => o.Height(height))
.HtmlAttributes(new { style = "height:700px;" })
.DataSource(dataSource => dataSource
.Ajax()
.PageSize(20)
.Events(events => events.Error("error_handler"))
.Model(model => model.Id(o => o.AttackID))
.Model(model => model.Field(f => f.SDHandledBy).Editable(true))
.Create(update => update.Action("EditingInline_Create", "Grid"))
.Update(update => update.Action("Update", "ShortDuration"))
.Read(read => read.Action("EditingInline_Read", "Grid"))
.Destroy(update => update.Action("EditingInline_Destroy", "Grid"))
)
.Sortable()
.Groupable()
.Filterable()
)
我想在编辑模式下,以“用户”列中添加下拉菜单。 我在viewbag中有用户的相关数据。
如何更改代码,并使该列与viewbag中的数据一起显示为下拉菜单?
这可能吗?如果没有,请帮助我解释什么是最好的方法。