fix:修改所有的 high medium low 为 P1 P2 P3
This commit is contained in:
@@ -1198,7 +1198,7 @@ li{
|
|||||||
.dc-asset-state-out {
|
.dc-asset-state-out {
|
||||||
background-color: orange;
|
background-color: orange;
|
||||||
}
|
}
|
||||||
.dc-asset-state-high {
|
.dc-asset-state-P1 {
|
||||||
background-color: rgba(255, 0, 0, 0.6);
|
background-color: rgba(255, 0, 0, 0.6);
|
||||||
}
|
}
|
||||||
.chart-box-dropdown {
|
.chart-box-dropdown {
|
||||||
|
|||||||
@@ -74,11 +74,11 @@
|
|||||||
<span v-else>-</span>
|
<span v-else>-</span>
|
||||||
</template>
|
</template>
|
||||||
<span v-else-if="item.prop == 'severity'" class="severity">
|
<span v-else-if="item.prop == 'severity'" class="severity">
|
||||||
<span v-if="scope.row[item.prop] == 'high'" class="high">P1</span>
|
<span v-if="scope.row[item.prop] == 'P1'" class="P1">P1</span>
|
||||||
<!--<i class="nz-icon nz-icon-arrow-up"></i> {{returnSeverityLabel(scope.row[item.prop])}}-->
|
<!--<i class="nz-icon nz-icon-arrow-up"></i> {{returnSeverityLabel(scope.row[item.prop])}}-->
|
||||||
<span v-if="scope.row[item.prop] == 'medium'" class="medium">P2</span>
|
<span v-if="scope.row[item.prop] == 'P2'" class="P2">P2</span>
|
||||||
<!--{{returnSeverityLabel(scope.row[item.prop])}}-->
|
<!--{{returnSeverityLabel(scope.row[item.prop])}}-->
|
||||||
<span v-if="scope.row[item.prop] == 'low'" class="low">P3</span>
|
<span v-if="scope.row[item.prop] == 'P3'" class="P3">P3</span>
|
||||||
<!--<i class="nz-icon nz-icon-arrow-down"></i> {{returnSeverityLabel(scope.row[item.prop])}}-->
|
<!--<i class="nz-icon nz-icon-arrow-down"></i> {{returnSeverityLabel(scope.row[item.prop])}}-->
|
||||||
</span>
|
</span>
|
||||||
<template v-else-if="item.prop == 'labels'" class="labels">
|
<template v-else-if="item.prop == 'labels'" class="labels">
|
||||||
@@ -825,7 +825,7 @@
|
|||||||
? JSON.parse(localStorage.getItem("nz-tableTitle-" + localStorage.getItem("nz-username") + "-" + '/alertList'))
|
? JSON.parse(localStorage.getItem("nz-tableTitle-" + localStorage.getItem("nz-username") + "-" + '/alertList'))
|
||||||
: this.tableTitle;
|
: this.tableTitle;
|
||||||
|
|
||||||
console.info(this.tools.customTableTitle)
|
// console.info(this.tools.customTableTitle)
|
||||||
//是否存在分页缓存
|
//是否存在分页缓存
|
||||||
let pageSize = localStorage.getItem('nz-pageSize-' + localStorage.getItem('nz-username') + '-' + this.tableId);
|
let pageSize = localStorage.getItem('nz-pageSize-' + localStorage.getItem('nz-username') + '-' + this.tableId);
|
||||||
if (pageSize != 'undefined' && pageSize != null) {
|
if (pageSize != 'undefined' && pageSize != null) {
|
||||||
@@ -938,25 +938,30 @@
|
|||||||
.pointer{
|
.pointer{
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
}
|
}
|
||||||
.severity .high{
|
.severity .P1{
|
||||||
background: #F5846A;
|
background: #F5846A;
|
||||||
border-radius: 2px;
|
border-radius: 2px;
|
||||||
font-size: 12px;
|
font-size: 12px;
|
||||||
color: #FFFFFF;
|
color: #FFFFFF;
|
||||||
padding: 2px 6px;
|
padding: 2px 6px;
|
||||||
}
|
}
|
||||||
.severity .medium{
|
.severity .P2{
|
||||||
background: #F7A54A;
|
background: #F7A54A;
|
||||||
border-radius: 2px;
|
border-radius: 2px;
|
||||||
font-size: 12px;
|
font-size: 12px;
|
||||||
color: #FFFFFF;
|
color: #FFFFFF;
|
||||||
padding: 2px 6px;
|
padding: 2px 6px;
|
||||||
}
|
}
|
||||||
.severity .low{
|
.severity .P3{
|
||||||
background: #F1C13D;
|
background: #F1C13D;
|
||||||
border-radius: 2px;
|
border-radius: 2px;
|
||||||
font-size: 12px;
|
font-size: 12px;
|
||||||
color: #FFFFFF;
|
color: #FFFFFF;
|
||||||
padding: 2px 6px;
|
padding: 2px 6px;
|
||||||
}
|
}
|
||||||
|
.red,.green{
|
||||||
|
color: white;
|
||||||
|
padding: 2px 5px;
|
||||||
|
border-radius: 4px;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|||||||
@@ -16,9 +16,9 @@
|
|||||||
<div class="alert-rule-box">
|
<div class="alert-rule-box">
|
||||||
<div class="alert-rule-title">Level</div>
|
<div class="alert-rule-title">Level</div>
|
||||||
<div class="alert-rule-value">
|
<div class="alert-rule-value">
|
||||||
<span v-if="alertRuleData && alertRuleData.severity === 'high'"><i class="nz-icon nz-icon-arrow-up"></i> {{$CONSTANTS.alertMessage.severityData.find(s => {return s.value == 'high'}).label}}</span>
|
<span v-if="alertRuleData && alertRuleData.severity === 'P1'"><i class="nz-icon nz-icon-arrow-up"></i> {{$CONSTANTS.alertMessage.severityData.find(s => {return s.value == 'P1'}).label}}</span>
|
||||||
<span style="padding-left: 18px;" v-if="alertRuleData && alertRuleData.severity === 'medium'">{{$CONSTANTS.alertMessage.severityData.find(s => {return s.value == 'medium'}).label}}</span>
|
<span style="padding-left: 18px;" v-if="alertRuleData && alertRuleData.severity === 'P2'">{{$CONSTANTS.alertMessage.severityData.find(s => {return s.value == 'P2'}).label}}</span>
|
||||||
<span v-if="alertRuleData && alertRuleData.severity === 'low'"><i class="nz-icon nz-icon-arrow-down"></i> {{$CONSTANTS.alertMessage.severityData.find(s => {return s.value == 'low'}).label}}</span>
|
<span v-if="alertRuleData && alertRuleData.severity === 'P3'"><i class="nz-icon nz-icon-arrow-down"></i> {{$CONSTANTS.alertMessage.severityData.find(s => {return s.value == 'P3'}).label}}</span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -58,12 +58,12 @@
|
|||||||
placement="top-start"
|
placement="top-start"
|
||||||
offset="-128"
|
offset="-128"
|
||||||
trigger="hover"
|
trigger="hover"
|
||||||
:content="$t('overall.result.total') + ':' + scope.row.alertStat.total + ',' + $t('alert.config.high') + ':' + scope.row.alertStat.high + ',' + $t('alert.config.medium') + ':' + scope.row.alertStat.medium+ ',' + $t('alert.config.low') + ':' + scope.row.alertStat.low">
|
:content="$t('overall.result.total') + ':' + scope.row.alertStat.total + ',' + $t('alert.config.P1') + ':' + scope.row.alertStat.P1 + ',' + $t('alert.config.P2') + ':' + scope.row.alertStat.P2+ ',' + $t('alert.config.P3') + ':' + scope.row.alertStat.P3">
|
||||||
<div slot="reference" class="dc-asset-states">
|
<div slot="reference" class="dc-asset-states">
|
||||||
<span class="dc-asset-state dc-asset-state-total">{{scope.row.alertStat.total}}</span>
|
<span class="dc-asset-state dc-asset-state-total">{{scope.row.alertStat.total}}</span>
|
||||||
<span class="dc-asset-state dc-asset-state-high">{{scope.row.alertStat.high}}</span>
|
<span class="dc-asset-state dc-asset-state-P1">{{scope.row.alertStat.P1}}</span>
|
||||||
<span class="dc-asset-state dc-asset-state-out">{{scope.row.alertStat.medium}}</span>
|
<span class="dc-asset-state dc-asset-state-out">{{scope.row.alertStat.P2}}</span>
|
||||||
<span class="dc-asset-state dc-asset-state-in">{{scope.row.alertStat.low}}</span>
|
<span class="dc-asset-state dc-asset-state-in">{{scope.row.alertStat.P3}}</span>
|
||||||
</div>
|
</div>
|
||||||
</el-popover>
|
</el-popover>
|
||||||
</template >
|
</template >
|
||||||
|
|||||||
@@ -97,9 +97,9 @@ export const asset = {
|
|||||||
|
|
||||||
export const alertMessage = {
|
export const alertMessage = {
|
||||||
severityData: [
|
severityData: [
|
||||||
{value: 'medium', label: i18n.t("alert.config.medium")},
|
{value: 'P2', label: i18n.t("alert.config.P2")},
|
||||||
{value: 'high', label: i18n.t("alert.config.high")},
|
{value: 'P1', label: i18n.t("alert.config.P1")},
|
||||||
{value: 'low', label: i18n.t("alert.config.low")}
|
{value: 'P3', label: i18n.t("alert.config.P3")}
|
||||||
],
|
],
|
||||||
typeData: [
|
typeData: [
|
||||||
{value: 1, label: i18n.t('alert.config.typeOption.project')},
|
{value: 1, label: i18n.t('alert.config.typeOption.project')},
|
||||||
@@ -107,9 +107,9 @@ export const alertMessage = {
|
|||||||
{value: 3, label: i18n.t('alert.config.typeOption.asset')}
|
{value: 3, label: i18n.t('alert.config.typeOption.asset')}
|
||||||
],
|
],
|
||||||
levels:[
|
levels:[
|
||||||
{value: 'medium', label: i18n.t("alert.config.medium")},
|
{value: 'P2', label: i18n.t("alert.config.P2")},
|
||||||
{value: 'high', label: i18n.t("alert.config.high")},
|
{value: 'P1', label: i18n.t("alert.config.P1")},
|
||||||
{value: 'low', label: i18n.t("alert.config.low")}
|
{value: 'P3', label: i18n.t("alert.config.P3")}
|
||||||
],
|
],
|
||||||
states:[
|
states:[
|
||||||
{value: '1', label: i18n.t('alert.list.pending')},
|
{value: '1', label: i18n.t('alert.list.pending')},
|
||||||
|
|||||||
@@ -275,9 +275,9 @@ const cn = {
|
|||||||
num: "数量",
|
num: "数量",
|
||||||
alert: "告警",
|
alert: "告警",
|
||||||
alertTotal: "总计",
|
alertTotal: "总计",
|
||||||
alertLow: "低",
|
alertP3: "P3",
|
||||||
alertMedium: "中",
|
alertP2: "P2",
|
||||||
alertHigh: "高",
|
alertP1: "P1",
|
||||||
inStock: "在库",
|
inStock: "在库",
|
||||||
outStock: "出库",
|
outStock: "出库",
|
||||||
pingUp: "Up",
|
pingUp: "Up",
|
||||||
@@ -329,9 +329,9 @@ const cn = {
|
|||||||
active: "在线",
|
active: "在线",
|
||||||
inactive: "宕机",
|
inactive: "宕机",
|
||||||
alert: "告警",
|
alert: "告警",
|
||||||
high: "高",
|
P1: "P1",
|
||||||
medium: "中",
|
P2: "P2",
|
||||||
low: "低",
|
P3: "P3",
|
||||||
endpoint: "Endpoint",
|
endpoint: "Endpoint",
|
||||||
total: "总计",
|
total: "总计",
|
||||||
up: "up",
|
up: "up",
|
||||||
@@ -767,9 +767,9 @@ const cn = {
|
|||||||
alertConfig: "告警规则",
|
alertConfig: "告警规则",
|
||||||
createAlertConfig: "新增告警规则",
|
createAlertConfig: "新增告警规则",
|
||||||
editAlertConfig: "修改告警规则",
|
editAlertConfig: "修改告警规则",
|
||||||
medium: "中",
|
P1: "P1",
|
||||||
high: "高",
|
P2: "P2",
|
||||||
low: "低",
|
P3: "P3",
|
||||||
typeOption: {
|
typeOption: {
|
||||||
project: "系统",
|
project: "系统",
|
||||||
module: "组件",
|
module: "组件",
|
||||||
|
|||||||
@@ -182,7 +182,7 @@ const en = {
|
|||||||
param:'Parameters',
|
param:'Parameters',
|
||||||
select:'Select',
|
select:'Select',
|
||||||
alertRule:'Alert rule',
|
alertRule:'Alert rule',
|
||||||
level:'Level',
|
level:'Priority',
|
||||||
state:'State'
|
state:'State'
|
||||||
},
|
},
|
||||||
valMapping:{
|
valMapping:{
|
||||||
@@ -280,9 +280,9 @@ const en = {
|
|||||||
num:'Num',
|
num:'Num',
|
||||||
alert:'Alert',
|
alert:'Alert',
|
||||||
alertTotal:'Total',
|
alertTotal:'Total',
|
||||||
alertLow:'Low',
|
alertP3:'P3',
|
||||||
alertMedium:'Medium',
|
alertP2:'P2',
|
||||||
alertHigh:'High',
|
alertP1:'P1',
|
||||||
inStock:'In stock',
|
inStock:'In stock',
|
||||||
outStock:'Out stock',
|
outStock:'Out stock',
|
||||||
pingUp:'Up',
|
pingUp:'Up',
|
||||||
@@ -313,7 +313,7 @@ const en = {
|
|||||||
},
|
},
|
||||||
alert:{
|
alert:{
|
||||||
alertMessage: 'Alert messages',
|
alertMessage: 'Alert messages',
|
||||||
level:'Level',
|
level:'Priority',
|
||||||
alertRule:'Alert rule',
|
alertRule:'Alert rule',
|
||||||
ruleNum:'Rule num',
|
ruleNum:'Rule num',
|
||||||
alertNum:'Alert num',
|
alertNum:'Alert num',
|
||||||
@@ -334,9 +334,9 @@ const en = {
|
|||||||
active:'active',
|
active:'active',
|
||||||
inactive:'inactive',
|
inactive:'inactive',
|
||||||
alert:'alert',
|
alert:'alert',
|
||||||
high:'high',
|
P1: "P1",
|
||||||
medium:'medium',
|
P2: "P2",
|
||||||
low:'low',
|
P3: "P3",
|
||||||
endpoint:'endpoint',
|
endpoint:'endpoint',
|
||||||
total:'total',
|
total:'total',
|
||||||
up:'up',
|
up:'up',
|
||||||
@@ -743,7 +743,7 @@ const en = {
|
|||||||
alertList: 'Alert message',//"告警信息"
|
alertList: 'Alert message',//"告警信息"
|
||||||
alertConfig: 'Alert rule',//"告警规则"
|
alertConfig: 'Alert rule',//"告警规则"
|
||||||
alertName: 'Alert name',//"告警名称"
|
alertName: 'Alert name',//"告警名称"
|
||||||
severity: 'Level',//"等级"
|
severity: 'Priority',//"等级"
|
||||||
description: 'Description',//"描述"
|
description: 'Description',//"描述"
|
||||||
summary: 'Summary',//"概要"
|
summary: 'Summary',//"概要"
|
||||||
startAt: 'Start time',//"开始时间"
|
startAt: 'Start time',//"开始时间"
|
||||||
@@ -774,10 +774,10 @@ const en = {
|
|||||||
alertConfig: 'Alert rule',//"告警规则"
|
alertConfig: 'Alert rule',//"告警规则"
|
||||||
createAlertConfig: 'New alert rule',//"新增告警规则"
|
createAlertConfig: 'New alert rule',//"新增告警规则"
|
||||||
editAlertConfig: 'Edit alert rule',//"修改告警规则"
|
editAlertConfig: 'Edit alert rule',//"修改告警规则"
|
||||||
medium: 'Medium',//"中"
|
|
||||||
alertNum: 'Alert number', //告警信息数量
|
alertNum: 'Alert number', //告警信息数量
|
||||||
high: 'High',//"高"
|
P1: "P1",
|
||||||
low: 'Low',//"低"
|
P2: "P2",
|
||||||
|
P3: "P3",
|
||||||
typeOption: {
|
typeOption: {
|
||||||
project: 'Project',//'系统'
|
project: 'Project',//'系统'
|
||||||
module: 'Module',//'组件'
|
module: 'Module',//'组件'
|
||||||
|
|||||||
@@ -32,16 +32,16 @@
|
|||||||
<div class="main-box-title">Alert messages</div>
|
<div class="main-box-title">Alert messages</div>
|
||||||
<div class="main-box-content">
|
<div class="main-box-content">
|
||||||
<div class="content-box">
|
<div class="content-box">
|
||||||
<span class="content-title"><i class="nz-icon nz-icon-jiantou-top colorFFF bg23BF9A"></i>high</span>
|
<span class="content-title"><i class="nz-icon nz-icon-jiantou-top colorFFF bg23BF9A"></i>P1</span>
|
||||||
<span class="float-right">{{moduleInfo.alertStat.high}}</span>
|
<span class="float-right">{{moduleInfo.alertStat.P1}}</span>
|
||||||
</div>
|
</div>
|
||||||
<div class="content-box">
|
<div class="content-box">
|
||||||
<span class="content-title"><i class="nz-icon nz-icon-jiantou-right colorFFF bg3C92F1"></i>medium</span>
|
<span class="content-title"><i class="nz-icon nz-icon-jiantou-right colorFFF bg3C92F1"></i>P2</span>
|
||||||
<span class="float-right">{{moduleInfo.alertStat.medium}}</span>
|
<span class="float-right">{{moduleInfo.alertStat.P2}}</span>
|
||||||
</div>
|
</div>
|
||||||
<div class="content-box">
|
<div class="content-box">
|
||||||
<span class="content-title"><i class="nz-icon nz-icon-jiantou-down colorFFF bgEC7F66"></i>low</span>
|
<span class="content-title"><i class="nz-icon nz-icon-jiantou-down colorFFF bgEC7F66"></i>P3</span>
|
||||||
<span class="float-right">{{moduleInfo.alertStat.low}}</span>
|
<span class="float-right">{{moduleInfo.alertStat.P3}}</span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@@ -64,9 +64,9 @@
|
|||||||
return{
|
return{
|
||||||
moduleInfo:{
|
moduleInfo:{
|
||||||
alertStat:{
|
alertStat:{
|
||||||
high:0,
|
P1:0,
|
||||||
low:0,
|
P3:0,
|
||||||
medium:0,
|
P2:0,
|
||||||
},
|
},
|
||||||
assetStat:{
|
assetStat:{
|
||||||
down:0,
|
down:0,
|
||||||
|
|||||||
@@ -85,11 +85,11 @@
|
|||||||
<span v-else>-</span>
|
<span v-else>-</span>
|
||||||
</template>
|
</template>
|
||||||
<span v-else-if="item.prop == 'severity'" class="severity">
|
<span v-else-if="item.prop == 'severity'" class="severity">
|
||||||
<span v-if="scope.row[item.prop] == 'high'" class="high">P1</span>
|
<span v-if="scope.row[item.prop] == 'P1'" class="P1">P1</span>
|
||||||
<!--<i class="nz-icon nz-icon-arrow-up"></i> {{returnSeverityLabel(scope.row[item.prop])}}-->
|
<!--<i class="nz-icon nz-icon-arrow-up"></i> {{returnSeverityLabel(scope.row[item.prop])}}-->
|
||||||
<span v-if="scope.row[item.prop] == 'medium'" class="medium">P2</span>
|
<span v-if="scope.row[item.prop] == 'P2'" class="P2">P2</span>
|
||||||
<!--{{returnSeverityLabel(scope.row[item.prop])}}-->
|
<!--{{returnSeverityLabel(scope.row[item.prop])}}-->
|
||||||
<span v-if="scope.row[item.prop] == 'low'" class="low">P3</span>
|
<span v-if="scope.row[item.prop] == 'P3'" class="P3">P3</span>
|
||||||
<!--<i class="nz-icon nz-icon-arrow-down"></i> {{returnSeverityLabel(scope.row[item.prop])}}-->
|
<!--<i class="nz-icon nz-icon-arrow-down"></i> {{returnSeverityLabel(scope.row[item.prop])}}-->
|
||||||
</span>
|
</span>
|
||||||
<template v-else-if="item.prop == 'labels'" class="labels">
|
<template v-else-if="item.prop == 'labels'" class="labels">
|
||||||
@@ -514,21 +514,21 @@
|
|||||||
padding: 2px 5px;
|
padding: 2px 5px;
|
||||||
border-radius: 4px;
|
border-radius: 4px;
|
||||||
}
|
}
|
||||||
.severity .high{
|
.severity .P1{
|
||||||
background: #F5846A;
|
background: #F5846A;
|
||||||
border-radius: 2px;
|
border-radius: 2px;
|
||||||
font-size: 12px;
|
font-size: 12px;
|
||||||
color: #FFFFFF;
|
color: #FFFFFF;
|
||||||
padding: 2px 6px;
|
padding: 2px 6px;
|
||||||
}
|
}
|
||||||
.severity .medium{
|
.severity .P2{
|
||||||
background: #F7A54A;
|
background: #F7A54A;
|
||||||
border-radius: 2px;
|
border-radius: 2px;
|
||||||
font-size: 12px;
|
font-size: 12px;
|
||||||
color: #FFFFFF;
|
color: #FFFFFF;
|
||||||
padding: 2px 6px;
|
padding: 2px 6px;
|
||||||
}
|
}
|
||||||
.severity .low{
|
.severity .P3{
|
||||||
background: #F1C13D;
|
background: #F1C13D;
|
||||||
border-radius: 2px;
|
border-radius: 2px;
|
||||||
font-size: 12px;
|
font-size: 12px;
|
||||||
|
|||||||
@@ -641,7 +641,7 @@
|
|||||||
obj.error=true;
|
obj.error=true;
|
||||||
obj.endpointError=true;
|
obj.endpointError=true;
|
||||||
}
|
}
|
||||||
if(item.state.alertStat.high> 0 || item.state.alertStat.low>0 || item.state.alertStat.medium>0){
|
if(item.state.alertStat.P1> 0 || item.state.alertStat.P3>0 || item.state.alertStat.P2>0){
|
||||||
obj.error=true;
|
obj.error=true;
|
||||||
obj.alertError=true;
|
obj.alertError=true;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -66,24 +66,24 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="facade-top-right-content">
|
<div class="facade-top-right-content">
|
||||||
<div>
|
<div>
|
||||||
<div class="content-high-title">
|
<div class="content-P1-title">
|
||||||
{{returnSeverityLabel('high')}}
|
{{returnSeverityLabel('P1')}}
|
||||||
</div>
|
</div>
|
||||||
<div>
|
<div>
|
||||||
{{projectInfo.alertStat[0] || 0}}
|
{{projectInfo.alertStat[0] || 0}}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div>
|
<div>
|
||||||
<div class="content-medium-title">
|
<div class="content-P2-title">
|
||||||
{{returnSeverityLabel('medium')}}
|
{{returnSeverityLabel('P2')}}
|
||||||
</div>
|
</div>
|
||||||
<div>
|
<div>
|
||||||
{{projectInfo.alertStat[1] || 0}}
|
{{projectInfo.alertStat[1] || 0}}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div style="margin-bottom: 20px;">
|
<div style="margin-bottom: 20px;">
|
||||||
<div class="content-low-title">
|
<div class="content-P3-title">
|
||||||
{{returnSeverityLabel('low')}}
|
{{returnSeverityLabel('P3')}}
|
||||||
</div>
|
</div>
|
||||||
<div>
|
<div>
|
||||||
{{projectInfo.alertStat[2] || 0}}
|
{{projectInfo.alertStat[2] || 0}}
|
||||||
@@ -451,6 +451,7 @@
|
|||||||
color: #fff;
|
color: #fff;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
margin-bottom: 5px;
|
margin-bottom: 5px;
|
||||||
|
line-height: 22px;
|
||||||
}
|
}
|
||||||
.facade-top-right-content > div > div:last-child{
|
.facade-top-right-content > div > div:last-child{
|
||||||
text-align: center;
|
text-align: center;
|
||||||
@@ -458,44 +459,44 @@
|
|||||||
flex: 1;
|
flex: 1;
|
||||||
height: calc(100% - 2px);
|
height: calc(100% - 2px);
|
||||||
}
|
}
|
||||||
.content-high-title{
|
.content-P1-title{
|
||||||
background: #F2866E;
|
background: #F2866E;
|
||||||
border-radius: 4px 0 0 4px;
|
border-radius: 4px 0 0 4px;
|
||||||
width: 54px;
|
width: 54px;
|
||||||
height: 100%;
|
height: 100%;
|
||||||
}
|
}
|
||||||
.content-high-title + div{
|
.content-P1-title + div{
|
||||||
border: 1px solid #F4907A;
|
border: 1px solid #F4907A;
|
||||||
font-size: 12px;
|
font-size: 12px;
|
||||||
color: #F4907A;
|
color: #F4907A;
|
||||||
}
|
}
|
||||||
|
|
||||||
.content-medium-title{
|
.content-P2-title{
|
||||||
background: #F89984;
|
background: #F89984;
|
||||||
border-radius: 4px 0 0 4px;
|
border-radius: 4px 0 0 4px;
|
||||||
width: 54px;
|
width: 54px;
|
||||||
height: 100%;
|
height: 100%;
|
||||||
}
|
}
|
||||||
.content-medium-title + div{
|
.content-P2-title + div{
|
||||||
border: 1px solid #F9A28F;
|
border: 1px solid #F9A28F;
|
||||||
font-size: 12px;
|
font-size: 12px;
|
||||||
color: #F9A28F;
|
color: #F9A28F;
|
||||||
}
|
}
|
||||||
|
|
||||||
.content-low-title{
|
.content-P3-title{
|
||||||
background: #F7BA78;
|
background: #F7BA78;
|
||||||
border-radius: 4px 0 0 4px;
|
border-radius: 4px 0 0 4px;
|
||||||
width: 54px;
|
width: 54px;
|
||||||
height: 100%;
|
height: 100%;
|
||||||
}
|
}
|
||||||
.content-low-title + div{
|
.content-P3-title + div{
|
||||||
border: 1px solid #F7BA78;
|
border: 1px solid #F7BA78;
|
||||||
font-size: 12px;
|
font-size: 12px;
|
||||||
color: #F7BA78;
|
color: #F7BA78;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
.right-content-high{
|
.right-content-P1{
|
||||||
border: 1px solid ;
|
border: 1px solid ;
|
||||||
}
|
}
|
||||||
.align--center{
|
.align--center{
|
||||||
|
|||||||
@@ -3,16 +3,16 @@
|
|||||||
const searchSelectInfo = { // value: 传给后台的值;label:显示给用户看的值
|
const searchSelectInfo = { // value: 传给后台的值;label:显示给用户看的值
|
||||||
severity: [ //告警级别
|
severity: [ //告警级别
|
||||||
{
|
{
|
||||||
value: 'medium',
|
value: 'P2',
|
||||||
label: i18n.t("alert.config.medium")
|
label: i18n.t("alert.config.P2")
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
value: 'high',
|
value: 'P1',
|
||||||
label: i18n.t("alert.config.high")
|
label: i18n.t("alert.config.P1")
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
value: 'low',
|
value: 'P3',
|
||||||
label: i18n.t("alert.config.low")
|
label: i18n.t("alert.config.P3")
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
promType: [ //promServer类型
|
promType: [ //promServer类型
|
||||||
|
|||||||
@@ -2,21 +2,21 @@
|
|||||||
.config {
|
.config {
|
||||||
height: 100%;
|
height: 100%;
|
||||||
}
|
}
|
||||||
.severity .high{
|
.severity .P1{
|
||||||
background: #F5846A;
|
background: #F5846A;
|
||||||
border-radius: 2px;
|
border-radius: 2px;
|
||||||
font-size: 12px;
|
font-size: 12px;
|
||||||
color: #FFFFFF;
|
color: #FFFFFF;
|
||||||
padding: 2px 6px;
|
padding: 2px 6px;
|
||||||
}
|
}
|
||||||
.severity .medium{
|
.severity .P2{
|
||||||
background: #F7A54A;
|
background: #F7A54A;
|
||||||
border-radius: 2px;
|
border-radius: 2px;
|
||||||
font-size: 12px;
|
font-size: 12px;
|
||||||
color: #FFFFFF;
|
color: #FFFFFF;
|
||||||
padding: 2px 6px;
|
padding: 2px 6px;
|
||||||
}
|
}
|
||||||
.severity .low{
|
.severity .P3{
|
||||||
background: #F1C13D;
|
background: #F1C13D;
|
||||||
border-radius: 2px;
|
border-radius: 2px;
|
||||||
font-size: 12px;
|
font-size: 12px;
|
||||||
@@ -96,11 +96,11 @@
|
|||||||
<span :title="$t('overall.delete')" @click="del(scope.row)" class="content-right-option" :id="'alert-del-'+scope.row.id"><i class="nz-icon nz-icon-delete"></i></span>
|
<span :title="$t('overall.delete')" @click="del(scope.row)" class="content-right-option" :id="'alert-del-'+scope.row.id"><i class="nz-icon nz-icon-delete"></i></span>
|
||||||
</div>
|
</div>
|
||||||
<span v-else-if="item.prop == 'severity'" class="severity">
|
<span v-else-if="item.prop == 'severity'" class="severity">
|
||||||
<span v-if="scope.row[item.prop] == 'high'" class="high">P1</span>
|
<span v-if="scope.row[item.prop] == 'P1'" class="P1">P1</span>
|
||||||
<!--<i class="nz-icon nz-icon-arrow-up"></i> {{returnSeverityLabel(scope.row[item.prop])}}-->
|
<!--<i class="nz-icon nz-icon-arrow-up"></i> {{returnSeverityLabel(scope.row[item.prop])}}-->
|
||||||
<span v-if="scope.row[item.prop] == 'medium'" class="medium">P2</span>
|
<span v-if="scope.row[item.prop] == 'P2'" class="P2">P2</span>
|
||||||
<!--{{returnSeverityLabel(scope.row[item.prop])}}-->
|
<!--{{returnSeverityLabel(scope.row[item.prop])}}-->
|
||||||
<span v-if="scope.row[item.prop] == 'low'" class="low">P3</span>
|
<span v-if="scope.row[item.prop] == 'P3'" class="P3">P3</span>
|
||||||
<!--<i class="nz-icon nz-icon-arrow-down"></i> {{returnSeverityLabel(scope.row[item.prop])}}-->
|
<!--<i class="nz-icon nz-icon-arrow-down"></i> {{returnSeverityLabel(scope.row[item.prop])}}-->
|
||||||
</span>
|
</span>
|
||||||
<template v-else-if="item.prop == 'alertNum'">
|
<template v-else-if="item.prop == 'alertNum'">
|
||||||
@@ -189,7 +189,7 @@
|
|||||||
unit:2,
|
unit:2,
|
||||||
operator: '>',
|
operator: '>',
|
||||||
last: 60,
|
last: 60,
|
||||||
severity: 'medium',
|
severity: 'P2',
|
||||||
summary: '',
|
summary: '',
|
||||||
description: '',
|
description: '',
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -175,7 +175,7 @@
|
|||||||
formatAssetData:function(data,totalData){
|
formatAssetData:function(data,totalData){
|
||||||
if(data && totalData){
|
if(data && totalData){
|
||||||
data=data.map((item)=>{
|
data=data.map((item)=>{
|
||||||
item.alertInfo=`<span style="color: #FE6565;">${item.alertHigh}</span>/<span style="color: orange;">${item.alertMedium}</span>/<span style="color: #90ee90">${item.alertLow}</span>`;
|
item.alertInfo=`<span style="color: #FE6565;">${item.alertP1}</span>/<span style="color: orange;">${item.alertP2}</span>/<span style="color: #90ee90">${item.alertP3}</span>`;
|
||||||
return item;
|
return item;
|
||||||
})
|
})
|
||||||
let assetStatData={
|
let assetStatData={
|
||||||
@@ -203,16 +203,16 @@
|
|||||||
value:totalData.outStock
|
value:totalData.outStock
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label:this.$t('dashboard.overview.asset.alertLow'),
|
label:this.$t('dashboard.overview.asset.alertP3'),
|
||||||
value:totalData.alertLow
|
value:totalData.alertP3
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label:this.$t('dashboard.overview.asset.alertMedium'),
|
label:this.$t('dashboard.overview.asset.alertP2'),
|
||||||
value:totalData.alertMedium
|
value:totalData.alertP2
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label:this.$t('dashboard.overview.asset.alertHigh'),
|
label:this.$t('dashboard.overview.asset.alertP1'),
|
||||||
value:totalData.alertHigh
|
value:totalData.alertP1
|
||||||
},
|
},
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
@@ -267,16 +267,16 @@
|
|||||||
prop:'alertTotal'
|
prop:'alertTotal'
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label:this.$t('dashboard.overview.asset.alertLow'),
|
label:this.$t('dashboard.overview.asset.alertP3'),
|
||||||
prop:'alertLow'
|
prop:'alertP3'
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label:this.$t('dashboard.overview.asset.alertMedium'),
|
label:this.$t('dashboard.overview.asset.alertP2'),
|
||||||
prop:'alertMedium'
|
prop:'alertP2'
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label:this.$t('dashboard.overview.asset.alertHigh'),
|
label:this.$t('dashboard.overview.asset.alertP1'),
|
||||||
prop:'alertHigh'
|
prop:'alertP1'
|
||||||
},
|
},
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
@@ -516,16 +516,16 @@
|
|||||||
showPopover: true,
|
showPopover: true,
|
||||||
popover: [
|
popover: [
|
||||||
{
|
{
|
||||||
label:this.$t('dashboard.overview.asset.alertLow'),
|
label:this.$t('dashboard.overview.asset.alertP3'),
|
||||||
prop:'alertLow'
|
prop:'alertP3'
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label:this.$t('dashboard.overview.asset.alertMedium'),
|
label:this.$t('dashboard.overview.asset.alertP2'),
|
||||||
prop:'alertMedium'
|
prop:'alertP2'
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label:this.$t('dashboard.overview.asset.alertHigh'),
|
label:this.$t('dashboard.overview.asset.alertP1'),
|
||||||
prop:'alertHigh'
|
prop:'alertP1'
|
||||||
},
|
},
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
@@ -893,16 +893,16 @@
|
|||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td rowspan="3">${this.$t('dashboard.overview.mapTooltip.alert')}</td>
|
<td rowspan="3">${this.$t('dashboard.overview.mapTooltip.alert')}</td>
|
||||||
<td >${this.$t('dashboard.overview.mapTooltip.high')}</td>
|
<td >${this.$t('dashboard.overview.mapTooltip.P1')}</td>
|
||||||
<td >${dcStat.alertHigh}</td>
|
<td >${dcStat.alertP1}</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td >${this.$t('dashboard.overview.mapTooltip.medium')}</td>
|
<td >${this.$t('dashboard.overview.mapTooltip.P2')}</td>
|
||||||
<td >${dcStat.alertMedium}</td>
|
<td >${dcStat.alertP2}</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td >${this.$t('dashboard.overview.mapTooltip.low')}</td>
|
<td >${this.$t('dashboard.overview.mapTooltip.P3')}</td>
|
||||||
<td >${dcStat.alertLow}</td>
|
<td >${dcStat.alertP3}</td>
|
||||||
</tr>
|
</tr>
|
||||||
</table>
|
</table>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -988,16 +988,16 @@
|
|||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td rowspan="3">${this.$t('dashboard.overview.mapTooltip.alert')}</td>
|
<td rowspan="3">${this.$t('dashboard.overview.mapTooltip.alert')}</td>
|
||||||
<td >${this.$t('dashboard.overview.mapTooltip.high')}</td>
|
<td >${this.$t('dashboard.overview.mapTooltip.P1')}</td>
|
||||||
<td >${dcStat.alertHigh}</td>
|
<td >${dcStat.alertP1}</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td >${this.$t('dashboard.overview.mapTooltip.medium')}</td>
|
<td >${this.$t('dashboard.overview.mapTooltip.P2')}</td>
|
||||||
<td >${dcStat.alertMedium}</td>
|
<td >${dcStat.alertP2}</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td >${this.$t('dashboard.overview.mapTooltip.low')}</td>
|
<td >${this.$t('dashboard.overview.mapTooltip.P3')}</td>
|
||||||
<td >${dcStat.alertLow}</td>
|
<td >${dcStat.alertP3}</td>
|
||||||
</tr>
|
</tr>
|
||||||
</table>
|
</table>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
Reference in New Issue
Block a user