mirror of
https://gitee.com/zoujingli/ThinkAdmin.git
synced 2025-04-05 19:41:44 +08:00
46 lines
1.9 KiB
PHP
46 lines
1.9 KiB
PHP
{extend name='table'}
|
|
|
|
{block name="button"}
|
|
<!--{if auth("remove")}-->
|
|
<button data-action='{:url("remove")}' data-rule="id#{id}" data-table-id="oplog" data-confirm="确定要删除选中的日志吗?" class='layui-btn layui-btn-sm layui-btn-primary'>批量删除</button>
|
|
<!--{/if}-->
|
|
<!--{if auth("clear")}-->
|
|
<button data-load='{:url("clear")}' data-confirm="确定要清空所有日志吗?" class='layui-btn layui-btn-sm layui-btn-primary'>清空日志</button>
|
|
<!--{/if}-->
|
|
{/block}
|
|
|
|
{block name="content"}
|
|
<div class="think-box-shadow">
|
|
{include file='oplog/index_search'}
|
|
<table id="oplog" data-url="{:sysuri()}" data-target-search="form.form-search"></table>
|
|
</div>
|
|
{/block}
|
|
|
|
{block name='script'}
|
|
<script>
|
|
$(function () {
|
|
$('#oplog').layTable({
|
|
even: true, height: 'full',
|
|
sort: {field: 'id', type: 'desc'},
|
|
cols: [[
|
|
{checkbox: true},
|
|
{field: 'id', title: 'ID', width: 80, sort: true, align: 'center'},
|
|
{field: 'username', title: '操作账号', sort: true, align: 'center'},
|
|
{field: 'node', title: '操作节点', sort: true},
|
|
{field: 'action', title: '操作行为', sort: true},
|
|
{field: 'content', title: '操作描述', sort: false},
|
|
{field: 'geoip', title: '访问地址', sort: true},
|
|
{field: 'geoisp', title: '网络服务商', sort: false},
|
|
{field: 'create_at', title: '操作时间', minWidth: 170, align: 'center', sort: true},
|
|
{toolbar: '#toolbar', align: 'center', fixed: 'right'}
|
|
]]
|
|
});
|
|
});
|
|
</script>
|
|
|
|
<script type="text/html" id="toolbar">
|
|
<!--{if auth('remove')}-->
|
|
<a data-action='{:url("remove")}' data-value="id#{{d.id}}" data-confirm="确认要删除这条记录吗?" class="layui-btn layui-btn-sm layui-btn-danger">删 除</a>
|
|
<!--{/if}-->
|
|
</script>
|
|
{/block} |