您的位置:首页 > 产品设计 > UI/UE

easyUI datagrid显示摘要信息在页脚

2012-08-11 10:37 260 查看
@author YHC

在这个教程中,我们将告诉你如何显示摘要信息行在datagrid页脚.



查看 Demo

显示页脚行,你应该设置showFooter 属性为true,然后准备页脚行定义在datagrid的数据,以下是示例数据.

{"total":1,"rows":[{"id":1,"name":"Chai","price":18.00}],"footer":[{"name":"Total","price":18.00}]}



创建DataGrid

<table id="tt" title="DataGrid" class="easyui-datagrid" style="width:400px;height:250px"
url="data/datagrid17_data.json"
fitColumns="true" rownumbers="true" showFooter="true">
<thead>
<tr>
<th field="name" width="80">Product Name</th>
<th field="price" width="40" align="right">Unit Price</th>
</tr>
</thead>
</table>
页脚行和显示数据行一样,所以你可以显示不止一个摘要信息在页脚.


下载 EasyUI 示例:

easyui-datagrid-demo.zip
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: