Authored by 2586703@qq.com

评论及登录 ajax修改

... ... @@ -236,7 +236,7 @@ require("./login");
url: YohoConfig.mainUrl + that.options.publishUrl,
data: data,
dataType: 'jsonp',
jsonp: 'callback'
jsonp: 'callback',
success: function(response) {
if (response.code === '800000') {
box.alert(tips.getTips("relogin"), 5);
... ... @@ -272,7 +272,7 @@ require("./login");
that.$element.find(".comments-list").prepend(publishHtml);
}
});
/*$.ajax({*/
/*$.ajax({
type:'POST',
url:YohoConfig.mainUrl + that.options.publishUrl,
data: data,
... ... @@ -348,7 +348,7 @@ require("./login");
$.ajax({
url: url,
dataType: 'jsonp',
jsonp: 'callback'
jsonp: 'callback',
success: function(response) {
$(".comments-list").empty();
pageHtml = mustache.render(that.options.commentItemTpl, response.data.comment);
... ... @@ -382,7 +382,7 @@ require("./login");
url: YohoConfig.mainUrl + that.options.deleteUrl,
data: 'id=' + id,
dataType: 'jsonp',
jsonp: 'callback'
jsonp: 'callback',
success: function(response) {
if (response.status) {
_this.parents("li").remove();
... ...
... ... @@ -119,7 +119,7 @@ var tips = require("./tips");;
'password': password
},
dataType: 'jsonp',
jsonp: 'callback'
jsonp: 'callback',
success: function(response) {
if (response && response.status && response.data) {
var userName;
... ...