|
|
|
@ -10,6 +10,7 @@ import com.github.yulichang.wrapper.MPJLambdaWrapper;
|
|
|
|
|
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
|
|
|
|
|
import lombok.RequiredArgsConstructor;
|
|
|
|
|
import org.dromara.qms.domain.QcInspectionTemplate;
|
|
|
|
|
import org.dromara.qms.domain.QcInspectionType;
|
|
|
|
|
import org.springframework.stereotype.Service;
|
|
|
|
|
import org.dromara.qms.domain.bo.QcInspectionMainBo;
|
|
|
|
|
import org.dromara.qms.domain.vo.QcInspectionMainVo;
|
|
|
|
@ -74,11 +75,11 @@ public class QcInspectionMainServiceImpl implements IQcInspectionMainService {
|
|
|
|
|
Map<String, Object> params = bo.getParams();
|
|
|
|
|
MPJLambdaWrapper<QcInspectionMain> lqw = JoinWrappers.lambda(QcInspectionMain.class)
|
|
|
|
|
.selectAll(QcInspectionMain.class)
|
|
|
|
|
|
|
|
|
|
//关联模板主表
|
|
|
|
|
.select(QcInspectionTemplate::getTemplateName)
|
|
|
|
|
.select(QcInspectionType::getTypeName)
|
|
|
|
|
.leftJoin(QcInspectionTemplate.class, QcInspectionTemplate::getTemplateId, QcInspectionMain::getTemplateId)
|
|
|
|
|
|
|
|
|
|
.leftJoin(QcInspectionType.class, QcInspectionType::getTypeId, QcInspectionMain::getInspectionType)
|
|
|
|
|
.eq(bo.getInspectionId() != null, QcInspectionMain::getInspectionId, bo.getInspectionId())
|
|
|
|
|
.eq(bo.getPlanDetailId() != null, QcInspectionMain::getPlanDetailId, bo.getPlanDetailId())//后续添加
|
|
|
|
|
.eq(StringUtils.isNotBlank(bo.getInspectionNo()), QcInspectionMain::getInspectionNo, bo.getInspectionNo())
|
|
|
|
@ -96,7 +97,7 @@ public class QcInspectionMainServiceImpl implements IQcInspectionMainService {
|
|
|
|
|
.eq(StringUtils.isNotBlank(bo.getWorkshop()), QcInspectionMain::getWorkshop, bo.getWorkshop())
|
|
|
|
|
// .eq(bo.getInspectionType() != null, QcInspectionMain::getInspectionType, bo.getInspectionType())
|
|
|
|
|
// .eq(bo.getStatus() != null, QcInspectionMain::getStatus, bo.getStatus())
|
|
|
|
|
.eq(StringUtils.isNotBlank(bo.getInspectionType()), QcInspectionMain::getInspectionType, bo.getInspectionType())
|
|
|
|
|
.eq(StringUtils.isNotBlank(bo.getQcInspectionType()), QcInspectionType::getQcInspectionType, bo.getQcInspectionType())
|
|
|
|
|
.eq(StringUtils.isNotBlank(bo.getStatus()), QcInspectionMain::getStatus, bo.getStatus())
|
|
|
|
|
.eq(StringUtils.isNotBlank(bo.getInspector()), QcInspectionMain::getInspector, bo.getInspector())
|
|
|
|
|
.eq(StringUtils.isNotBlank(bo.getShift()), QcInspectionMain::getShift, bo.getShift())
|
|
|
|
@ -172,4 +173,18 @@ public class QcInspectionMainServiceImpl implements IQcInspectionMainService {
|
|
|
|
|
}
|
|
|
|
|
return baseMapper.deleteByIds(ids) > 0;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* PDA分页查询质检任务
|
|
|
|
|
*
|
|
|
|
|
* @param bo
|
|
|
|
|
* @param pageQuery
|
|
|
|
|
* @return
|
|
|
|
|
*/
|
|
|
|
|
@Override
|
|
|
|
|
public TableDataInfo<QcInspectionMainVo> getMainList(QcInspectionMainBo bo, PageQuery pageQuery) {
|
|
|
|
|
MPJLambdaWrapper<QcInspectionMain> lqw = buildQueryWrapper(bo);
|
|
|
|
|
Page<QcInspectionMainVo> result = baseMapper.selectVoPage(pageQuery.build(), lqw);
|
|
|
|
|
return TableDataInfo.build(result);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|