...
|
...
|
@@ -192,6 +192,12 @@ var g = new common.grid({ |
|
|
}else if(items.socialSyncFlag == 1){
|
|
|
HtmArr.push('<a data-index="' + items.__index + '" data-type="noSync" href="JavaScript:;" class="btn btn-danger btn-xs synFlag">取消同步</a>');
|
|
|
}
|
|
|
|
|
|
if(items.guangSyncFlag == 0 ){
|
|
|
HtmArr.push('<a data-index="' + items.__index + '" data-type="sync" href="JavaScript:;" class="btn btn-primary btn-xs guangSynFlag">同步到逛</a>');
|
|
|
}else if(items.guangSyncFlag == 1){
|
|
|
HtmArr.push('<a data-index="' + items.__index + '" data-type="noSync" href="JavaScript:;" class="btn btn-danger btn-xs guangSynFlag">取消同步到逛</a>');
|
|
|
}
|
|
|
return HtmArr.join('');
|
|
|
}
|
|
|
}
|
...
|
...
|
@@ -279,6 +285,29 @@ $(document).on('click', '.synFlag', function () { |
|
|
|
|
|
});
|
|
|
|
|
|
// 同步
|
|
|
$(document).on('click', '.guangSynFlag', function () {
|
|
|
var item = g.rows[$(this).data("index")];
|
|
|
|
|
|
var type = $(this).data('type');
|
|
|
common.util.__ajax({
|
|
|
url: '/shareOrder/synGuang',
|
|
|
data: {
|
|
|
commentId: item.id,
|
|
|
result : type
|
|
|
}
|
|
|
}, function (res) {
|
|
|
g.reload();
|
|
|
/* if (res.code == 200) {
|
|
|
common.util.__tip('操作成功', 'success');
|
|
|
|
|
|
} else {
|
|
|
common.util.__tip(res.message,'danger');
|
|
|
}*/
|
|
|
}, false);
|
|
|
|
|
|
});
|
|
|
|
|
|
$(document).on('click', '#filter', function () {
|
|
|
g.reload();
|
|
|
});
|
...
|
...
|
@@ -361,6 +390,7 @@ $('#batch-audit-fail').on('click', function () { |
|
|
function encodeHtml(str, reg) {
|
|
|
return str ? str.replace(reg || /[&<">'](?:(amp|lt|quot|gt|#39|nbsp);)?/g, function(a, b) {
|
|
|
if (b) {
|
|
|
|
|
|
return a;
|
|
|
} else {
|
|
|
return {
|
...
|
...
|
|