UPDATE: 新建计划可选择所有标准设备
This commit is contained in:
@@ -8,7 +8,6 @@ import cn.hutool.core.bean.BeanUtil;
|
|||||||
import cn.hutool.core.collection.CollectionUtil;
|
import cn.hutool.core.collection.CollectionUtil;
|
||||||
import cn.hutool.core.util.ObjectUtil;
|
import cn.hutool.core.util.ObjectUtil;
|
||||||
import cn.hutool.core.util.StrUtil;
|
import cn.hutool.core.util.StrUtil;
|
||||||
import cn.hutool.extra.spring.SpringUtil;
|
|
||||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||||
import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
|
import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
|
||||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||||
@@ -18,17 +17,12 @@ import com.njcn.common.pojo.exception.BusinessException;
|
|||||||
import com.njcn.common.pojo.poi.PullDown;
|
import com.njcn.common.pojo.poi.PullDown;
|
||||||
import com.njcn.common.utils.EncryptionUtil;
|
import com.njcn.common.utils.EncryptionUtil;
|
||||||
import com.njcn.gather.device.mapper.PqStandardDevMapper;
|
import com.njcn.gather.device.mapper.PqStandardDevMapper;
|
||||||
import com.njcn.gather.device.pojo.enums.CheckStateEnum;
|
|
||||||
import com.njcn.gather.device.pojo.enums.CommonEnum;
|
|
||||||
import com.njcn.gather.device.pojo.param.PqStandardDevParam;
|
import com.njcn.gather.device.pojo.param.PqStandardDevParam;
|
||||||
import com.njcn.gather.device.pojo.po.PqStandardDev;
|
import com.njcn.gather.device.pojo.po.PqStandardDev;
|
||||||
import com.njcn.gather.device.pojo.vo.PqStandardDevExcel;
|
import com.njcn.gather.device.pojo.vo.PqStandardDevExcel;
|
||||||
import com.njcn.gather.device.pojo.vo.PreDetection;
|
import com.njcn.gather.device.pojo.vo.PreDetection;
|
||||||
import com.njcn.gather.device.service.IPqStandardDevService;
|
import com.njcn.gather.device.service.IPqStandardDevService;
|
||||||
import com.njcn.gather.plan.mapper.AdPlanStandardDevMapper;
|
import com.njcn.gather.plan.mapper.AdPlanStandardDevMapper;
|
||||||
import com.njcn.gather.plan.pojo.po.AdPlan;
|
|
||||||
import com.njcn.gather.plan.pojo.po.AdPlanStandardDev;
|
|
||||||
import com.njcn.gather.plan.service.IAdPlanService;
|
|
||||||
import com.njcn.gather.plan.service.IAdPlanStandardDevService;
|
import com.njcn.gather.plan.service.IAdPlanStandardDevService;
|
||||||
import com.njcn.gather.pojo.enums.DetectionResponseEnum;
|
import com.njcn.gather.pojo.enums.DetectionResponseEnum;
|
||||||
import com.njcn.gather.system.dictionary.pojo.po.DictData;
|
import com.njcn.gather.system.dictionary.pojo.po.DictData;
|
||||||
@@ -311,7 +305,7 @@ public class PqStandardDevServiceImpl extends ServiceImpl<PqStandardDevMapper, P
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public List<PqStandardDev> canBindingList() {
|
public List<PqStandardDev> canBindingList() {
|
||||||
List<String> excludeStandardDevIds = new ArrayList<>();
|
/*List<String> excludeStandardDevIds = new ArrayList<>();
|
||||||
// 获取所有已绑定的标准设备
|
// 获取所有已绑定的标准设备
|
||||||
List<AdPlanStandardDev> boundList = adPlanStandardDevService.list();
|
List<AdPlanStandardDev> boundList = adPlanStandardDevService.list();
|
||||||
if (CollectionUtil.isNotEmpty(boundList)) {
|
if (CollectionUtil.isNotEmpty(boundList)) {
|
||||||
@@ -350,13 +344,13 @@ public class PqStandardDevServiceImpl extends ServiceImpl<PqStandardDevMapper, P
|
|||||||
.collect(Collectors.toList());
|
.collect(Collectors.toList());
|
||||||
excludeStandardDevIds = excludeBoundList.stream().map(AdPlanStandardDev::getStandardDevId).collect(Collectors.toList());
|
excludeStandardDevIds = excludeBoundList.stream().map(AdPlanStandardDev::getStandardDevId).collect(Collectors.toList());
|
||||||
}
|
}
|
||||||
}
|
}*/
|
||||||
List<PqStandardDev> list = this.lambdaQuery()
|
List<PqStandardDev> list = this.lambdaQuery()
|
||||||
.eq(PqStandardDev::getState, DataStateEnum.ENABLE.getCode())
|
.eq(PqStandardDev::getState, DataStateEnum.ENABLE.getCode())
|
||||||
.list();
|
.list();
|
||||||
for (PqStandardDev pqStandardDev : list) {
|
/*for (PqStandardDev pqStandardDev : list) {
|
||||||
pqStandardDev.setDisabled(excludeStandardDevIds.contains(pqStandardDev.getId()));
|
pqStandardDev.setDisabled(excludeStandardDevIds.contains(pqStandardDev.getId()));
|
||||||
}
|
}*/
|
||||||
return list;
|
return list;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user