多单位版国产化地质资料管理系统
zhai
2025-12-18 3c6f6c1e3016e38146a4c46be6e7b625c35591f2
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
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%
    String path = request.getContextPath();
    String basePath = request.getScheme() + "://" + request.getServerName() + ":" + request.getServerPort()
            + path + "/";
%>
 
<!DOCTYPE HTML>
<html>
<head>
<base href="<%=basePath%>">
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<title>选择模块</title>
<link href="static/plugins/font-awesome/css/font-awesome.css" rel="stylesheet" type="text/css">
<link href="static/plugins/jquery-easyui/themes/bootstrap/easyui.css" rel="stylesheet" type="text/css">
<link rel="stylesheet" href="static/styles/initialize.css" type="text/css">
<link rel="stylesheet" href="static/styles/common.css" type="text/css">
 
<script type="text/javascript" src="static/plugins/jquery/jquery.min.js"></script>
<script type="text/javascript" src="static/plugins/jquery-easyui/jquery.easyui.min.js"></script>
<script type="text/javascript" src="static/plugins/jquery-easyui/plugins/datagrid-scrollview.js"></script>
<script type="text/javascript" src="static/plugins/jquery-easyui/locale/easyui-lang-zh_CN.js"></script>
<script type="text/javascript" src="static/plugins/slimScroll/jquery.slimscroll.min.js"></script>
<script type="text/javascript" src="static/scripts/ResizeScroll.js"></script>
<script type="text/javascript" src="static/plugins/layer/layer.js"></script>
 
<script type="text/javascript" src="static/plugins/spinjs/spin.js"></script>
<script type="text/javascript" src="static/plugins/spinjs/jquery.spin.js"></script>
<script type="text/javascript" src="static/plugins/jquery.blockUI.js"></script>
 
<script type="text/javascript" src="static/wcp/scripts/wcp.js"></script>
<script type="text/javascript" src="static/wcp/scripts/libs/wcp.layer.js"></script>
<script type="text/javascript" src="static/wcp/scripts/libs/wcp.blockUI.js"></script>
<script type="text/javascript" src="static/wcp/scripts/libs/wcp.spin.js"></script>
<script type="text/javascript" src="static/wcp/scripts/libs/wcp.jquery.js"></script>
 
<!--[if lt IE 9]>
<script type="text/javascript" src="static/plugins/json2.js"></script>
<![endif]-->
<style>
html, body {
    height: 100%;
}
 
.container {
    width: 100%;
    height: 100%;
    padding: 10px;
}
 
.left {
    width: 100%;
    float: left;
}
 
.left .pt-tree {
    border-right: 1px solid rgb(212, 212, 212) !important;
}
 
.search {
    clear: both;
}
</style>
 
</head>
<body>
    <div class="container">
        <div class="pt-note pt-note-danger">
            <p >注:勾选的模块对应的业务表数据将被清除,对应的附件数据、流程数据也将同时被清除。请谨慎选择!</p>
        </div>
        <div class="left">
            <div class="easyui-panel pt-tree" style="border-right: none;">
                <ul id="ul_module"></ul>
            </div>
        </div>
        <div class="pt-form-btn" style="bottom:0px;">
            <div class="form-group">
                <button type="button" class="pt-btn pt-btn-info" onclick="doSave();">确定</button>
                <button type="reset" class="pt-btn pt-btn-default" onclick="doClose();">关闭</button>
            </div>
        </div>
    </div>
</body>
 
<script>
    //窗口参数,用于弹窗传递
    var params = {
        opts : null,
        callBack : null
    };
 
    //模块树URL
    var url = "config/module/getModuleListByTree";
 
    var moduleTree = $("#ul_module").tree({
        method : "post",
        url : url,
        animate : true,
        checkbox : true,
        cascadeCheck : true,
        onBeforeLoad : function(node, param) {
            new ResizeScroll({
                "id" : "#ul_module",
                "height" : "400"
            });
 
            wcp.ui.setBusy("#ul_module");
        },
        onLoadSuccess : function(node, data) {
            wcp.ui.clearBusy("#ul_module");
            new ResizeScroll({
                "id" : "#ul_module",
                "height" : "390"
            });
 
        },
        onLoadError : function(args) {
            wcp.ui.clearBusy("#ul_module");
        },
    });
 
    //查询数据
    function doSearch(value) {
        moduleTree.tree({
            queryParams : {
                searchText : value
            }
        })
    }
 
    //确定按钮事件
    function doSave() {
        var checkRows = $("#ul_module").tree("getChecked");
        if (checkRows.length == 0) {
            layer.alert("请选择要初始化数据的模块!");
            return false;
        }
 
        var ids = [];
        for (var i = 0; i < checkRows.length; i++) {
            ids.push(checkRows[i].id);
        }
        layer.confirm("确认要对选中的模块数据进行初始化吗?操作后数据将不可恢复!", {
            icon : 3,
            title : '提示'
        }, function(index) {
            wcp.ui.setBusy("body", wcp.ajax({
                url : "config/setting/initCnfData",
                data : JSON.stringify(ids),
            }).done(function(result) {
                doClose();
                top.wcp.notify.success("初始化成功!");
            }));
        });
    }
    function doClose() { //关闭按钮事件
        var index = top.layer.getFrameIndex(window.name); //获取窗口索引
        top.layer.close(index);
    }
</script>
</html>