最近在做一个管理系统,出于一些需要,经常要将一些datagrid清空.然后easyUI本身并没有自带的方法,然后自己动手丰衣足食吧. 清空无外乎两种思路,删除现有数据和填充空数据. 1.删除数据 var rows = $(id).datagrid('getRows'); for(var i=rows.length-1;i>=0;i--){ var index = $('#dg_careersystem').datagrid('getRowIndex', rows[i]); console.log…
» Create column groups in DataGrid The easyui DataGrid has ability to group columns, as the following example shows: View Demo In this example, we use flat data to populate the DataGrid data, and group the listprice,unitcost,addr1,status columns unde…