...
|
...
|
@@ -130,6 +130,7 @@ export default { |
|
|
logMonitionVisible:false,//日志监测弹框
|
|
|
subscriptionReportVisible:false,//订阅人员弹框
|
|
|
bizName:'',//业务名称
|
|
|
ruleData:[],//故障规则定义数据
|
|
|
}
|
|
|
},
|
|
|
setup(props){
|
...
|
...
|
@@ -199,7 +200,16 @@ export default { |
|
|
{type:'log',targetId:''},
|
|
|
{type:'report',targetId:''},
|
|
|
]
|
|
|
//规则名字
|
|
|
let ruleName=Vue.ref('产生告警时触发');
|
|
|
//故障规则id
|
|
|
let ruleId=Vue.ref();
|
|
|
//模块id
|
|
|
let modleId=Vue.ref();
|
|
|
return{
|
|
|
modleId,
|
|
|
ruleId,
|
|
|
ruleName,
|
|
|
isLoading,
|
|
|
modelData,
|
|
|
faultDefinitionRadio,
|
...
|
...
|
@@ -256,6 +266,11 @@ export default { |
|
|
if(!this.isSaveModel()){
|
|
|
return;
|
|
|
}
|
|
|
this.configData.map(item=>{
|
|
|
if(item.type=='netlink'){
|
|
|
this.modleId=item.id;
|
|
|
}
|
|
|
})
|
|
|
this.hiddenAll();
|
|
|
this.networkMonitorHide = true;
|
|
|
this.isActiveIndex=index;
|
...
|
...
|
@@ -271,6 +286,11 @@ export default { |
|
|
if(!this.isSaveModel()){
|
|
|
return;
|
|
|
}
|
|
|
this.configData.map(item=>{
|
|
|
if(item.type=='npm'){
|
|
|
this.modleId=item.id;
|
|
|
}
|
|
|
})
|
|
|
this.hiddenAll();
|
|
|
this.applicationMonitorHide = true;
|
|
|
this.isActiveIndex=index;
|
...
|
...
|
@@ -285,6 +305,11 @@ export default { |
|
|
if(!this.isSaveModel()){
|
|
|
return;
|
|
|
}
|
|
|
this.configData.map(item=>{
|
|
|
if(item.type=='base'){
|
|
|
this.modleId=item.id;
|
|
|
}
|
|
|
})
|
|
|
this.postPropsData('base',index);
|
|
|
/*if(this.busTypeArr){
|
|
|
this.hiddenAll();
|
...
|
...
|
@@ -302,6 +327,11 @@ export default { |
|
|
if(!this.isSaveModel()){
|
|
|
return;
|
|
|
}
|
|
|
this.configData.map(item=>{
|
|
|
if(item.type=='apm'){
|
|
|
this.modleId=item.id;
|
|
|
}
|
|
|
})
|
|
|
this.hiddenAll();
|
|
|
this.apmMonitorHide = true;
|
|
|
this.isActiveIndex=index;
|
...
|
...
|
@@ -315,6 +345,11 @@ export default { |
|
|
if(!this.isSaveModel()){
|
|
|
return;
|
|
|
}
|
|
|
this.configData.map(item=>{
|
|
|
if(item.type=='log'){
|
|
|
this.modleId=item.id;
|
|
|
}
|
|
|
})
|
|
|
this.$global.showMsg('敬请期待...','warning');
|
|
|
return;
|
|
|
this.hiddenAll();
|
...
|
...
|
@@ -330,6 +365,11 @@ export default { |
|
|
if(!this.isSaveModel()){
|
|
|
return;
|
|
|
}
|
|
|
this.configData.map(item=>{
|
|
|
if(item.type=='report'){
|
|
|
this.modleId=item.id;
|
|
|
}
|
|
|
})
|
|
|
this.$global.showMsg('敬请期待...','warning');
|
|
|
return;
|
|
|
this.hiddenAll();
|
...
|
...
|
@@ -632,6 +672,26 @@ export default { |
|
|
}
|
|
|
|
|
|
},
|
|
|
//获取故障规则定义的详情
|
|
|
getRuleDetail(){
|
|
|
|
|
|
let that=this;
|
|
|
let params={}
|
|
|
this.$http.get('/api-web/fault/conf/rule/'+this.docId,params,function (res){
|
|
|
if(res && res.data){
|
|
|
that.ruleData=res.data;
|
|
|
if(that.ruleData.length>0){
|
|
|
that.kpiId=that.ruleData[0].kpiId;
|
|
|
that.triggerValue=that.ruleData[0].triggerValue;
|
|
|
that.ruleId=that.ruleData[0].id;
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
})
|
|
|
},
|
|
|
//保存模块类型
|
|
|
saveConfigDetail(){
|
|
|
if(!this.busTypeArr){
|
...
|
...
|
@@ -698,6 +758,7 @@ export default { |
|
|
type:this.type,
|
|
|
targetId:this.targetId,
|
|
|
state:this.state,
|
|
|
id:this.modleId,
|
|
|
faultConfig:{
|
|
|
id:this.faultConfId,
|
|
|
name:this.name,
|
...
|
...
|
@@ -804,6 +865,8 @@ export default { |
|
|
type:'alarm',
|
|
|
triggerValue: this.triggerValue,
|
|
|
kpiId: this.kpiId,
|
|
|
name:this.ruleName,
|
|
|
id:this.ruleId,
|
|
|
|
|
|
faultConfig: {
|
|
|
id: this.faultConfId,
|
...
|
...
|
@@ -834,14 +897,14 @@ export default { |
|
|
let that=this;
|
|
|
this.getTargetId('base')
|
|
|
let params={
|
|
|
targetId:this.targetId,
|
|
|
bizId:this.busTypeArr
|
|
|
// targetId:this.targetId,
|
|
|
busId:this.busTypeArr
|
|
|
}
|
|
|
this.$http.post('/api-web/fault/conf/base/saveOrUpdate',params,function (res){
|
|
|
if(res && res.success){
|
|
|
that.targetId=res.object.targetId;
|
|
|
that.targetId=res.str;
|
|
|
that.setTargetId(that.targetId)
|
|
|
// that.$global.showMsg('保存成功')
|
|
|
that.$global.showMsg('保存成功')
|
|
|
// that.alarmList=res.data;
|
|
|
that.saveConfigDetailOther();
|
|
|
}else{
|
...
|
...
|
@@ -859,7 +922,7 @@ export default { |
|
|
let params={
|
|
|
id:item.id,
|
|
|
}
|
|
|
this.$http.get('/api-web/fault/conf/netLink/deleteNetLinkAndNodeById',params,function (res){
|
|
|
that.$http.get('/api-web/fault/conf/netLink/deleteNetLinkAndNodeById',params,function (res){
|
|
|
if(res){
|
|
|
that.$global.showMsg("删除成功!");
|
|
|
that.getNetLinkList();
|
...
|
...
|
@@ -961,6 +1024,7 @@ export default { |
|
|
this.init()
|
|
|
this.getQueryKpiInfo();
|
|
|
this.getDetailByid();
|
|
|
this.getRuleDetail();
|
|
|
},
|
|
|
unmounted () {}
|
|
|
|
...
|
...
|
|