Browse Source

文章流量统计页面 点击文章标题跳转文章页面

XMTT 7 years ago
parent
commit
bf77202d8a

+ 1 - 1
css/model/sys/article.css

19
    width: 4%;
19
    width: 4%;
20
}
20
}
21
21
22
.sys_article_index .table-opt .name,.sys_article_viewcount .table-opt .icon-line-chart{
22
.sys_article_index .table-opt .name,.sys_article_viewcount .table-opt .icon-line-chart,.sys_article_viewcount .articleTitle .name{
23
    cursor:pointer;
23
    cursor:pointer;
24
}
24
}
25
25

+ 2 - 1
html/model/sys/article/viewcount.html

55
                <!--<td class="opt-check" ><i class="icon icon-st-check" articleId="{{id}}"></i></td>-->
55
                <!--<td class="opt-check" ><i class="icon icon-st-check" articleId="{{id}}"></i></td>-->
56
                <td class="table-opt" articleId="{{id}}"><i class="icon icon-line-chart"></i></td>
56
                <td class="table-opt" articleId="{{id}}"><i class="icon icon-line-chart"></i></td>
57
                <td class="hand-id" articleId="{{id}}">{{-_index}}</td>
57
                <td class="hand-id" articleId="{{id}}">{{-_index}}</td>
58
                <td class="articleTitle">{{articleTitle}}</td>
58
                <!--<td class="articleTitle">{{articleTitle}}</td>-->
59
                <td class="articleTitle"><a class="name">{{articleTitle}}</a></td>
59
                <td class="professorName">{{professorName}}</td>
60
                <td class="professorName">{{professorName}}</td>
60
                <td class="subject">{{subject}}</td>
61
                <td class="subject">{{subject}}</td>
61
                <td class="colNum">{{colNum}}</td>
62
                <td class="colNum">{{colNum}}</td>

+ 9 - 1
js/model/sys/article/viewcount.js

45
                            if (articleId) {
45
                            if (articleId) {
46
                                util.get("../ajax/article/base", {id: articleId}, function (data) {
46
                                util.get("../ajax/article/base", {id: articleId}, function (data) {
47
                                    if (data) {
47
                                    if (data) {
48
                                        $e.parent().find(".articleTitle").text(data.articleTitle);
48
                                        $e.parent().find(".articleTitle .name").text(data.articleTitle).attr('shareId',data.shareId).attr('createTime',data.createTime);
49
                                        $e.parent().find(".professorName").text(data.professorName || data.organizationName);
49
                                        $e.parent().find(".professorName").text(data.professorName || data.organizationName);
50
                                        $e.parent().find(".subject").text(data.subject);
50
                                        $e.parent().find(".subject").text(data.subject);
51
                                        $e.parent().find(".colNum").text(caption("banner", data.colNum));
51
                                        $e.parent().find(".colNum").text(caption("banner", data.colNum));
144
                        }
144
                        }
145
                    })
145
                    })
146
                });
146
                });
147
                root.on("click",".articleTitle a.name",function () {
148
                    console.log("xmtt");
149
                    var articleId = $(this).attr("articleId");
150
                    var time = $(this).attr("createTime").substring(0,8);
151
                    var shareId = $(this).attr("shareId");
152
                    // window.open('http://www.ekexiu.com/articalShow.html?articleId=' + articleId);
153
                    window.open('http://www.ekexiu.com/shtml/a/'+time+'/' + shareId+'.html');
154
                });
147
                var myChart = echarts.init(document.getElementById('total'));
155
                var myChart = echarts.init(document.getElementById('total'));
148
                var tableData = {data: []},
156
                var tableData = {data: []},
149
                    allData = [];
157
                    allData = [];