Authored by 张凯

杭州-优化通知查询页面

... ... @@ -26,20 +26,17 @@ layui.define(['table', 'form', 'admin', 'layer', 'common','sessions', 'xmSelect'
//回车搜索
$('#notice_search_keyword').keydown(function (e) {
if (e.keyCode === 13) {
getChartData();
reloadTable();
reloadData();
}
});
//查询按钮点击事件
$('#noticeSearchQueryBtn').on('click',function () {
getChartData();
reloadTable();
reloadData();
})
//发送状态
form.on('select(notice_search_isSend)', function(){
getChartData();
reloadTable();
reloadData();
});
form.render();
... ... @@ -158,25 +155,7 @@ layui.define(['table', 'form', 'admin', 'layer', 'common','sessions', 'xmSelect'
}
});
// 用户下拉框
// common.userXmSelect({
// el: '#notice_user_list',
// name: 'users',
// tips: '=接收人=',
// toolbar: {
// show: false
// },
// radio: true,
// on: function (data) {
// if (data.arr && data.arr.length > 0){
// userNames = data.arr[0].username;
// } else {
// userNames = '';
// }
// reloadTable();
// }
// });
//用户下拉框 joke add 20211209
$.ajax({
url: `${common.domainName}/api-web/notice/getNoticeUsers?access_token=${accessToken}`,
method: 'GET',
... ... @@ -214,8 +193,7 @@ layui.define(['table', 'form', 'admin', 'layer', 'common','sessions', 'xmSelect'
} else {
userNames = '';
}
getChartData();
reloadTable();
reloadData();
}
});
}else{
... ... @@ -228,7 +206,7 @@ layui.define(['table', 'form', 'admin', 'layer', 'common','sessions', 'xmSelect'
}
});
//绑定业务下拉选择数据
//绑定业务下拉选择数据 joke add 20211209
admin.req({
url: domainName + '/api-web/notice/getNoticeBusTypes',
success: function (response) {
... ... @@ -267,8 +245,7 @@ layui.define(['table', 'form', 'admin', 'layer', 'common','sessions', 'xmSelect'
} else {
busId = '';
}
getChartData();
reloadTable();
reloadData();
}
});
if(busIdSelect){
... ... @@ -283,6 +260,7 @@ layui.define(['table', 'form', 'admin', 'layer', 'common','sessions', 'xmSelect'
layer.msg('获取业务失败', {icon: 2});
}
});
//资源类型下拉框 joke add 20211209
$.ajax({
url: `${common.domainName}/api-web/notice/getNoticeResTypes?access_token=${accessToken}`,
method: 'GET',
... ... @@ -321,8 +299,7 @@ layui.define(['table', 'form', 'admin', 'layer', 'common','sessions', 'xmSelect'
} else {
resType = '';
}
getChartData();
reloadTable();
reloadData();
}
});
if(busIdSelect){
... ... @@ -484,5 +461,10 @@ layui.define(['table', 'form', 'admin', 'layer', 'common','sessions', 'xmSelect'
}
})
}
function reloadData(){
getChartData();
reloadTable();
}
});
});
... ...