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
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:th="http://www.w3.org/1999/xhtml" >
<head>
    <meta charset="UTF-8" />
    <title th:text="${systemName}"></title>
    <script th:src="@{${pubzyWebRoot} + 'media/js/jquery-1.11.1.js'}"></script>
    <script type="text/javascript" th:inline="javascript">
        /*<![CDATA[*/
        var backstageWebRoot = [[${backstageWebRoot}]];
        $(function() {
            var search = window.location.search;
            var newsid = "";
            if(search.indexOf("?") > -1){
                search = search.replace("?", "");
                newsid = search.split('=')[1];
            }
            $.ajax({
                type : "GET",
                url : backstageWebRoot + 'api/sys/pubnews/getInfoById/'+newsid,
                success : function(result) {
                    if(result != null){
                        var dateD = new Date(result.lasteditdate);
                        var dateS = dateD.toLocaleString() != "" ? 
                                dateD.toLocaleString().substring(0,dateD.toLocaleString().indexOf(" "))
                                .replace(/\//g,"-"):"";
                        $(".div_title").html(result.title);
                        $("#username").text(result.createusername);
                        $("#createdate").text(dateS);
                        $(".div_info").html(htmlDecodeByRegExp(result.contents));
                    }
                }
            });
        });
        //解码
        function htmlDecodeByRegExp(str){
            var s = "";
            if(str.length == 0) return "";
            s = str.replace(/&amp;/g,"&");
            s = s.replace(/&lt;/g,"<");
            s = s.replace(/&gt;/g,">");
            s = s.replace(/&nbsp;/g," ");
            s = s.replace(/&#39;/g,"\'");
            s = s.replace(/&quot;/g,"\"");
            return s;
        }
        /*]]>*/
    </script>
    <style>
        body {
            margin: 0;
            font-family: "Roboto", sans-serif !important;
        }
        .div_zxmain{
            padding:3%;
            height:100%;
        }
        .div_title{
            text-align:center;
            /*font-weight:bold;*/
            font-size:24px;
            color: #296ebb;
        }
        .div_createInfo{
            text-align:center;
            line-height:29px;
            background:#f3f3f3;
            font-size:13px;
            font-family:微软雅黑;
            margin-top: 27px;
        }
        .div_info{
            width:100%;
            height:100%;
            font-size:16px;
            margin-top:20px;
            /*padding-left: 10px;*/
            padding-right: 10px;
        }
    </style>
</head>
<body>
<div class="div_zxmain">
    <div class="div_title"></div>
      <p class="div_createInfo" >发布人:<span id="username"></span>
        &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
        &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
        &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
        更新时间:
        <span id="createdate"></span>
    </p>
    <div class="div_info"></div>
    <hr style="height:1px;border:none;background:#007dfe"/>
    <p style="text-align: center"><a href="#" onclick="window.print()">[打印本页]</a>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
        <a href="#" onclick="window.close()">[关闭页面]</a></p>
</div>
</body>
</html>