EasyUI 相关
根据关键字值取行
var rowIndex = $('#tt').datagrid('getRowIndex', id);//id是关键字值
var data = $('#tt').datagrid('getData').rows[rowIndex];
var oname = data.operator;//operator是属性值
datagrid editor 日期格式
<table id="dg2" class="easyui-datagrid" style="width:100%;" idfield="detailinvid" toolbar="#ltb" rownumbers="true" nowarp="false" singleSelect="true" iconCls="icon-save" nowrap="false"> <thead> <tr> <th data-options="field:'invname',width:100">名称</th> <th data-options="field:'require',width:150">要求</th> <th data-options="field:'unit',width:80" editor="{type:'textbox'}" >单位</th> <th data-options="field:'detailqty',width:70">数量</th> <th data-options="field:'requiredate',width:100 " editor="{type:'datebox',options: { editable: false,formatter:myformatter,parser:myparser}}">要求完工日期</th> <th data-options="field:'memo',width:90" editor="{type:'textbox'}">备注</th> <th data-options="field:'detailinvid',hidden:'true'"></th> <c:if test="${isview=='0'}"> <th data-options="field:'operupd',width:100" align="center" formatter="formatAction">操作</th> </c:if> </tr> </thead> </table>

浙公网安备 33010602011771号