From 07eef7ad0e37afcd0725ca25f034bc1b48eb9d40 Mon Sep 17 00:00:00 2001 From: tianyongbao Date: Tue, 20 Jan 2026 18:21:28 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E6=89=AB=E6=8F=8F=E8=AE=BE=E5=A4=87?= =?UTF-8?q?=E4=BA=8C=E7=BB=B4=E7=A0=81=EF=BC=8Cbug=E4=BF=AE=E5=A4=8D?= =?UTF-8?q?=E3=80=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../intc/fishery/controller/DeviceController.java | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) diff --git a/intc-modules/intc-fishery/src/main/java/com/intc/fishery/controller/DeviceController.java b/intc-modules/intc-fishery/src/main/java/com/intc/fishery/controller/DeviceController.java index da5569e..93a01cd 100644 --- a/intc-modules/intc-fishery/src/main/java/com/intc/fishery/controller/DeviceController.java +++ b/intc-modules/intc-fishery/src/main/java/com/intc/fishery/controller/DeviceController.java @@ -824,19 +824,19 @@ public class DeviceController extends BaseController { .eq(LinkedCtrl::getDeviceId, device.getId()) .select(LinkedCtrl::getId) ); - + if (!linkedCtrls.isEmpty()) { List linkedCtrlIds = linkedCtrls.stream() .map(LinkedCtrl::getId) .collect(Collectors.toList()); - + // 2. 解除关联的开关绑定 deviceSwitchMapper.update(null, new LambdaUpdateWrapper() .set(DeviceSwitch::getLinkedCtrlId, null) .in(DeviceSwitch::getLinkedCtrlId, linkedCtrlIds) ); - + // 3. 删除联动控制记录 linkedCtrlMapper.delete( new LambdaQueryWrapper() @@ -985,19 +985,19 @@ public class DeviceController extends BaseController { .eq(LinkedCtrl::getDeviceId, request.getId()) .select(LinkedCtrl::getId) ); - + if (!linkedCtrls.isEmpty()) { List linkedCtrlIds = linkedCtrls.stream() .map(LinkedCtrl::getId) .collect(Collectors.toList()); - + // 2. 解除关联的开关绑定 deviceSwitchMapper.update(null, new LambdaUpdateWrapper() .set(DeviceSwitch::getLinkedCtrlId, null) .in(DeviceSwitch::getLinkedCtrlId, linkedCtrlIds) ); - + // 3. 删除联动控制记录 linkedCtrlMapper.delete( new LambdaQueryWrapper() @@ -1048,13 +1048,11 @@ public class DeviceController extends BaseController { * 检查设备二维码,解析设备类型和序列号 * 二维码格式:pk=xxxxx&dn=xxxxx * - * @param rootUserId 用户ID(预留参数) * @param qrCode 设备二维码内容 * @return 设备类型和序列号 */ @GetMapping("/check_device_qrcode") public R checkDeviceQrcode( - @RequestParam("rootUserId") Long rootUserId, @RequestParam("qrCode") String qrCode) { // 验证二维码不能为空