任务分配修改

This commit is contained in:
2025-11-06 15:16:26 +08:00
parent 9eb42b930f
commit a3cd8a0a55
24 changed files with 528 additions and 198 deletions

View File

@@ -47,9 +47,9 @@ public class BusinessQCCoefficientDataController implements BusinessControllerMa
return success(businessQCCoefficientDataService.createBusinessQCCoefficientData(createReqVO));
}
@PutMapping("/update")
@PostMapping("/update")
@Operation(summary = "更新质控样检测系数任务数据,空白样、标样")
@PreAuthorize("@ss.hasPermission('qms:business-QC-coefficient-data:update')")
// @PreAuthorize("@ss.hasPermission('qms:business-QC-coefficient-data:update')")
public CommonResult<Boolean> updateBusinessQCCoefficientData(@Valid @RequestBody BusinessQCCoefficientDataSaveReqVO updateReqVO) {
businessQCCoefficientDataService.updateBusinessQCCoefficientData(updateReqVO);
return success(true);
@@ -90,6 +90,14 @@ public class BusinessQCCoefficientDataController implements BusinessControllerMa
return success(BeanUtils.toBean(pageResult, BusinessQCCoefficientDataRespVO.class));
}
@GetMapping("/list")
@Operation(summary = "获得质控样检测系数任务数据,空白样、标样分页")
// @PreAuthorize("@ss.hasPermission('qms:business-QC-coefficient-data:query')")
public CommonResult<List<BusinessQCCoefficientDataRespVO>> getBusinessQCCoefficientDataPage(@Valid BusinessQCCoefficientDataReqVO reqVO) {
List<BusinessQCCoefficientDataDO> pageResult = businessQCCoefficientDataService.getBusinessQCCoefficientDataList(reqVO);
return success(BeanUtils.toBean(pageResult, BusinessQCCoefficientDataRespVO.class));
}
@GetMapping("/export-excel")
@Operation(summary = "导出质控样检测系数任务数据,空白样、标样 Excel")
@PreAuthorize("@ss.hasPermission('qms:business-QC-coefficient-data:export')")

View File

@@ -47,9 +47,9 @@ public class BusinessQCManagementDataController implements BusinessControllerMar
return success(businessQCManagementDataService.createBusinessQCManagementData(createReqVO));
}
@PutMapping("/update")
@PostMapping("/update")
@Operation(summary = "更新质控管理样检测任务数据,管理样、标准样")
@PreAuthorize("@ss.hasPermission('qms:business-QC-management-data:update')")
// @PreAuthorize("@ss.hasPermission('qms:business-QC-management-data:update')")
public CommonResult<Boolean> updateBusinessQCManagementData(@Valid @RequestBody BusinessQCManagementDataSaveReqVO updateReqVO) {
businessQCManagementDataService.updateBusinessQCManagementData(updateReqVO);
return success(true);
@@ -90,6 +90,14 @@ public class BusinessQCManagementDataController implements BusinessControllerMar
return success(BeanUtils.toBean(pageResult, BusinessQCManagementDataRespVO.class));
}
@GetMapping("/list")
@Operation(summary = "获得质控管理样检测任务数据,管理样、标准样列表")
// @PreAuthorize("@ss.hasPermission('qms:business-QC-management-data:query')")
public CommonResult<List<BusinessQCManagementDataRespVO>> getBusinessQCManagementDataList(@Valid BusinessQCManagementDataReqVO reqVO) {
List<BusinessQCManagementDataDO> pageResult = businessQCManagementDataService.getBusinessQCManagementDataList(reqVO);
return success(BeanUtils.toBean(pageResult, BusinessQCManagementDataRespVO.class));
}
@GetMapping("/export-excel")
@Operation(summary = "导出质控管理样检测任务数据,管理样、标准样 Excel")
@PreAuthorize("@ss.hasPermission('qms:business-QC-management-data:export')")

View File

@@ -0,0 +1,79 @@
package com.zt.plat.module.qms.business.bus.controller.vo;
import lombok.*;
import java.util.*;
import io.swagger.v3.oas.annotations.media.Schema;
import com.zt.plat.framework.common.pojo.PageParam;
import org.springframework.format.annotation.DateTimeFormat;
import java.time.LocalDateTime;
import static com.zt.plat.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND;
@Schema(description = "管理后台 - 质控样检测系数任务数据,空白样、标样分页 Request VO")
@Data
public class BusinessQCCoefficientDataReqVO {
@Schema(description = "样品编号")
private String sampleCode;
@Schema(description = "样品名称", example = "赵六")
private String sampleName;
@Schema(description = "检测方法配置ID", example = "31198")
private Long configAssayMethodId;
@Schema(description = "指派单ID", example = "28147")
private Long businessAssayTaskId;
@Schema(description = "定值样业务ID", example = "5300")
private Long businessStandardSampleId;
@Schema(description = "质控类型_ID,字典表【T_DIC_BSN】质控类型空白样、管理样、标准样、标样", example = "21660")
private Long dictionaryBusinessId;
@Schema(description = "质控类型_Key,字典表【T_DIC_BSN】质控类型空白样、管理样、标准样、标样")
private String dictionaryBusinessKey;
@Schema(description = "检测项目")
private String assayProject;
@Schema(description = "分析部门ID", example = "12186")
private Long assayDepartmentId;
@Schema(description = "分析部门名称", example = "芋艿")
private String assayDepartmentName;
@Schema(description = "分析人")
private String assayOperator;
@Schema(description = "分配任务时间")
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
private LocalDateTime[] assignTaskTime;
@Schema(description = "是否已分配任务")
private Integer isAssignTasked;
@Schema(description = "是否已上报")
private Integer isReported;
@Schema(description = "上报人")
private String reporter;
@Schema(description = "上报时间")
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
private LocalDateTime[] reportTime;
@Schema(description = "乐观锁", example = "6160")
private Integer updateCount;
@Schema(description = "所属部门")
private String systemDepartmentCode;
@Schema(description = "创建时间")
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
private LocalDateTime[] createTime;
@Schema(description = "备注")
private String remark;
}

View File

@@ -37,8 +37,7 @@ public class BusinessQCCoefficientDataSaveReqVO {
@Schema(description = "质控类型_Key,字典表【T_DIC_BSN】质控类型空白样、管理样、标准样、标样")
private String dictionaryBusinessKey;
@Schema(description = "检测项目", requiredMode = Schema.RequiredMode.REQUIRED)
@NotEmpty(message = "检测项目不能为空")
@Schema(description = "检测项目")
private String assayProject;
@Schema(description = "分析部门ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "12186")

View File

@@ -0,0 +1,79 @@
package com.zt.plat.module.qms.business.bus.controller.vo;
import lombok.*;
import java.util.*;
import io.swagger.v3.oas.annotations.media.Schema;
import com.zt.plat.framework.common.pojo.PageParam;
import org.springframework.format.annotation.DateTimeFormat;
import java.time.LocalDateTime;
import static com.zt.plat.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND;
@Schema(description = "管理后台 - 质控管理样检测任务数据,管理样、标准样分页 Request VO")
@Data
public class BusinessQCManagementDataReqVO {
@Schema(description = "样品编号")
private String sampleCode;
@Schema(description = "样品名称", example = "李四")
private String sampleName;
@Schema(description = "检测方法配置ID", example = "22240")
private Long configAssayMethodId;
@Schema(description = "指派单ID", example = "12452")
private Long businessAssayTaskId;
@Schema(description = "定值样业务ID", example = "29446")
private Long businessStandardSampleId;
@Schema(description = "质控类型_ID,字典表【T_DIC_BSN】质控类型空白样、管理样、标准样、标样", example = "512")
private Long dictionaryBusinessId;
@Schema(description = "质控类型_Key,字典表【T_DIC_BSN】质控类型空白样、管理样、标准样、标样")
private String dictionaryBusinessKey;
@Schema(description = "检测项目")
private String assayProject;
@Schema(description = "分析部门ID", example = "21281")
private Long assayDepartmentId;
@Schema(description = "分析部门名称", example = "赵六")
private String assayDepartmentName;
@Schema(description = "分析人")
private String assayOperator;
@Schema(description = "分配任务时间")
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
private LocalDateTime[] assignTaskTime;
@Schema(description = "是否已分配任务")
private Integer isAssignTasked;
@Schema(description = "是否已上报")
private Integer isReported;
@Schema(description = "上报人")
private String reporter;
@Schema(description = "上报时间")
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
private LocalDateTime[] reportTime;
@Schema(description = "乐观锁", example = "16695")
private Integer updateCount;
@Schema(description = "所属部门")
private String systemDepartmentCode;
@Schema(description = "创建时间")
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
private LocalDateTime[] createTime;
@Schema(description = "备注")
private String remark;
}

View File

@@ -18,8 +18,8 @@ public class CreateQcSampleReqVO {
@Schema(description = "定值样业务ID", example = "24895")
private Long businessStandardSampleId;
@Schema(description = "质控样分析方法id")
private Long configQCAssayMethodId;
@Schema(description = "质控样配置方法id")
private Long configQCSampleMethodId;
@Schema(description = "质控类型_ID,字典表【T_DIC_BSN】质控类型空白样、管理样、标准样、标样", example = "9549")
private Long dictionaryBusinessId;

View File

@@ -42,4 +42,34 @@ public interface BusinessQCCoefficientDataMapper extends BaseMapperX<BusinessQCC
.orderByDesc(BusinessQCCoefficientDataDO::getId));
}
default List<BusinessQCCoefficientDataDO> selectList(BusinessQCCoefficientDataReqVO reqVO) {
return selectList(new LambdaQueryWrapperX<BusinessQCCoefficientDataDO>()
.eqIfPresent(BusinessQCCoefficientDataDO::getSampleCode, reqVO.getSampleCode())
.likeIfPresent(BusinessQCCoefficientDataDO::getSampleName, reqVO.getSampleName())
.eqIfPresent(BusinessQCCoefficientDataDO::getConfigAssayMethodId, reqVO.getConfigAssayMethodId())
.eqIfPresent(BusinessQCCoefficientDataDO::getBusinessAssayTaskId, reqVO.getBusinessAssayTaskId())
.eqIfPresent(BusinessQCCoefficientDataDO::getBusinessStandardSampleId, reqVO.getBusinessStandardSampleId())
.eqIfPresent(BusinessQCCoefficientDataDO::getDictionaryBusinessId, reqVO.getDictionaryBusinessId())
.eqIfPresent(BusinessQCCoefficientDataDO::getDictionaryBusinessKey, reqVO.getDictionaryBusinessKey())
.eqIfPresent(BusinessQCCoefficientDataDO::getAssayProject, reqVO.getAssayProject())
.eqIfPresent(BusinessQCCoefficientDataDO::getAssayDepartmentId, reqVO.getAssayDepartmentId())
.likeIfPresent(BusinessQCCoefficientDataDO::getAssayDepartmentName, reqVO.getAssayDepartmentName())
.eqIfPresent(BusinessQCCoefficientDataDO::getAssayOperator, reqVO.getAssayOperator())
.betweenIfPresent(BusinessQCCoefficientDataDO::getAssignTaskTime, reqVO.getAssignTaskTime())
.eqIfPresent(BusinessQCCoefficientDataDO::getIsAssignTasked, reqVO.getIsAssignTasked())
.eqIfPresent(BusinessQCCoefficientDataDO::getIsReported, reqVO.getIsReported())
.eqIfPresent(BusinessQCCoefficientDataDO::getReporter, reqVO.getReporter())
.betweenIfPresent(BusinessQCCoefficientDataDO::getReportTime, reqVO.getReportTime())
.eqIfPresent(BusinessQCCoefficientDataDO::getUpdateCount, reqVO.getUpdateCount())
.eqIfPresent(BusinessQCCoefficientDataDO::getSystemDepartmentCode, reqVO.getSystemDepartmentCode())
.betweenIfPresent(BusinessQCCoefficientDataDO::getCreateTime, reqVO.getCreateTime())
.eqIfPresent(BusinessQCCoefficientDataDO::getRemark, reqVO.getRemark())
.orderByDesc(BusinessQCCoefficientDataDO::getId));
}
default List<BusinessQCCoefficientDataDO> selectByBusinessAssayTaskId(Long businessAssayTaskId) {
return selectList(new LambdaQueryWrapperX<BusinessQCCoefficientDataDO>()
.eq(BusinessQCCoefficientDataDO::getBusinessAssayTaskId, businessAssayTaskId));
}
}

View File

@@ -42,4 +42,29 @@ public interface BusinessQCManagementDataMapper extends BaseMapperX<BusinessQCMa
.orderByDesc(BusinessQCManagementDataDO::getId));
}
default List<BusinessQCManagementDataDO> selectList(BusinessQCManagementDataReqVO reqVO) {
return selectList(new LambdaQueryWrapperX<BusinessQCManagementDataDO>()
.eqIfPresent(BusinessQCManagementDataDO::getSampleCode, reqVO.getSampleCode())
.likeIfPresent(BusinessQCManagementDataDO::getSampleName, reqVO.getSampleName())
.eqIfPresent(BusinessQCManagementDataDO::getConfigAssayMethodId, reqVO.getConfigAssayMethodId())
.eqIfPresent(BusinessQCManagementDataDO::getBusinessAssayTaskId, reqVO.getBusinessAssayTaskId())
.eqIfPresent(BusinessQCManagementDataDO::getBusinessStandardSampleId, reqVO.getBusinessStandardSampleId())
.eqIfPresent(BusinessQCManagementDataDO::getDictionaryBusinessId, reqVO.getDictionaryBusinessId())
.eqIfPresent(BusinessQCManagementDataDO::getDictionaryBusinessKey, reqVO.getDictionaryBusinessKey())
.eqIfPresent(BusinessQCManagementDataDO::getAssayProject, reqVO.getAssayProject())
.eqIfPresent(BusinessQCManagementDataDO::getAssayDepartmentId, reqVO.getAssayDepartmentId())
.likeIfPresent(BusinessQCManagementDataDO::getAssayDepartmentName, reqVO.getAssayDepartmentName())
.eqIfPresent(BusinessQCManagementDataDO::getAssayOperator, reqVO.getAssayOperator())
.betweenIfPresent(BusinessQCManagementDataDO::getAssignTaskTime, reqVO.getAssignTaskTime())
.eqIfPresent(BusinessQCManagementDataDO::getIsAssignTasked, reqVO.getIsAssignTasked())
.eqIfPresent(BusinessQCManagementDataDO::getIsReported, reqVO.getIsReported())
.eqIfPresent(BusinessQCManagementDataDO::getReporter, reqVO.getReporter())
.betweenIfPresent(BusinessQCManagementDataDO::getReportTime, reqVO.getReportTime())
.eqIfPresent(BusinessQCManagementDataDO::getUpdateCount, reqVO.getUpdateCount())
.eqIfPresent(BusinessQCManagementDataDO::getSystemDepartmentCode, reqVO.getSystemDepartmentCode())
.betweenIfPresent(BusinessQCManagementDataDO::getCreateTime, reqVO.getCreateTime())
.eqIfPresent(BusinessQCManagementDataDO::getRemark, reqVO.getRemark())
.orderByDesc(BusinessQCManagementDataDO::getId));
}
}

View File

@@ -9,15 +9,13 @@ import cn.hutool.core.collection.CollUtil;
import com.zt.plat.module.qms.business.bus.dal.dataobject.BusinessAssayTaskDO;
import com.zt.plat.module.qms.business.bus.dal.dataobject.BusinessAssayTaskDataDO;
import com.zt.plat.module.qms.business.bus.dal.dataobject.BusinessAssayTaskDetailDO;
import com.zt.plat.module.qms.business.bus.dal.dataobject.BusinessQCDataDO;
import com.zt.plat.module.qms.business.bus.dal.dataobject.BusinessQCParameterDataDO;
import com.zt.plat.module.qms.business.bus.dal.dataobject.BusinessQCProjectDataDO;
import com.zt.plat.module.qms.business.bus.dal.dataobject.BusinessQCCoefficientDataDO;
import com.zt.plat.module.qms.business.bus.dal.dataobject.BusinessQCCoefficientParameterDataDO;
import com.zt.plat.module.qms.business.bus.dal.mapper.BusinessAssayTaskDataMapper;
import com.zt.plat.module.qms.business.bus.dal.mapper.BusinessAssayTaskDetailMapper;
import com.zt.plat.module.qms.business.bus.dal.mapper.BusinessAssayTaskMapper;
import com.zt.plat.module.qms.business.bus.dal.mapper.BusinessQCDataMapper;
import com.zt.plat.module.qms.business.bus.dal.mapper.BusinessQCParameterDataMapper;
import com.zt.plat.module.qms.business.bus.dal.mapper.BusinessQCProjectDataMapper;
import com.zt.plat.module.qms.business.bus.dal.mapper.BusinessQCCoefficientDataMapper;
import com.zt.plat.module.qms.business.bus.dal.mapper.BusinessQCCoefficientParameterDataMapper;
import com.zt.plat.module.qms.business.bus.liteflow.slot.SampleTaskAssignContext;
import jakarta.annotation.Resource;
@@ -34,13 +32,10 @@ public class SampleTaskAssignDataSaveOrUpdateCmp extends NodeComponent {
private BusinessAssayTaskDataMapper businessAssayTaskDataMapper;
@Resource
private BusinessQCDataMapper businessQCDataMapper;
private BusinessQCCoefficientDataMapper businessQCCoefficientDataMapper;
@Resource
private BusinessQCProjectDataMapper businessQCProjectDataMapper;
@Resource
private BusinessQCParameterDataMapper businessQCParameterDataMapper;
private BusinessQCCoefficientParameterDataMapper businessQCCoefficientParameterDataMapper;
@Override
public void process() throws Exception {
@@ -54,11 +49,9 @@ public class SampleTaskAssignDataSaveOrUpdateCmp extends NodeComponent {
List<BusinessAssayTaskDataDO> businessAssayTaskDataList = sampleTaskAssignContext.getBusinessAssayTaskDataList();
List<BusinessQCDataDO> businessQCDataList = sampleTaskAssignContext.getBusinessQCDataList();
List<BusinessQCCoefficientDataDO> businessQCCoefficientDataList = sampleTaskAssignContext.getBusinessQCCoefficientDataList();
List<BusinessQCProjectDataDO> businessQCProjectDataList = sampleTaskAssignContext.getBusinessQCProjectDataList();
List<BusinessQCParameterDataDO> businessQCParameterDataList = sampleTaskAssignContext.getBusinessQCParameterDataList();
List<BusinessQCCoefficientParameterDataDO> businessQCCoefficientParameterDataList = sampleTaskAssignContext.getBusinessQCCoefficientParameterDataList();
if (CollUtil.isNotEmpty(savebusinessAssayTaskList)) {
this.businessAssayTaskMapper.insertBatch(savebusinessAssayTaskList);
@@ -76,16 +69,12 @@ public class SampleTaskAssignDataSaveOrUpdateCmp extends NodeComponent {
this.businessAssayTaskDataMapper.updateBatch(businessAssayTaskDataList);
}
if (CollUtil.isNotEmpty(businessQCDataList)) {
this.businessQCDataMapper.insertBatch(businessQCDataList);
if (CollUtil.isNotEmpty(businessQCCoefficientDataList)) {
this.businessQCCoefficientDataMapper.insertBatch(businessQCCoefficientDataList);
}
if (CollUtil.isNotEmpty(businessQCProjectDataList)) {
this.businessQCProjectDataMapper.insertBatch(businessQCProjectDataList);
}
if (CollUtil.isNotEmpty(businessQCParameterDataList)) {
this.businessQCParameterDataMapper.insertBatch(businessQCParameterDataList);
if (CollUtil.isNotEmpty(businessQCCoefficientParameterDataList)) {
this.businessQCCoefficientParameterDataMapper.insertBatch(businessQCCoefficientParameterDataList);
}
}

Some files were not shown because too many files have changed in this diff Show More