我的视图中有以下代码
@(Html.Telerik().Grid<DatabaseModel.RMAItemModel>()
.Name("RMAItemsGrid")
.DataKeys(keys => keys.Add(u => u.RmaID).RouteKey("RmaID"))
.DataBinding(dataBinding => dataBinding.Ajax().Select("SelectRMAItemList", "Order"))
.Columns(columns =>
{
var ids = "";
columns.Bound(o => o.RmaItemNo).Hidden(true);
columns.Template(@<text>@{ids = item.RmaID.ToString();}</text>).Hidden(true);
columns.Bound(o => o.RefundType).Title("Refund Type").ClientTemplate(Html.Telerik().DropDownList().Name("RefundType<#= RmaItemNo #>").BindTo(CommonService.GetListItems(31, ids.ToString(), 0, "Refund", false)).HtmlAttributes(new { style = "width:200px" }).ToHtmlString()).Filterable(false).Sortable(false);
}
在RefundType列的ClientTemplate我调用Telerik DropDownList 在下拉列表中我调用函数CommonService.GetListItems (31, * ids.ToString( ) 或<#=RefundType#> , 0, "Refund", false) *
我想将RefundType列值分配给ids ,或者我需要将RefundType列值直接分配到
CommonService.GetListItems (31, ids.ToString( ) 或<#=RefundType#> , 0, "Refund", false)
我无法将列值传递给函数
CommonService.GetListItems(31, ids.ToString(), 0, "退款", false)
我想传递 Column 值而不是id