2
13693261870
2022-09-16 653761a31dfeb50dd3d007e892d69c90bf0cdafc
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
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
<!--
功能描述:资源中心 - 资源发布
-->
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:layout="http://www.w3.org/1999/xhtml"
      xmlns:th="http://www.w3.org/1999/xhtml" layout:decorator="MasterPage/CommonPage/Layout">
<!-- layout文件路径-->
<head>
    <meta charset="utf-8" />
    <meta http-equiv="X-UA-Compatible" content="IE=Edge" />
    <meta name="viewport" content="width=device-width, initial-scale=1" />
    <title th:text="'资源发布 - ' + ${systemName}"></title>
    <!--<link th:href="@{${pubzyWebRoot} + 'ext-4.2.1.883/resources/css/ext-all-neptune.css'}" rel="stylesheet" type="text/css" />-->
    <link th:href="@{${pubzyWebRoot} + 'media/css/bootstrap-tree.css'}" rel="stylesheet" type="text/css" />
    <link rel="stylesheet" th:href="@{${pubzyWebRoot} + 'BootStrap4/expand/plugins/portlet/css/portlet.css'}" />
    <link th:href="@{${pubzyWebRoot} + 'media/css/select2_metro.css'}" type="text/css" rel="stylesheet" />
    <link th:href="@{${pubzyWebRoot} + 'media/css/pagination.css'}" type="text/css" rel="stylesheet" />
    <link rel="stylesheet" th:href="@{${pubzyWebRoot} + 'BootStrap4/assets/plugins/bootstrap-datepicker/old_datepaker/datepicker.css'}" />
    <link th:href="@{${pubzyWebRoot} + 'zTree/css/metroStyle/metroStyle.css'}" rel="stylesheet" type="text/css" />
    <script th:src="@{${pubzyWebRoot} + 'jqPaginator/jqpaginator.min.js'}"></script>
    <!--<script th:src="@{${pubzyWebRoot} + 'ext-4.2.1.883/ext-all.js'}"></script>-->
    <!--<script th:src="@{${pubzyWebRoot} + 'ext-4.2.1.883/locale/ext-lang-zh_CN.js'}"></script>-->
    <!--<script th:src="@{${pubzyWebRoot} + 'ext-4.2.1.883/PagingToolbar.js'}"></script>-->
    <!--<script src="/js/Extjs/ZYML/ZYMLZiYuan.js"></script>-->
    <script th:src="@{${pubzyWebRoot} + 'media/js/tabPages.js'}"></script>
    <script th:src="@{${pubzyWebRoot} + 'media/js/winPro.js'}"></script>
    <script th:src="@{${pubzyWebRoot} + 'echarts/echarts.min-3.0.js'}" type="text/javascript"></script>
    <script th:src="@{${pubzyWebRoot} + 'media/js/select2.min.js'}" type="text/javascript"></script>
    <!--<script th:src="@{${pubzyWebRoot} + 'BootStrap4/assets/plugins/bootstrap-datepicker/old_datepaker/bootstrap-datepicker.js'}"></script>-->
    <!--<script th:src="@{${pubzyWebRoot} + 'BootStrap4/assets/plugins/bootstrap-datepicker/old_datepaker/bootstrap-datepicker.zh-CN.min.js'}"></script>-->
    <script th:src="@{${pubzyWebRoot} + 'zTree/js/jquery.ztree.all.js'}"></script>
    <script th:src="@{${pubzyWebRoot} + 'zTree/js/jquery.ztree.core.js'}"></script>
    <script th:src="@{${pubzyWebRoot} + 'zTree/js/jquery.ztree.exedit.js'}"></script>
    <script th:src="@{${pubzyWebRoot} + 'zTree/js/jquery.ztree.excheck.js'}"></script>
    <script src="/js/openresource.js"></script>
    <style type="text/css">
        .div_left{
            position: absolute;
            width:350px;
            height: 780px;
            margin: 3px;
        }
 
        .div_right{
            margin-left: 360px;
            height: 100%;
            padding: 3px;
        }
 
        .div_catalog{
            float: left;
            width:100%;
            height: 100%;
            color: #000;
            border-radius: 6px;
            padding: 2px;
            background-color: #fff;
        }
 
        .div_catalog div{
            /*width: 100%;*/
            height: 55px;
            border-bottom: 1px solid #CFD3D6;
            cursor:pointer;
        }
 
        .div_catalog div:not(:first-child):hover {
            background-color: #F5F6FA;
        }
 
        .div_catalog div:first-child{
            background-color: #2B85FF;
            cursor: pointer;
            border-top-left-radius: 6px;
            border-top-right-radius: 6px;
            color: white;
        }
 
        .div_catalog div:not(:first-child) {
            margin: 0 3px;
        }
 
 
        .span_left{
            float: left;
            font-size:17px;
            line-height:55px;
            margin-left: 20px;
        }
        .span_right{
            float: right;
            font-size:14px;
            line-height: 55px;
            margin-right: 10px;
            color: #737373;
        }
        .div_search{
            background-color:white;
            height: 60px;
            /*width: 100%;*/
            padding: 5px 5px;
            -webkit-border-radius: 10px;
            -moz-border-radius: 10px;
            border-radius: 10px;
            font-size: 16px !important;
            margin-top: 0.5px;
        }
        .div_main{
            color:grey;
            height: 500px;
            font-size: 16px;
        }
        .div_zy{
            background-color: white;
            /*padding: 18px 0px 0px 27px;*/
            /*border-left:3px solid #E0DEDB;*/
            height: 200px;
            border-radius: 6px;
        }
        /*.div_zy:first-child{*/
            /*!*border-top: 1px solid #E0DEDB;*!*/
        /*}*/
        /*.div_zy:not(:first-child){*/
            /*margin-top: 10px;*/
        /*}*/
        .sort{
            cursor: pointer;
            padding: 5px 8px;
            border-radius: 5px;
        }
        .shtype{
            cursor: pointer;
            padding: 5px 8px;
            border-radius: 5px;
        }
 
        .clickCss {
            /*color: #fff;*/
            background-color: #F5F6FA !important;
        }
 
        /*边框公共样式*/
        .div_border {
            box-shadow: 0px 0px 1px 1px #bfbfbf;
        }
 
        .div_top:not(:first-child) {
            margin-top: 20px;
        }
 
        .search_left_div {
            float: left;
            border: 1px solid #EBEDF9;
            height: 100%;
            -webkit-border-radius: 6px;
            -moz-border-radius: 6px;
            border-radius: 6px;
            margin-right: 5px;
            line-height: 50px;
            padding: 0 10px;
            margin-right: 15px;
        }
 
        .isactive {
            color: #fff;
            background-color: #2B85FF;
        }
 
        .isanormal {
            color: #000;
            background-color: ;
        }
 
        .search_left {
            /*display: inline-block;*/
            float: left;
            /*width: 582px;*/
            height: 50px;
            line-height: 50px;
            color: grey;
        }
 
        .search_right {
            display: inline-block;
            width: 299px;
            float: right;
            border: 1px solid #8DB3E0;
            border-radius: 6px;
        }
 
        .search_title {
            color: #2B56BF;
            margin-right: 5px;
            /*font-size: 17px;*/
        }
 
        p {
            margin-bottom: 10px !important;
        }
 
    </style>
    <script type="text/javascript" th:inline="javascript">
        var resourceType = "";
        var formdata = {};
        $(function () {
            resourceType = [[${ResourceTypeListJson}]];
            showResourceType();
            // $(".div_right").css("width",window.innerWidth-300+"px");
            $(".div_right").css("width",$("#bts_pagebody").width()-360+"px");
            $("#div_search").css("width",$(".div_right").width() +'px');
        });
        function  changepage(num) {
            var url = 'dataListnew?page=' + num;
            $("#block").load(url, formdata, function () { //加载图文列表
                var Page = Number(document.getElementById("curren").value);
                var Count = Number(document.getElementById("total").value);
                if (Count != 0) {
                    $('#Paginator').jqPaginator({
                        totalCounts: Count,
                        pageSize: 15,
                        currentPage: Page,
                        first: '<li class="first"><a href="javascript:void(0);">首页</a></li>',
                        prev: '<li class="prev"><a href="javascript:void(0);">上一页</a></li>',
                        next: '<li class="next"><a href="javascript:void(0);">下一页</a></li>',
                        last: '<li class="last"><a href="javascript:void(0);">末页</a></li>',
                        page: '<li class="page"><a href="javascript:void(0);">{{page}}</a></li>',
                        onPageChange: function (num) {
                            if (num != Page) {
                                changepage(num);
                            }
                        }
                    });
                }
            });
        }
        function showResourceType(){
            var list = eval(resourceType);
            var html = "<div onclick=\"Search('','','all','')\" key=\"all\" style='cursor: auto;'><span class=\"span_left\" style='font-size:18px; font-weight: bold;'>全部资源类型</span></div>";
            for(var i =0;i<list.length;i++){
                var name = (list[i].key.indexOf("KJ_") != -1 && list[i].key != "KJ_") ? ("--"+list[i].value):list[i].value;
                html+="<div onclick=\"Search('','','"+list[i].key+"','')\" key='"+list[i].key+"'><span class='span_left'>"+name
                    +"</span><span class='span_right'>笔</span><span style=\"line-height: 55px; font-size: 17px; float: right;\">" + list[i].zycount + "</span></div>";
            }
            $(".div_catalog").html(html);
        }
        //排序
        function sort(obj){
            $(".sort").each(function () {
                if($(this)[0].id != $(obj)[0].id){
                    // $(this).css("color","black").css("font-weight","normal");
                    // $(this).css("background-color","");
                    $(this).addClass("isanormal");
                    $(this).removeClass("isactive");
                }else{//选中排序
                    var type = "";
                    if($(obj).attr("type").trim() == ""){
                        type = " desc";
                    }
                    if($(obj).attr("type").trim() == "desc"){
                        type = "";
                    }
                    $(obj).attr("type",type);
                    Search($(obj)[0].id+type,"","","-1");
                    /*$(this).css("color","#ffffff").css("font-weight","bold");
                    $(this).css("background-color","#0b92d4");*/
                    $(this).addClass("isactive");
                    $(this).removeClass("isanormal");
                }
            })
        }
        //审核状态
        function shtype(obj) {
            $(".shtype").each(function () {
                if($(this).attr("type") != $(obj).attr("type")){
                    // $(this).css("color","black").css("font-weight","normal");
                    // $(this).css("background-color","");
                    $(this).addClass("isanormal");
                    $(this).removeClass("isactive");
                }else{//选中排序
                    Search("","","",$(obj).attr("type"));
                    // $(this).css("color","#ffffff").css("font-weight","bold");
                    // $(this).css("background-color","#0b92d4");
                    $(this).addClass("isactive");
                    $(this).removeClass("isanormal");
                }
            })
        }
    </script>
    <script>
        //查询事件
        function Search(sort,title,resourceclass,type) {
            formdata = {};
            if(resourceclass != ''){
                $("#resourceclass").val(resourceclass);
                $(".div_catalog div:not(:first-child)").each(function () {
                    if($(this).attr("key") == resourceclass){
                        $(this).addClass("clickCss");
                        // $(this).css("color","#EEE683");
                        // $(this).css("background-color","#17A6EC");
                    }else {
                        $(this).removeClass("clickCss");
                        // $(this).css("color","white");
                        // $(this).css("background-color","#0B92D4");
                    }
                })
            }
            var thistype = "";
            $(".shtype").each(function () {
                if($(this).css("background-color") != "rgba(0, 0, 0, 0)"){
                    thistype = $(this).attr("type");
                }
            });
            var thissort = "";
            $(".sort").each(function () {
                if($(this).css("background-color") != "rgba(0, 0, 0, 0)"){
                    thissort = $(this).attr("id") + "  " + $(this).attr("type");
                }
            });
            formdata = {
                sort:sort != ''?sort : thissort,
                title:$("#title").val(),
                resourceclass: $("#resourceclass").val() != 'all' ? $("#resourceclass").val() : "",
                auditstatus:type != '-1'?type:thistype
            };
            $("#block").load('dataListnew', formdata, function () {
                var  Page =Number(document.getElementById("curren").value);
                var  Count =Number(document.getElementById("total").value);
                if(Count != 0) {
                    $('#Paginator').jqPaginator({
                        totalCounts: Count,
                        pageSize: 15,
                        currentPage: Page,
                        first: '<li class="first"><a href="javascript:void(0);">首页</a></li>',
                        prev: '<li class="prev"><a href="javascript:void(0);">上一页</a></li>',
                        next: '<li class="next"><a href="javascript:void(0);">下一页</a></li>',
                        last: '<li class="last"><a href="javascript:void(0);">末页</a></li>',
                        page: '<li class="page"><a href="javascript:void(0);">{{page}}</a></li>',
                        onPageChange: function (num) {
                            if(num!=Page){
                                changepage(num);
                            }
                        }
                    });
                }
            });
        }
        $(function(){
            var url ='dataListnew?page='+1;
            formdata = {
                sort:'pubdate desc'
            };
            $("#block").load(url, formdata, function () { //加载图文列表
                var  Page =Number(document.getElementById("curren").value);
                var  Count =Number(document.getElementById("total").value);
                if(Count != 0) {
                    $('#Paginator').jqPaginator({
                        totalCounts: Count,
                        pageSize: 15,
                        currentPage: Page,
                        first: '<li class="first"><a href="javascript:void(0);">首页</a></li>',
                        prev: '<li class="prev"><a href="javascript:void(0);">上一页</a></li>',
                        next: '<li class="next"><a href="javascript:void(0);">下一页</a></li>',
                        last: '<li class="last"><a href="javascript:void(0);">末页</a></li>',
                        page: '<li class="page"><a href="javascript:void(0);">{{page}}</a></li>',
                        onPageChange: function (num) {
                            if(num!=Page){
                                changepage(num);
                            }
                        }
                    });
                }
            });
        })
        function  changepage(num) {
            var url ='dataListnew?page='+num;
            $("#block").load(url, formdata, function () { //加载图文列表
                var  Page =Number(document.getElementById("curren").value);
                var  Count =Number(document.getElementById("total").value);
                if(Count != 0) {
                    $('#Paginator').jqPaginator({
                        totalCounts: Count,
                        pageSize: 15,
                        currentPage: Page,
                        first: '<li class="first"><a href="javascript:void(0);">首页</a></li>',
                        prev: '<li class="prev"><a href="javascript:void(0);">上一页</a></li>',
                        next: '<li class="next"><a href="javascript:void(0);">下一页</a></li>',
                        last: '<li class="last"><a href="javascript:void(0);">末页</a></li>',
                        page: '<li class="page"><a href="javascript:void(0);">{{page}}</a></li>',
                        onPageChange: function (num) {
                            if(num!=Page){
                                changepage(num);
                            }
                        }
                    });
                }
            });
        }
        //打开资源信息新增窗口
        function AddZiYuan() {
            var url = "/res/ResManage/ResRegister/ResEdit?resMainInfoId=";
            // winPro.openFullwin(url, "新增资源", "yes");
            openFullWindow(url, "新增资源");
        }
    </script>
</head>
<body>
<div layout:fragment="content">
    <input type="hidden" id="resourceclass" />
    <div class="content-page div_top" style="min-height: 978px !important;margin-left: 0;margin-top: 17px !important;">
        <div class="div_left">
            <div class="div_catalog div_border">
            </div>
        </div>
        <div class="div_right">
            <div class="div_search div_border">
 
                <div class="search_left">
                    <div class="search_left_div">
                        <span class="search_title">排序</span>
                        <span class="sort isactive" onclick="sort(this)" type="" id="pubdate" type="desc">发布时间</span>
                        <span class="sort" onclick="sort(this)" type="" id="applycount">申请量</span>
                        <span class="sort" onclick="sort(this)" type="" id="readcount">浏览量</span>
                    </div>
                    <div class="search_left_div">
                        <span class="search_title">审核状态</span>
                        <span class="shtype isactive" onclick="shtype(this)" type="">全部</span>
                        <span class="shtype" onclick="shtype(this)" type="1">待审核</span>
                        <span class="shtype" onclick="shtype(this)" type="3">未通过</span>
                        <span class="shtype" onclick="shtype(this)" type="2">已通过</span>
                        <span class="shtype" onclick="shtype(this)" type="0">未提交</span>
                    </div>
 
                </div>
                <div class="search_right">
                    <input type="text" id="title" name="title" value="" style="height: 46px;border: none; font-size: 15px;color: #000;font-weight: 600;width: 78%;display: inline-block;" class="form-control col-sm-12" placeholder="请输入资源名称、简称或关键字" />
                    <img style="float: right;cursor: pointer;" onclick="Search('','','','-1')" src="/image/Systeminfo/search.png" />
                </div>
 
                <div style="width:100%;float:left;margin-top: 15px;">
 
                </div>
            </div>
            <div style="height: 40px; line-height: 40px;font-size: 16px;padding-left: 5px;color: grey;margin: 5px 0;">
                <span>搜索到<span id="countNum"></span>笔资源</span>
                <button type="button" class="btn btn-primary" onclick="AddZiYuan('');" style="float: right; margin-top: 3px;">
                    <i class="fa fa-plus"></i>发布
                </button>
            </div>
            <div class="div_main" id="block">
            </div>
            <div id="grid" style="display: none"></div>
        </div>
    </div>
</div>
</body>
</html>