wzy
2021-04-01 d388e2788b7ef088d7cd40f901b0acdcec460bc3
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
<!DOCTYPE HTML>
<html  xmlns:th="http://www.thymeleaf.org">
<head>
<meta charset="utf-8">
<META HTTP-EQUIV="Pragma" CONTENT="no-cache">
<meta name="renderer" content="webkit|ie-comp|ie-stand">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<meta name="viewport"
    content="width=device-width,initial-scale=1,minimum-scale=1.0,maximum-scale=1.0,user-scalable=no" />
<meta http-equiv="Cache-Control" content="no-siteapp" />
<!-- 本框架基本脚本和样式 -->
<script type="text/javascript" th:src="@{/js/plugin/jquery-2.1.4.min.js}"></script>
<script type="text/javascript" th:src="@{/js/systools/MBase.js}"></script>
 
</head>
<body class="gray-bg">
    <div class="wrapper wrapper-content animated fadeInRight">
        <div class="ibox-content radius-5 mt-5 mpanel">
            <div class="row">
                <div class="col-sm-12">
                    <!-- 数据表格部分 -->
                    <table id="mgrid">
                        <thead>
                            <tr>
                                <th data-checkbox="true"></th>
                                <th data-formatter="MGrid.indexfn" data-align="center"
                                    data-width="30px">序号</th>
                                <th data-field="taskType">任务名称</th>
                                <th data-field="startTime">开始时间</th>
                                <th data-field="finishTime">结束时间</th>
                                <th data-align="center" data-width="150px" data-field="id"
                                    data-formatter="buidOperate">操作</th>
                            </tr>
                        </thead>
                    </table>
                    <!-- 数据表格部分end -->
                </div>
            </div>
        </div>
    </div>
    <script type="text/javascript"
        th:src="@{/js/systools/MJsBase.js}"></script>
    <script type="text/javascript">
        
        //定义表格对象
        var myGrid;
 
        $(function() {
            
            //定义删除数据的路径
            var delPath = "";
            //使用权限标签控制路径是否显示在界面上
            delPath = "";
            //初始化表格对象
            myGrid = MGrid.initGrid({
                url : basePath+"/developer/asyncErrorLog/list",//url数据加载地址,表格初始化后会自动去后台加载数据。
                delUrl : delPath
            });
 
        });
        //构建操作栏的按钮
        function buidOperate(value, row, index) {
            var html = [];
            html[0] = '<a onClick="openDetail(\'' + value
                    + '\')"  title="详情" class="glyphicon glyphicon-eye-open"></a>'
            return html.join("");
        }
        
        //打开编辑界面
        function openDetail(id) {
            layer.open({
                type : 2,
                title : "查看详情",
                area : [ MUI.SIZE_L, '500px' ],
                maxmin : true,
                content : [ basePath+'/developer/asyncErrorLog/detail?id=' + id ]
            });
        }
    </script>
</body>
</html>