Authored by zhangxiaoru

editorial

@@ -8,13 +8,13 @@ var $ = require('yoho-jquery'), @@ -8,13 +8,13 @@ var $ = require('yoho-jquery'),
8 lazyLoad = require('yoho-jquery-lazyload'), 8 lazyLoad = require('yoho-jquery-lazyload'),
9 dialog = require('../plugins/dialog'); 9 dialog = require('../plugins/dialog');
10 10
  11 +var _alert = dialog.Alert;
  12 +
11 require('../common/header'); 13 require('../common/header');
12 require('../common/return-top'); 14 require('../common/return-top');
13 15
14 lazyLoad($('.content-msg img.lazy')); 16 lazyLoad($('.content-msg img.lazy'));
15 17
16 -var _alert = dialog.Alert;  
17 -  
18 $('.editorial-index-page').on('click', '.like-icon', function() { 18 $('.editorial-index-page').on('click', '.like-icon', function() {
19 var $this = $(this), 19 var $this = $(this),
20 20
@@ -2,13 +2,13 @@ var $ = require('yoho-jquery'), @@ -2,13 +2,13 @@ var $ = require('yoho-jquery'),
2 lazyLoad = require('yoho-jquery-lazyload'), 2 lazyLoad = require('yoho-jquery-lazyload'),
3 dialog = require('../plugins/dialog'); 3 dialog = require('../plugins/dialog');
4 4
  5 +var _alert = dialog.Alert;
  6 +
5 require('../common/header'); 7 require('../common/header');
6 require('../common/return-top'); 8 require('../common/return-top');
7 9
8 lazyLoad($('.content-msg img.lazy')); 10 lazyLoad($('.content-msg img.lazy'));
9 11
10 -var _alert = dialog.Alert;  
11 -  
12 $('.editorial-list-page').on('click', '.like-icon', function() { 12 $('.editorial-list-page').on('click', '.like-icon', function() {
13 13
14 var $this = $(this), 14 var $this = $(this),
@@ -35,6 +35,7 @@ $('.editorial-list-page').on('click', '.like-icon', function() { @@ -35,6 +35,7 @@ $('.editorial-list-page').on('click', '.like-icon', function() {
35 if (data.code === 500) { 35 if (data.code === 500) {
36 new _alert(data.message).show(); 36 new _alert(data.message).show();
37 } 37 }
  38 +
38 // if (data.code === 200) { 39 // if (data.code === 200) {
39 // if (data.data * 1 === 0) { 40 // if (data.data * 1 === 0) {
40 // $this.next('b').addClass('num-0').children('.num').html('0'); // 隐藏数字显示 41 // $this.next('b').addClass('num-0').children('.num').html('0'); // 隐藏数字显示