如果datagrid要模拟选中行的效果,不能用selectRow,这个是返回数据
要返回行样式用:
var rowIndex = $("#smsCaseList").datagrid('getRowIndex',id); //获取当前记录所在索引
$('#smsCaseList').datagrid('selectRecord', rowIndex);
本文介绍了一种在datagrid中实现选中行效果的方法。通过使用特定的API,可以不返回数据而是更改行的样式来达到模拟选中行的目的。
如果datagrid要模拟选中行的效果,不能用selectRow,这个是返回数据
要返回行样式用:
var rowIndex = $("#smsCaseList").datagrid('getRowIndex',id); //获取当前记录所在索引
$('#smsCaseList').datagrid('selectRecord', rowIndex);

被折叠的 条评论
为什么被折叠?