skyline 7 달 전
부모
커밋
ab4c0899de
1개의 변경된 파일1개의 추가작업 그리고 0개의 파일을 삭제
  1. 1 0
      car-wash-service/src/main/java/com/kym/service/impl/WashDeviceServiceImpl.java

+ 1 - 0
car-wash-service/src/main/java/com/kym/service/impl/WashDeviceServiceImpl.java

@@ -155,6 +155,7 @@ public class WashDeviceServiceImpl extends MyBaseServiceImpl<WashDeviceMapper, W
         CommUtil.assertsNonNulls(List.of(device.getDeviceName(), device.getStationId(), device.getProductKey()), "参数异常");
         Long count = lambdaQuery()
                 .eq(WashDevice::getStationId, device.getStationId())
+                .eq(WashDevice::getDeviceName, device.getDeviceName())
                 .eq(WashDevice::getProductKey, device.getProductKey()).count();
         CommUtil.asserts(count == 0, "设备已存在");
         save(device);