...
|
...
|
@@ -13,6 +13,12 @@ webpackJsonp([152],[ |
|
|
ON: 2,// 开启
|
|
|
OFF: 1 // 关闭
|
|
|
};
|
|
|
// 时间状态
|
|
|
var TimeStatusEnum = {
|
|
|
BEFORE : 1,// 未开始
|
|
|
ING: 2,// 进行中
|
|
|
END: 3 // 已过期
|
|
|
};
|
|
|
//界面分类值
|
|
|
var PagEnum = {
|
|
|
DEF_HOT_SEARCH_WORDS: 1, //默认搜索词管理页面
|
...
|
...
|
@@ -59,6 +65,9 @@ webpackJsonp([152],[ |
|
|
el: "#status-filter"
|
|
|
});
|
|
|
new common.dropDown({
|
|
|
el: "#time-status-filter"
|
|
|
});
|
|
|
new common.dropDown({
|
|
|
el: "#channelIds-filter"
|
|
|
});
|
|
|
new common.dropDown({
|
...
|
...
|
@@ -164,6 +173,7 @@ webpackJsonp([152],[ |
|
|
channelIds: $.trim(common.util.__input("channelIds-filter")),
|
|
|
startTime: $.trim($('#starttime-filter').val()),
|
|
|
endTime: $.trim($('#endtime-filter').val()),
|
|
|
timeStatus: $.trim(common.util.__input("time-status-filter")),
|
|
|
content: $.trim($('#content-filter').val())
|
|
|
};
|
|
|
//热搜词管理页面
|
...
|
...
|
@@ -201,6 +211,17 @@ webpackJsonp([152],[ |
|
|
}
|
|
|
}
|
|
|
},
|
|
|
{
|
|
|
display: "时间状态", name: "timeStatus", render: function (item) {
|
|
|
if (item.timeStatus === TimeStatusEnum.BEFORE) {
|
|
|
return "<span>未开始</span>";
|
|
|
}else if (item.timeStatus === TimeStatusEnum.ING) {
|
|
|
return "<span>进行中</span>";
|
|
|
} else {
|
|
|
return "<span>已过期</span>";
|
|
|
}
|
|
|
}
|
|
|
},
|
|
|
{display: "开始时间", name: "startTime"},
|
|
|
{display: "结束时间", name: "endTime"},
|
|
|
{display: "添加人", name: "creatorUsrname"},
|
...
|
...
|
@@ -209,7 +230,11 @@ webpackJsonp([152],[ |
|
|
{display: "修改时间", name: "modifyTime"},
|
|
|
{
|
|
|
display: "操作", name: "", render: function (item) {
|
|
|
return '<a class="btn btn-xs btn-info modify" data-index="' + item.__index + '">修改</a>';
|
|
|
var str = '<a class="btn btn-xs btn-info modify" data-index="' + item.__index + '">修改</a>';
|
|
|
// if (item.status === StatusEnum.OFF) {
|
|
|
// str = str+ '<a class="btn btn-xs btn-danger del-a" data-index="' + item.id + '" data-name="' + item.content + '">删除</a>';
|
|
|
// }
|
|
|
return str;
|
|
|
}
|
|
|
}
|
|
|
];
|
...
|
...
|
@@ -383,6 +408,23 @@ webpackJsonp([152],[ |
|
|
Bll.toast('/operations/terms/add', item, "添加");
|
|
|
});
|
|
|
/**
|
|
|
* 清理搜索词缓存
|
|
|
*/
|
|
|
$("#filter-clear").click(function () {
|
|
|
common.util.__tip("开始清缓存","success");
|
|
|
common.util.__ajax2({
|
|
|
url: '/hotSearchBrand/clearSearchWordsCache'
|
|
|
}, function(res){
|
|
|
if (res.code == 200) {
|
|
|
// g.reload();
|
|
|
common.util.__tip("清缓存成功!","success");
|
|
|
}else{
|
|
|
common.util.__tip(res.data.message);
|
|
|
}
|
|
|
});
|
|
|
|
|
|
});
|
|
|
/**
|
|
|
* 修改
|
|
|
*/
|
|
|
$(document).on("click", ".modify", function () {
|
...
|
...
|
@@ -392,6 +434,32 @@ webpackJsonp([152],[ |
|
|
Bll.toast('/operations/terms/modify', item, "修改");
|
|
|
});
|
|
|
|
|
|
/**
|
|
|
* 删除默认搜索词
|
|
|
*//*
|
|
|
$(document).on("click", ".del-a", function () {
|
|
|
var item = $(this).data('index');
|
|
|
var name = $(this).data('name');
|
|
|
common.dialog.confirm("温馨提示", "确定  <b><font color='#ff0000'>删除 </font>【" + name + "】</b> 吗?", function() {
|
|
|
common.util.__ajax2({
|
|
|
url: '/hotSearchBrand/delSearchWords',
|
|
|
data: {
|
|
|
id: item
|
|
|
}
|
|
|
}, function(res){
|
|
|
if (res.code == 200) {
|
|
|
// g.reload();
|
|
|
$("#filter-btn").click();
|
|
|
common.util.__tip("删除成功!","success");
|
|
|
}else{
|
|
|
common.util.__tip(res.data.message);
|
|
|
}
|
|
|
})
|
|
|
});
|
|
|
});*/
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
...
|
...
|
|