|
|
@@ -640,6 +640,7 @@ public class DeviceGatewayImpl implements DeviceGateway {
|
|
|
}
|
|
|
|
|
|
@Override
|
|
|
+ @Transactional
|
|
|
public Boolean devShare(ShareParam shareParam) {
|
|
|
|
|
|
//校验主绑人
|
|
|
@@ -660,7 +661,7 @@ public class DeviceGatewayImpl implements DeviceGateway {
|
|
|
queryWrapper.in(DevShare::getState, Arrays.asList(0, 1));
|
|
|
List<DevShare> list = devShareService.list(queryWrapper);
|
|
|
|
|
|
- if (list != null && list.size() > 1) {
|
|
|
+ if (CollectionUtils.isNotEmpty(list)) {
|
|
|
throw new BizException(ErrorEnum.SHARE_IS_NOT_REPEAT.getErrorCode(), ErrorEnum.SHARE_IS_NOT_REPEAT.getErrorMessage());
|
|
|
}
|
|
|
|