前端更新 (#192)

* fix:add package

* fix:notice_info为null的情况

* fix:2 bugs

* feat:1.common增加通知配置 2.cmdb预定义值webhook&其他模型

* fix:json 不支持预定义值

* fix:json 不支持预定义值

* fix:删除代码
This commit is contained in:
wang-liang0615 2023-10-09 19:52:19 +08:00 committed by GitHub
parent dd8f66a3fa
commit 17b27d492a
2 changed files with 4 additions and 14 deletions

View File

@ -205,11 +205,3 @@ export function ciTypeFilterPermissions(type_id) {
method: 'get', method: 'get',
}) })
} }
export function getAllDagsName(params) {
return axios({
url: '/v1/dag/all_names',
method: 'GET',
params: params
})
}

View File

@ -256,7 +256,7 @@
<script> <script>
import _ from 'lodash' import _ from 'lodash'
import { addTrigger, updateTrigger, deleteTrigger, getAllDagsName } from '../../api/CIType' import { addTrigger, updateTrigger, deleteTrigger } from '../../api/CIType'
import FilterComp from '@/components/CMDBFilterComp' import FilterComp from '@/components/CMDBFilterComp'
import EmployeeTreeSelect from '@/views/setting/components/employeeTreeSelect.vue' import EmployeeTreeSelect from '@/views/setting/components/employeeTreeSelect.vue'
import Webhook from '../../components/webhook' import Webhook from '../../components/webhook'
@ -346,9 +346,9 @@ export default {
}, },
mounted() {}, mounted() {},
methods: { methods: {
async getDags() { async getNoticeConfigAppBot() {
await getAllDagsName().then((res) => { await getNoticeConfigAppBot().then((res) => {
this.dags = res.map((dag) => ({ id: dag[1], label: dag[0] })) this.appBot = res
}) })
}, },
async getNoticeConfigAppBot() { async getNoticeConfigAppBot() {
@ -358,7 +358,6 @@ export default {
}, },
createFromTriggerTable(attrList) { createFromTriggerTable(attrList) {
this.visible = true this.visible = true
this.getDags()
this.getNoticeConfigAppBot() this.getNoticeConfigAppBot()
this.attrList = attrList this.attrList = attrList
this.triggerId = null this.triggerId = null
@ -378,7 +377,6 @@ export default {
}, },
async open(property, attrList) { async open(property, attrList) {
this.visible = true this.visible = true
await this.getDags()
this.getNoticeConfigAppBot() this.getNoticeConfigAppBot()
this.attrList = attrList this.attrList = attrList
if (property.has_trigger) { if (property.has_trigger) {