From 976c616a72b7bce187d198fead5d0c0b7ecdd7c6 Mon Sep 17 00:00:00 2001 From: mmagi Date: Wed, 7 Jun 2023 22:29:25 +0800 Subject: [PATCH 1/2] fix: robot not selectable when add new testsuite --- src/components/TestSuiteUpdate.vue | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/components/TestSuiteUpdate.vue b/src/components/TestSuiteUpdate.vue index b0ff741c..47823c32 100644 --- a/src/components/TestSuiteUpdate.vue +++ b/src/components/TestSuiteUpdate.vue @@ -72,6 +72,7 @@ const testSuite = ref({ projectId: route.params.projectId, devices: [], testCases: [], + alertRobotIds: null, }); const deviceData = ref([]); const deviceDataBack = ref([]); @@ -139,7 +140,6 @@ const removeFromPublic = (e) => { const getSource = () => { getDevice(); getTestCaseList(); - getAlertRobots(); }; const emit = defineEmits(['flush']); const summit = () => { @@ -186,6 +186,7 @@ onMounted(() => { if (props.suiteId !== 0) { getSuiteInfo(props.suiteId); } + getAlertRobots(); }); From 1f92306d5f2322171e3f4b7e98d4386b0a37cb77 Mon Sep 17 00:00:00 2001 From: mmagi Date: Wed, 7 Jun 2023 22:29:25 +0800 Subject: [PATCH 2/2] fix: agent editor missing original robot selection --- src/views/Devices.vue | 27 +++++++++++++++------------ 1 file changed, 15 insertions(+), 12 deletions(-) diff --git a/src/views/Devices.vue b/src/views/Devices.vue index fd0e0578..85aa3719 100644 --- a/src/views/Devices.vue +++ b/src/views/Devices.vue @@ -140,13 +140,13 @@ const openHub = () => { }; watch(dialogAgent, (newValue, oldValue) => { if (!newValue) { - agent.value = { - id: 0, - name: '', - highTemp: 45, - highTempTime: 15, - robotSecret: '', - robotToken: '', + agent.value = { + id: 0, + name: '', + highTemp: 45, + highTempTime: 15, + robotSecret: '', + robotToken: '', robotType: 1, }; } @@ -1012,12 +1012,15 @@ onUnmounted(() => { min - {{ $t('agent.ui.defaultAlertRobotIds') }} -