Authored by wangtao

fix:#1684 【监控概览】将业务置顶后左下角业务统计数量发现变化(确认是否修改统计规则)

#1784 【监控概览】选择最后一个业务右击复选框样式问题(复选框溢出外层)
... ... @@ -187,10 +187,22 @@ layui.define(['common', 'swiper', 'admin', 'commonDetail', 'mxClient', 'sessions
currentBizId = $(this).data("id");
$("#mainindex_menubox").show(100);
$("#mainindex_menubox").css({
'top': e.pageY + 'px',
'left': e.pageX + 'px'
});
let maxWidth = document.body.offsetWidth;
if(maxWidth - e.pageX < 120){
$("#mainindex_menubox").css({
'top': e.pageY + 'px',
'right': '50px'
});
} else {
$("#mainindex_menubox").css({
'top': e.pageY + 'px',
'left': e.pageX + 'px'
});
}
//子菜单点击事件
$("#mainindex_menubox ul>li").unbind("click").on("click", function () {
... ... @@ -203,7 +215,11 @@ layui.define(['common', 'swiper', 'admin', 'commonDetail', 'mxClient', 'sessions
window.parent.postMessage({
type: 'custom-jump-menu-event',
message: {
'type':"JumpToAlarmManagement"
'type':"JumpToAlarmManagement",
params:{
"tag":"BUS",
"id":bizId
}
}
}, '*')
}
... ... @@ -235,7 +251,11 @@ layui.define(['common', 'swiper', 'admin', 'commonDetail', 'mxClient', 'sessions
type: 'custom-jump-menu-event',
message: {
'path':'',
'type':"JumpToListView"
'type':"JumpToListView",
params:{
"tag":"BUS",
"id":bizId
}
}
}, '*')
}
... ... @@ -279,31 +299,36 @@ layui.define(['common', 'swiper', 'admin', 'commonDetail', 'mxClient', 'sessions
layer.msg('暂无该类型资源', {icon: 0});
return false;
}
if (level && level === 'all') {
$(this).attr("lay-href", "/alarm/activewarning/bizId=" + _bizId)
} else {
/*var restype = '';
if (_resType) {
if (_resType == 'HOST') {
_resType = 'operatingSystem'
$(this).attr("data-restype", "operatingSystem");
window.top.postMessage({
type: 'custom-jump-menu-event',
message: {
'path':'',
'type':"JumpToListView",
params:{
"tag":"BUS",
"_resType":_resType,
"level":level,
"id":_bizId
}
restype = "/restype=" + _resType
}
$('[lay-id="/biz/list"]').find('.layui-tab-close').trigger('click');
$(this).attr("lay-href", "/biz/list/bizId=" + _bizId + restype);
admin.sideFlexible();*/
let win = window.parent;
if (win) {
window.parent.postMessage({
type: 'custom-jump-menu-event',
message: {
'path':'',
'type':"JumpToListView"
}
}, '*')
}
}
}, '*');
// if (level && level === 'all') {
// // $(this).attr("lay-href", "/alarm/activewarning/bizId=" + _bizId)
// } else {
// /*var restype = '';
// if (_resType) {
// if (_resType == 'HOST') {
// _resType = 'operatingSystem'
// $(this).attr("data-restype", "operatingSystem");
// }
// restype = "/restype=" + _resType
// }
// $('[lay-id="/biz/list"]').find('.layui-tab-close').trigger('click');
// $(this).attr("lay-href", "/biz/list/bizId=" + _bizId + restype);
// admin.sideFlexible();*/
// }
});
//点击告警数字,跳转至告警页面
$("#indexbizhealth [data-index-banner-item='type'] .index-banner-item-tips").unbind('click').on("click", function () {
... ... @@ -563,7 +588,11 @@ layui.define(['common', 'swiper', 'admin', 'commonDetail', 'mxClient', 'sessions
type: 'custom-jump-menu-event',
message: {
'path':'',
'type':"JumpToAlarmManagement"
'type':"JumpToAlarmManagement",
params:{
"level" : level,
"restype" : _resType
}
}
}, '*')
});
... ... @@ -586,7 +615,11 @@ layui.define(['common', 'swiper', 'admin', 'commonDetail', 'mxClient', 'sessions
type: 'custom-jump-menu-event',
message: {
'path':'',
'type':"JumpToListView"
'type':"JumpToListView",
params:{
"tag":"RES",
"id":_resType
}
}
}, '*')
... ... @@ -614,11 +647,22 @@ layui.define(['common', 'swiper', 'admin', 'commonDetail', 'mxClient', 'sessions
document.body.appendChild(alink);
alink.click();
document.body.removeChild(alink);*/
var alarmLevelSelect = $('#select-content-ul .select-list.listActive').data('val');
var alarmLevelVal = '';
if (alarmLevelSelect != 4) {
alarmLevelVal = alarmLevelSelect;
} else {
alarmLevelVal = '';
}
window.top.postMessage({
type: 'custom-jump-menu-event',
message: {
'path':'',
'type':"JumpToAlarmManagement"
'type' : "JumpToAlarmManagement",
params:{
"restype" : restype,
"alarmLevelVal" : alarmLevelVal
}
}
}, '*')
});
... ...
... ... @@ -376,11 +376,7 @@
<div class="flex-bottom">
<div style="width: calc(100% - 200px);">
{{# if(d.data[0] && d.data[0].bizList ) { }}
<span class="index-banner-count">业务共 {{d.data[0].bizList.length}} </span>
{{# }else{ }}
<span class="index-banner-count">业务共 0 </span>
{{# } }}
<span class="index-banner-count">业务共 {{d.str}} </span>
</div>
<div class="div-select select-margin " style="width: 100px">
... ...