87,838
社区成员




<table class="easyui-datagrid" title="文档列表" id="dg" pagination="true" style="height:98%"
data-options="toolbar:'#ft',
pagination:true,
pageSize:10
">
<thead>
<tr>
<th data-options="field:'wordname',width:180,halign:'center'">文档名称</th>
<th data-options="field:'wordtype',width:100,halign:'center',align:'center'">文档类型</th>
<th data-options="field:'createtime',width:150,halign:'center',align:'center'">上传时间</th>
<th data-options="field:'createby',width:180,halign:'center',align:'center'">上传用户</th>
<th field="opt" formatter='optFormater' width="150" halign="center" align="center">操作</th>
</tr>
</thead>
</table>
//DataGrid操作栏
function optFormater(value, row, index) {
var wordId = row.id;
var wordurl = row.wordurl;
var wordname = row.wordname;
var del = '<a href="WordList!deleteData.action?wordname=' + encodeURI(encodeURI(wordname)) + '&id=' + wordId + '&url=' + wordurl
+ '" onclick="return confirm(' + "'确定删除?'" + ');">删除</a> | ';
var preview = '<a href="documentView.jsp?url=' + wordurl
+ '" target="_bank">预览</a>';
return del + preview;
}
{field:'opt',title:'修改',width:100,align:'center', rowspan:2,
formatter:function(value,rec,index){
var e = '<span style="color:blue;"><a href="javascript:void(0);" style="text-decoration: none;font-weight:bold;" onclick="edit(\''+rec.id+'\')">编辑</a></span>';
return e;
}
}