From 4e72128bbd32d6f3fc07377f42e0a655f6a3c30e Mon Sep 17 00:00:00 2001 From: joylink_zhaoerwei Date: Thu, 24 Aug 2023 16:14:21 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E5=AD=97=E6=AE=B5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/AlertMock.ts | 12 ++++++++---- src/components/alarm/alarmInfoDialog.vue | 4 +++- src/stores/line-net-store.ts | 1 + 3 files changed, 12 insertions(+), 5 deletions(-) diff --git a/src/api/AlertMock.ts b/src/api/AlertMock.ts index d432378..cf3a0ca 100644 --- a/src/api/AlertMock.ts +++ b/src/api/AlertMock.ts @@ -38,14 +38,18 @@ export async function alarmInfoListQuery( /** * 确认报警处理 - * @param recordId 推送的警告信息的id - * * @param tipId 决策信息的id + * @param id 推送的警告信息的id + * @param tipType 故障类型 + * @param alertLocationId 故障范围对应的列表id */ export function recordConfirmAlarmInfoByTipType( id: number, - tipType: string + tipType: string, + alertLocationId?: number ): Promise> { - return api.get(`/api/alertRecord/confirm/${id}/${tipType}`); + return api.get(`/api/alertRecord/confirm/${id}/${tipType}`, { + params: alertLocationId, + }); } /** diff --git a/src/components/alarm/alarmInfoDialog.vue b/src/components/alarm/alarmInfoDialog.vue index a4c69d1..80f0c41 100644 --- a/src/components/alarm/alarmInfoDialog.vue +++ b/src/components/alarm/alarmInfoDialog.vue @@ -120,6 +120,7 @@ const alarmInfo = ref({ alertObject: '', alertType: '', locator_device_id: '', + alert_location_id: '', }); const drivingInfo = ref(''); const submissionInfo = ref(''); @@ -183,7 +184,8 @@ async function searchByTipType() { const type = (saveAlertTypeData as never)[faultType.value]; const response = await recordConfirmAlarmInfoByTipType( +messageUse.id, - type + type, + messageUse.alert_location_id ); drivingInfo.value = JSON.parse(response.data.drivingInfo); submissionInfo.value = JSON.parse(response.data.submissionInfo); diff --git a/src/stores/line-net-store.ts b/src/stores/line-net-store.ts index e6b98c6..136c08d 100644 --- a/src/stores/line-net-store.ts +++ b/src/stores/line-net-store.ts @@ -14,6 +14,7 @@ export interface AlarmInfo { alert_object: string; alert_type: number; locator_device_id: string; + alert_location_id: number; alarmStatus?: number; } export const useLineNetStore = defineStore('lineNet', {