最近开发一个项目是用的easyui框架,由于美观考虑,需要将datagrid实现右侧操作列冻结(数据列太多必须横向滚动).查了下官方API只有冻结列,但是都是冻结左侧列的实例,于是百度走一波.
不啰嗦,直接上代码.
<style>
.datagrid-view1 {
left: auto;
right: 0;
}
.datagrid-view2 {
left: 0;
right: auto;
}
</style>
<thead>
<tr>
<th width="10px" data-options="field:'id', align:'center', hidden:true">ID</th>
<th width="110px" data-options="field:'name', align:'left', halign:'center'">名称</th>
<th width="116px" data-options="field:'state', align:'left', halign:'center'">状态</th>
<th width="120px" data-options="field:'memo', align:'left', halign:'center',formatter:escapeHtml">备注</th>
</tr>
</thead>
<thead frozen="true">
<tr>
<th width="130px" data-options="field:'operate2', align:'center', halign:'center', formatter:InputAction">操作</th>
</tr>
</thead>

2033

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



