@{
ViewBag.Title = "EasyUI";
Layout = null;
}
<script src="~/jquery-easyui-1.5.5.2/jquery.min.js"></script>
<script src="~/jquery-easyui-1.5.5.2/jquery.easyui.min.js"></script>
<script src="~/jquery-easyui-1.5.5.2/locale/easyui-lang-zh_CN.js"></script>
<link href="~/jquery-easyui-1.5.5.2/themes/default/easyui.css" rel="stylesheet" />
<link href="~/jquery-easyui-1.5.5.2/themes/icon.css" rel="stylesheet" />
<h2>EasyUI</h2>
<div>
<!--DataGrid-->
<div style="margin:20px">
<table class="easyui-datagrid" fitColumns="true" rownumbers="true" singleSelect="true" title="第一个Datagrid" style="width:300px;height:auto">
<thead>
<tr>
<th align="center" width="100px" data-options="field:'Name'">姓名</th>
<th align="center" width="100px" data-options="field:'Age'">年龄</th>
<th align="center" width="100px" data-options="field:'Work'">工作</th>
</tr>
</thead>
<tbody>
<tr>
<td>张三</td>
<td>11</td>
<td>C#</td>
</tr>
<tr>
<td>李四</td>
<td>11</td>
<td>java</td>
</tr>
<tr>
<td>王五</td>
<td>11</td>
<td>php</td>
</tr>
</tbody>
</table>
</div>
</div>

第二种写法(js):

$('#dg').datagrid({
url:'datagrid_data.json',
columns:[[
{field:'code',title:'Code',width:100},
{field:'name',title:'Name',width:100},
{field:'price',title:'Price',width:100,align:'right'}
]]
});

  

最新文章

  1. 日常积累之JSON.stringify和JSON.parse substr
  2. Oracle Redo Log 机制 小结(转载)
  3. c++ 私有函数 头文件设计
  4. 小波变换和motion信号处理(二)(转)
  5. 导入表 IMPORT_DESCRIPTOR
  6. hdu3849-By Recognizing These Guys, We Find Social Networks Useful:双连通分量
  7. 谁能告诉我为什么sum_area输出总是0(多边形重心问题)
  8. android压缩解压zip文件
  9. 对eigrp默认网络的理解!
  10. 201521123114 《Java程序设计》第11周学习总结
  11. 【vue】函数式组件
  12. 网络流问题 P2763 试题库问题
  13. step_by_step_记录deepin下curl安装过程
  14. python高级-面向对象(11)
  15. Linux电源管理(7)_Wakeup events framework【转】
  16. Maven的assembly插件实现自定义打包部署(包含依赖jar包)
  17. 使用Pyspark进行特征工程时的那些坑
  18. python正则表达式二[转]
  19. IOS tableview 横向滚动
  20. CRF 及CRF++ 安装与解释

热门文章

  1. Java中volatile如何保证long和double的原子性操作
  2. Spring data jpa persistence .xml 配置文件
  3. doT模板引擎
  4. express设置允许跨域访问该服务.
  5. 【Java架构:基础技术】一篇文章搞掂:MyBatis-Plus
  6. ICO和区块链区别
  7. TIOBE 编程语言排行榜是什么,它是如何计算编程语言排行的?
  8. java并发编程笔记(二)——并发工具
  9. docker内的服务无法获取用户真实IP
  10. JDK动态代理源码剖析