From 54b77f284074a55c19e1a1e7e74971eee06a4796 Mon Sep 17 00:00:00 2001 From: yangjun <1173114630@qq.com> Date: Mon, 28 Jul 2025 11:26:04 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E6=91=84=E5=83=8F=E5=A4=B4?= =?UTF-8?q?=E5=90=8C=E6=AD=A5=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/iot/baseIot/CheckBaseIotList.vue | 8 ++++++- src/views/iot/baseIot/compoents/SxtForm.vue | 22 ++++++++++++++++++++ src/views/iot/baseIot/compoents/SxtModal.vue | 2 +- 3 files changed, 30 insertions(+), 2 deletions(-) diff --git a/src/views/iot/baseIot/CheckBaseIotList.vue b/src/views/iot/baseIot/CheckBaseIotList.vue index aec3a83..87e947d 100644 --- a/src/views/iot/baseIot/CheckBaseIotList.vue +++ b/src/views/iot/baseIot/CheckBaseIotList.vue @@ -68,7 +68,7 @@ - + @@ -126,6 +126,7 @@ function searchReset() { //选择摄像头 function handleSxt(item){ console.log("🚀 ~ handleSxt ~ item:", item) + item.orgInfo = orgInfo.value; sxtModal.value.init(item); } //选择电表 @@ -141,6 +142,11 @@ function searchReset() { console.log("🚀 ~ handleWsd ~ item:", item) } + //物联设备同步后刷新列表 + function handleWlsbSuccess(){ + getBaseList(orgInfo.value) + } + // 自动请求并暴露内部方法 onMounted(() => { activeKey.value = "1"; diff --git a/src/views/iot/baseIot/compoents/SxtForm.vue b/src/views/iot/baseIot/compoents/SxtForm.vue index 0098306..f7964f4 100644 --- a/src/views/iot/baseIot/compoents/SxtForm.vue +++ b/src/views/iot/baseIot/compoents/SxtForm.vue @@ -53,6 +53,7 @@ * 初始化 */ function init(record) { + console.log("🚀 ~ init ~ record:", record) baseIotInfo.value = record; queryParam.pageNo = 1; getDataList(); @@ -99,6 +100,27 @@ * 提交数据 */ function submitForm() { + const list = checkDataList.value.records; + console.log('---->',list) + console.log("🚀 ~ submitForm ~ baseIotInfo.value:", baseIotInfo.value) + const orgInfo = baseIotInfo.value.orgInfo; + console.log("🚀 ~ submitForm ~ orgInfo:", orgInfo) + // console.log("🚀 ~ submitForm ~ orgInfo:", orgInfo.value.departId) + console.log("🚀 ~ submitForm ~ orgInfo:", orgInfo.id) + console.log("🚀 ~ submitForm ~ orgInfo:", orgInfo.departName) + + const params = {nuId:baseIotInfo.value.nuId, + nuName:baseIotInfo.value.nuName, + dataSourceCode:baseIotInfo.value.sysOrgCode, + departId: orgInfo.id, + departName: orgInfo.departName, + list} + console.log("🚀 ~ submitForm ~ params:", params) + defHttp.post({url:"/iot/tplink/cameraInfo/syncCameraList",params}).then((res)=>{ + console.log("🚀 ~ submitForm ~ res:", res) + emit("ok") + }) + } diff --git a/src/views/iot/baseIot/compoents/SxtModal.vue b/src/views/iot/baseIot/compoents/SxtModal.vue index 1ab6ab1..2c2ec07 100644 --- a/src/views/iot/baseIot/compoents/SxtModal.vue +++ b/src/views/iot/baseIot/compoents/SxtModal.vue @@ -1,5 +1,5 @@