NEZ-947 feat;alert rule增加 state 页面开发

This commit is contained in:
zhangyu
2021-08-30 15:02:44 +08:00
parent 780b119c61
commit 8ce2075eb1
3 changed files with 42 additions and 3 deletions

View File

@@ -49,6 +49,7 @@
@queryMessage="queryMessage"
@reload="getTableData"
@addSilence="addSilence"
@statusChange='statusChange'
@selectionChange="selectionChange"
@showBottomBox="(targetTab, object) => { $refs.dataList.showBottomBox(targetTab, object) }"></alert-rule-table>
</template>
@@ -179,6 +180,18 @@ export default {
}
})
},
statusChange (alertRule) {
const params = { ...alertRule, severity: null }
this.$put(this.url, params).then(response => {
if (response.code === 200) {
this.rightBox.show = false
this.$message({ duration: 1000, type: 'success', message: this.$t('tip.saveSuccess') })
} else {
this.$message.error(response.msg)
}
this.getTableData()
})
},
edit (u, copyFlag) {
this.$get(`${this.url}/${u.id}`).then(response => {
if (response.code === 200) {