You've already forked qlg.tsgz.moe
Init Repo
This commit is contained in:
33
hyhproject/admin/view/logoperates/list.html
Executable file
33
hyhproject/admin/view/logoperates/list.html
Executable file
@ -0,0 +1,33 @@
|
||||
{extend name="base" /}
|
||||
{block name="css"}
|
||||
<link rel="stylesheet" type="text/css" href="__ADMIN__/js/mmgrid/mmGrid.css?v={$v}" />
|
||||
{/block}
|
||||
{block name="js"}
|
||||
<script src="__ADMIN__/js/mmgrid/mmGrid.js?v={$v}" type="text/javascript"></script>
|
||||
<script src="__ADMIN__/logoperates/logoperates.js?v={$v}" type="text/javascript"></script>
|
||||
{/block}
|
||||
{block name="main"}
|
||||
<div id='alertTips' class='alert alert-success alert-tips fade in'>
|
||||
<div id='headTip' class='head'><i class='fa fa-lightbulb-o'></i>操作说明</div>
|
||||
<ul class='body'>
|
||||
<li>该功能主要用于查看商城职员的操作日志信息。点击“查看”可以查看该操作传送到后台的传送内容。</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="wst-toolbar">
|
||||
<input type="text" id="startDate" name="startDate" class="laydate-icon ipt" placeholder='开始日期' maxLength="20" />
|
||||
至
|
||||
<input type="text" id="endDate" name="endDate" class="laydate-icon ipt" placeholder='结束日期' maxLength="20" />
|
||||
<button class="btn btn-primary" onclick='javascript:loadGrid(0)'><i class='fa fa-search'></i>查询</button>
|
||||
</div>
|
||||
<div class='wst-grid'>
|
||||
<div id="mmg" class="mmg"></div>
|
||||
<div id="pg" style="text-align: right;"></div>
|
||||
</div>
|
||||
<div id='viewBox' style='display:none;'>
|
||||
<table class='wst-form wst-box-top'>
|
||||
<tr>
|
||||
<td id='content' style='word-break:break-all;'></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
{/block}
|
57
hyhproject/admin/view/logoperates/logoperates.js
Executable file
57
hyhproject/admin/view/logoperates/logoperates.js
Executable file
@ -0,0 +1,57 @@
|
||||
var mmg;
|
||||
$(function(){
|
||||
var laydate = layui.laydate;
|
||||
laydate.render({
|
||||
elem: '#startDate'
|
||||
});
|
||||
laydate.render({
|
||||
elem: '#endDate'
|
||||
});
|
||||
var h = WST.pageHeight();
|
||||
var cols = [
|
||||
{title:'职员', name:'staffName', width: 50},
|
||||
{title:'操作功能', name:'operateDesc' ,width:80,renderer: function (val,item,rowIndex){
|
||||
return item['menuName']+"-"+item['operateDesc'];
|
||||
}},
|
||||
{title:'访问路径', name:'operateUrl' ,width:200},
|
||||
{title:'操作IP', name:'operateIP' ,width:70},
|
||||
{title:'操作时间', name:'operateTime' ,width:70},
|
||||
{title:'传递参数', name:'op' ,width:30,renderer: function (val,item,rowIndex){
|
||||
return "<a class='btn btn-blue' onclick='javascript:toView("+item['operateId']+")'><i class='fa fa-search'></i>查看</a>";
|
||||
}}
|
||||
];
|
||||
|
||||
mmg = $('.mmg').mmGrid({height: h-155,indexCol: true,indexColWidth:50,cols: cols,method:'POST',
|
||||
url: WST.U('admin/logoperates/pageQuery'), fullWidthRows: true, autoLoad: true,
|
||||
plugins: [
|
||||
$('#pg').mmPaginator({})
|
||||
]
|
||||
});
|
||||
$('#headTip').WSTTips({width:90,height:35,callback:function(v){
|
||||
var diff = v?155:128;
|
||||
mmg.resize({height:h-diff})
|
||||
}});
|
||||
})
|
||||
function loadGrid(){
|
||||
mmg.load({page:1,startDate:$('#startDate').val(),endDate:$('#endDate').val()});
|
||||
}
|
||||
function toView(id){
|
||||
var loading = WST.msg('正在获取数据,请稍后...', {icon: 16,time:60000});
|
||||
$.post(WST.U('admin/logoperates/get'),{id:id},function(data,textStatus){
|
||||
layer.close(loading);
|
||||
var json = WST.toAdminJson(data);
|
||||
if(json.status==1){
|
||||
$('#content').html(json.data.content);
|
||||
var box = WST.open({ title:"传递参数",type: 1,area: ['500px', '350px'],
|
||||
content:$('#viewBox'),
|
||||
btn:['关闭'],
|
||||
end:function(){$('#viewBox').hide();},
|
||||
yes: function(index, layero){
|
||||
layer.close(box);
|
||||
}
|
||||
});
|
||||
}else{
|
||||
WST.msg(json.msg,{icon:2});
|
||||
}
|
||||
});
|
||||
}
|
Reference in New Issue
Block a user