31ad8541 by 任超

style:新闻动态列表的页面的修改

1 parent 22304f3e
...@@ -311,4 +311,8 @@ div.subject { ...@@ -311,4 +311,8 @@ div.subject {
311 } 311 }
312 .newsCon { 312 .newsCon {
313 overflow: hidden; 313 overflow: hidden;
314 }
315 .tj {
316 margin: 10px 0;
317 cursor: pointer;
314 } 318 }
...\ No newline at end of file ...\ No newline at end of file
......
...@@ -49,11 +49,13 @@ function HotArticle() { ...@@ -49,11 +49,13 @@ function HotArticle() {
49 success: function (result) {//返回数据根据结果进行相应的处理 49 success: function (result) {//返回数据根据结果进行相应的处理
50 if (result.code == 200 && result.data != null) { 50 if (result.code == 200 && result.data != null) {
51 for (var i = 0; i < result.data.length; i++) { 51 for (var i = 0; i < result.data.length; i++) {
52 li = '<li class="tj">'; 52 li = '<li class="tj"><a href="./xwxq.html?id='+result.data[i].id+'" target="_blank">';
53 li += '<img src="' + result.data[i].cover + '">'; 53 if ( result.data[i].cover ) {
54 li += '<img src="' + result.data[i].cover + '">';
55 }
54 li += '<span class="tj-title">' + result.data[i].headline + '</span>'; 56 li += '<span class="tj-title">' + result.data[i].headline + '</span>';
55 li += '<span class="tj-date">' + result.data[i].deadtime + '</span>'; 57 li += '<span class="tj-date">' + result.data[i].deadtime + '</span>';
56 li += '</li>'; 58 li += '</a></li>';
57 recommend.append(li); 59 recommend.append(li);
58 } 60 }
59 } 61 }
......