【发布时间】:2016-12-18 16:53:55
【问题描述】:
我正在使用数据表 1.10.13 服务器端处理。我想添加一个带有编辑用户链接的“编辑”列。这个怎么做?
我的 js 文件
$('#userTable').DataTable( {
"processing": true,
"serverSide": true,
"ajax": {
"type": "GET",
"url": "",
"dataSrc": "data",
"contentType": "application/json; charset=utf-8",
"dataType": "json",
"processData": true
},
"columns": [
{ "data": "id" },
{ "data": "email" },
{ "data": "" }, //edit link column
]
} );
数据表查看php
<table cellspacing="0" id="userTable" class="display">
<thead>
<tr>
<th class="ui-state-default">Name</th>
<th class="ui-state-default">Email</th>
<th class="ui-state-default">EDIT</th>
</tr>
</thead>
<tbody></tbody>
</table>
请指教
【问题讨论】:
标签: jquery datatables