fix:修改 alertMessage 打开 新增告警静默后 无法查看详情的问题

This commit is contained in:
zhangyu
2022-07-12 17:42:01 +08:00
parent 704386dc21
commit 1b53f2beae

View File

@@ -289,8 +289,8 @@ export default {
{ name: type + '_id', value: row.id, regex: 0 }
]
} else if (type === 'alertMessage') {
if (typeof row.labels === 'string') row.labels = JSON.parse(row.labels)
const labels = JSON.parse(JSON.stringify(row.labels))
let labels = this.$loadsh.cloneDeep(row.labels)
if (typeof labels === 'string') labels = JSON.parse(labels)
this.objectSilence.matchers = []
const filterArr = ['alertname', 'severity_id', 'severity', 'rule_type']
Object.keys(labels).forEach((key, i) => {