修改分析方法
This commit is contained in:
@@ -141,27 +141,27 @@
|
|||||||
<dependency>
|
<dependency>
|
||||||
<groupId>com.yomahub</groupId>
|
<groupId>com.yomahub</groupId>
|
||||||
<artifactId>liteflow-spring-boot-starter</artifactId>
|
<artifactId>liteflow-spring-boot-starter</artifactId>
|
||||||
<version>2.15.0</version>
|
<version>2.15.1</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>com.yomahub</groupId>
|
<groupId>com.yomahub</groupId>
|
||||||
<artifactId>liteflow-script-javax-pro</artifactId>
|
<artifactId>liteflow-script-javax-pro</artifactId>
|
||||||
<version>2.15.0</version>
|
<version>2.15.1</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>com.yomahub</groupId>
|
<groupId>com.yomahub</groupId>
|
||||||
<artifactId>liteflow-script-groovy</artifactId>
|
<artifactId>liteflow-script-groovy</artifactId>
|
||||||
<version>2.15.0</version>
|
<version>2.15.1</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>com.yomahub</groupId>
|
<groupId>com.yomahub</groupId>
|
||||||
<artifactId>liteflow-script-qlexpress</artifactId>
|
<artifactId>liteflow-script-qlexpress</artifactId>
|
||||||
<version>2.15.0</version>
|
<version>2.15.1</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>com.yomahub</groupId>
|
<groupId>com.yomahub</groupId>
|
||||||
<artifactId>liteflow-script-graaljs</artifactId>
|
<artifactId>liteflow-script-graaljs</artifactId>
|
||||||
<version>2.15.0</version>
|
<version>2.15.1</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
|
||||||
<!-- pdfbox -->
|
<!-- pdfbox -->
|
||||||
|
|||||||
@@ -48,7 +48,7 @@ public class SampleEntrustController {
|
|||||||
if (response.isSuccess()) {
|
if (response.isSuccess()) {
|
||||||
return success(response.getContextBean(SampleEntrustContext.class));
|
return success(response.getContextBean(SampleEntrustContext.class));
|
||||||
} else {
|
} else {
|
||||||
return error(500, response.getMessage());
|
return error(1_032_100_000, response.getMessage());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -66,7 +66,7 @@ public class SampleEntrustController {
|
|||||||
if (response.isSuccess()) {
|
if (response.isSuccess()) {
|
||||||
return success(response.getContextBean(SampleEntrustContext.class));
|
return success(response.getContextBean(SampleEntrustContext.class));
|
||||||
} else {
|
} else {
|
||||||
return error(500, response.getMessage());
|
return error(1_032_100_000, response.getMessage());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -165,7 +165,7 @@ public class SampleFlowController {
|
|||||||
if (response.isSuccess()) {
|
if (response.isSuccess()) {
|
||||||
return success(response.getContextBean(SampleFlowContext.class));
|
return success(response.getContextBean(SampleFlowContext.class));
|
||||||
} else {
|
} else {
|
||||||
return error(500, response.getMessage());
|
return error(1_032_100_000, response.getMessage());
|
||||||
}
|
}
|
||||||
//return success(FlowBus.getNodeMap());
|
//return success(FlowBus.getNodeMap());
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -13,6 +13,7 @@ import java.util.List;
|
|||||||
|
|
||||||
import com.zt.plat.framework.common.pojo.CommonResult;
|
import com.zt.plat.framework.common.pojo.CommonResult;
|
||||||
import com.zt.plat.framework.common.pojo.vo.BatchDeleteReqVO;
|
import com.zt.plat.framework.common.pojo.vo.BatchDeleteReqVO;
|
||||||
|
import com.zt.plat.module.qms.business.bus.controller.vo.*;
|
||||||
import com.zt.plat.module.qms.business.bus.liteflow.param.SampleTaskAssignManualParam;
|
import com.zt.plat.module.qms.business.bus.liteflow.param.SampleTaskAssignManualParam;
|
||||||
import com.zt.plat.module.qms.business.bus.liteflow.param.SampleTaskAssignMethodParam;
|
import com.zt.plat.module.qms.business.bus.liteflow.param.SampleTaskAssignMethodParam;
|
||||||
import com.zt.plat.module.qms.business.bus.liteflow.param.SampleTaskAssignSampleParam;
|
import com.zt.plat.module.qms.business.bus.liteflow.param.SampleTaskAssignSampleParam;
|
||||||
@@ -38,10 +39,21 @@ public class SampleTaskAssignController {
|
|||||||
return success(list);
|
return success(list);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@GetMapping("/getAssaySampleList")
|
||||||
|
public CommonResult<?> getAssaySampleList() {
|
||||||
|
List<UnAssignTaskedSubSampleRespVO> list = sampleTaskAssignService.getAssaySampleList();
|
||||||
|
return success(list);
|
||||||
|
}
|
||||||
|
|
||||||
|
@GetMapping("/getAssayMethodList")
|
||||||
|
public CommonResult<?> getAssayMethodList(Long businessSubSampleId, Long configAssayMethodId) {
|
||||||
|
List<Object> list = sampleTaskAssignService.getAssayMethodList(businessSubSampleId, configAssayMethodId);
|
||||||
|
return success(list);
|
||||||
|
}
|
||||||
|
|
||||||
@PostMapping("/changeMethod")
|
@PostMapping("/changeMethod")
|
||||||
public CommonResult<?> changeMethod() {
|
public CommonResult<?> changeMethod(@RequestBody ChangeAssayMethodReqVO req) {
|
||||||
|
sampleTaskAssignService.changeMethod(req);
|
||||||
|
|
||||||
return success("成功");
|
return success("成功");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,16 @@
|
|||||||
|
package com.zt.plat.module.qms.business.bus.controller.vo;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class ChangeAssayMethodReqVO {
|
||||||
|
|
||||||
|
private Long businessSubSampleId;
|
||||||
|
|
||||||
|
private Long configAssayMethodId;
|
||||||
|
|
||||||
|
private List<Long> changeConfigAssayMethodIdList;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,50 @@
|
|||||||
|
package com.zt.plat.module.qms.business.bus.controller.vo;
|
||||||
|
|
||||||
|
import java.io.Serializable;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class UnAssignTaskedSubSampleRespVO implements Serializable {
|
||||||
|
|
||||||
|
private static final long serialVersionUID = -6009144013166409560L;
|
||||||
|
|
||||||
|
@Schema(description = "联合id")
|
||||||
|
private String id;
|
||||||
|
|
||||||
|
@Schema(description = "分样子样ID")
|
||||||
|
private Long businessSubSampleId;
|
||||||
|
|
||||||
|
@Schema(description = "样品名称", example = "张三")
|
||||||
|
private String sampleName;
|
||||||
|
|
||||||
|
@Schema(description = "样品编号")
|
||||||
|
private String sampleCode;
|
||||||
|
|
||||||
|
@Schema(description = "分析编号")
|
||||||
|
private String sampleAssayCode;
|
||||||
|
|
||||||
|
@Schema(description = "归库编号")
|
||||||
|
private String sampleReturnCode;
|
||||||
|
|
||||||
|
@Schema(description = "样品流程节点时间", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
private LocalDateTime sampleFlowNodeTime;
|
||||||
|
|
||||||
|
@Schema(description = "检测方法配置ID", example = "9130")
|
||||||
|
private Long configAssayMethodId;
|
||||||
|
|
||||||
|
@Schema(description = "分析类型,【字典】【jy_sample_assay_type】单杯、双杯、平行...", example = "2")
|
||||||
|
private String assayType;
|
||||||
|
|
||||||
|
@Schema(description = "检测项目")
|
||||||
|
private String assayProject;
|
||||||
|
|
||||||
|
@Schema(description = "分析部门ID", example = "16988")
|
||||||
|
private Long assayDepartmentId;
|
||||||
|
|
||||||
|
@Schema(description = "分析部门名称", example = "芋艿")
|
||||||
|
private String assayDepartmentName;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -171,6 +171,40 @@ public interface BusinessAssayTaskDataMapper extends BaseMapperX<BusinessAssayTa
|
|||||||
.eq(BusinessAssayTaskDataDO::getBusinessAssayTaskId, businessAssayTaskId));
|
.eq(BusinessAssayTaskDataDO::getBusinessAssayTaskId, businessAssayTaskId));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 根据子样查询分析任务
|
||||||
|
* @param businessSubSampleId 子样id
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
default List<BusinessAssayTaskDataDO> selectByBusinessSubSampleId(Long businessSubSampleId) {
|
||||||
|
return selectList(new LambdaQueryWrapperX<BusinessAssayTaskDataDO>()
|
||||||
|
.eq(BusinessAssayTaskDataDO::getBusinessSubSampleId, businessSubSampleId));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 根据子样查询分析任务
|
||||||
|
* @param businessSubSampleId 子样id
|
||||||
|
* @param configAssayMethodId 分析方法
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
default List<BusinessAssayTaskDataDO> selectByBusinessSubSampleIdAndConfigAssayMethodId(Long businessSubSampleId, Long configAssayMethodId) {
|
||||||
|
return selectList(new LambdaQueryWrapperX<BusinessAssayTaskDataDO>()
|
||||||
|
.eq(BusinessAssayTaskDataDO::getBusinessSubSampleId, businessSubSampleId)
|
||||||
|
.eq(BusinessAssayTaskDataDO::getConfigAssayMethodId, configAssayMethodId));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 根据分样查询分析任务
|
||||||
|
* @param businessSubParentSampleId 分样样id
|
||||||
|
* @param configAssayMethodId 分析方法
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
default List<BusinessAssayTaskDataDO> selectByBusinessSubParentSampleIdAndConfigAssayMethodId(Long businessSubParentSampleId, Long configAssayMethodId) {
|
||||||
|
return selectList(new LambdaQueryWrapperX<BusinessAssayTaskDataDO>()
|
||||||
|
.eq(BusinessAssayTaskDataDO::getBusinessSubParentSampleId, businessSubParentSampleId)
|
||||||
|
.eq(BusinessAssayTaskDataDO::getConfigAssayMethodId, configAssayMethodId));
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 查询是否上报的分析任务
|
* 查询是否上报的分析任务
|
||||||
* @param excludeIds 排除的id列表
|
* @param excludeIds 排除的id列表
|
||||||
@@ -211,4 +245,9 @@ public interface BusinessAssayTaskDataMapper extends BaseMapperX<BusinessAssayTa
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询未指派的子样
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
List<UnAssignTaskedSubSampleRespVO> selectUnAssignTaskedSubSample();
|
||||||
}
|
}
|
||||||
@@ -24,11 +24,11 @@ public class SampleEntrustCheckCmp extends NodeComponent {
|
|||||||
|
|
||||||
|
|
||||||
if (sampleEntrustRegistration.getConfigEntrustSourceId() == null) {
|
if (sampleEntrustRegistration.getConfigEntrustSourceId() == null) {
|
||||||
throw new ServiceException(500, "委托来源id不允许为空");
|
throw new ServiceException(1_032_100_000, "委托来源id不允许为空");
|
||||||
}
|
}
|
||||||
ConfigEntrustSourceDO configEntrustSource = sampleEntrustContext.getConfigEntrustSourceById(sampleEntrustRegistration.getConfigEntrustSourceId());
|
ConfigEntrustSourceDO configEntrustSource = sampleEntrustContext.getConfigEntrustSourceById(sampleEntrustRegistration.getConfigEntrustSourceId());
|
||||||
if (configEntrustSource == null) {
|
if (configEntrustSource == null) {
|
||||||
throw new ServiceException(500, "委托来源id不正确");
|
throw new ServiceException(1_032_100_000, "委托来源id不正确");
|
||||||
}
|
}
|
||||||
|
|
||||||
sampleEntrustRegistration.setDataCheckStatus(QmsCommonConstant.SUCCESS);
|
sampleEntrustRegistration.setDataCheckStatus(QmsCommonConstant.SUCCESS);
|
||||||
|
|||||||
@@ -64,7 +64,7 @@ public class SampleEntrustContextInitCmp extends NodeComponent {
|
|||||||
SampleEntrustParam sampleEntrustParam = this.getRequestData();
|
SampleEntrustParam sampleEntrustParam = this.getRequestData();
|
||||||
|
|
||||||
if (sampleEntrustParam == null) {
|
if (sampleEntrustParam == null) {
|
||||||
throw new ServiceException(500, "样品委托参数不允许为空");
|
throw new ServiceException(1_032_100_000, "样品委托参数不允许为空");
|
||||||
}
|
}
|
||||||
|
|
||||||
//获取样品委托上下文
|
//获取样品委托上下文
|
||||||
@@ -99,14 +99,14 @@ public class SampleEntrustContextInitCmp extends NodeComponent {
|
|||||||
|
|
||||||
//委托来源id为空并且委托来源key也为空
|
//委托来源id为空并且委托来源key也为空
|
||||||
if (sampleEntrustParam.getConfigEntrustSourceId() == null && StringUtils.isBlank(sampleEntrustParam.getConfigEntrustSourceKey())) {
|
if (sampleEntrustParam.getConfigEntrustSourceId() == null && StringUtils.isBlank(sampleEntrustParam.getConfigEntrustSourceKey())) {
|
||||||
throw new ServiceException(500, "委托来源id或委托来源key为空");
|
throw new ServiceException(1_032_100_000, "委托来源id或委托来源key为空");
|
||||||
}
|
}
|
||||||
|
|
||||||
//委托来源的id为空
|
//委托来源的id为空
|
||||||
if (sampleEntrustParam.getConfigEntrustSourceId() == null && StringUtils.isNotBlank(sampleEntrustParam.getConfigEntrustSourceKey()) && StringUtils.isNotBlank(sampleEntrustParam.getEntrustType())) {
|
if (sampleEntrustParam.getConfigEntrustSourceId() == null && StringUtils.isNotBlank(sampleEntrustParam.getConfigEntrustSourceKey()) && StringUtils.isNotBlank(sampleEntrustParam.getEntrustType())) {
|
||||||
ConfigEntrustSourceDO configEntrustSourceDO = configEntrustSourceList.stream().filter(f -> f.getKey().equals(sampleEntrustParam.getConfigEntrustSourceKey()) && f.getEntrustType().equals(sampleEntrustParam.getEntrustType())).findFirst().orElse(null);
|
ConfigEntrustSourceDO configEntrustSourceDO = configEntrustSourceList.stream().filter(f -> f.getKey().equals(sampleEntrustParam.getConfigEntrustSourceKey()) && f.getEntrustType().equals(sampleEntrustParam.getEntrustType())).findFirst().orElse(null);
|
||||||
if (configEntrustSourceDO == null) {
|
if (configEntrustSourceDO == null) {
|
||||||
throw new ServiceException(500, "样品委托来源不正确");
|
throw new ServiceException(1_032_100_000, "样品委托来源不正确");
|
||||||
}
|
}
|
||||||
sampleEntrustRegistration.setConfigEntrustSourceId(configEntrustSourceDO.getId());
|
sampleEntrustRegistration.setConfigEntrustSourceId(configEntrustSourceDO.getId());
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -217,7 +217,7 @@ public class SampleEntrustGenSampleDataCmp extends NodeComponent {
|
|||||||
//查询当前委托样品对应的子样
|
//查询当前委托样品对应的子样
|
||||||
List<ConfigSubSampleDO> entrustConfigSubSampleList = configSubSampleList.stream().filter(f -> configSubSampleIdList.contains(f.getId()) && f.getBaseSampleId().equals(businessSampleEntrustDetailDO.getBaseSampleId())).distinct().collect(Collectors.toList());
|
List<ConfigSubSampleDO> entrustConfigSubSampleList = configSubSampleList.stream().filter(f -> configSubSampleIdList.contains(f.getId()) && f.getBaseSampleId().equals(businessSampleEntrustDetailDO.getBaseSampleId())).distinct().collect(Collectors.toList());
|
||||||
if (entrustConfigSubSampleList.size() != 1) {
|
if (entrustConfigSubSampleList.size() != 1) {
|
||||||
throw new ServiceException(500, "子样配置不正确");
|
throw new ServiceException(1_032_100_000, "子样配置不正确");
|
||||||
}
|
}
|
||||||
//获取到子样配置
|
//获取到子样配置
|
||||||
ConfigSubSampleDO configSubSample = entrustConfigSubSampleList.get(0);
|
ConfigSubSampleDO configSubSample = entrustConfigSubSampleList.get(0);
|
||||||
|
|||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user