试验管理
This commit is contained in:
parent
7630ed04c6
commit
9c33b375a6
|
|
@ -100,4 +100,12 @@ public class ExperimentalController {
|
||||||
public ServerResponse viewTestData(EncryptedReq<ParamsDto> data) {
|
public ServerResponse viewTestData(EncryptedReq<ParamsDto> data) {
|
||||||
return service.viewTestData(data.getData());
|
return service.viewTestData(data.getData());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@PostMapping(value = "commitCheckTestData")
|
||||||
|
@DecryptAndVerify(decryptedClass = ParamsDto.class)//加解密统一管理
|
||||||
|
@LogAnnotation(operModul = "试验管理", operation = "提交审查数据", operDesc = "系统级事件", operType = "提交审查")
|
||||||
|
// @PreAuthorize("@pms.hasPermission('sys:experimentalTest:commitCheck')")
|
||||||
|
public ServerResponse commitCheckTestData(EncryptedReq<ParamsDto> data) {
|
||||||
|
return service.commitCheckTestData(data.getData());
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -37,4 +37,9 @@ public class ParamsDto extends PageEntity {
|
||||||
*/
|
*/
|
||||||
private String keyWord;
|
private String keyWord;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 收样ID数组
|
||||||
|
*/
|
||||||
|
private Long[] ids;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -49,15 +49,9 @@ public class ExperimentalVo {
|
||||||
* 试验班组
|
* 试验班组
|
||||||
*/
|
*/
|
||||||
private String teamName;
|
private String teamName;
|
||||||
/**
|
|
||||||
* 审核状态 0 待审核 1审核通过 2审核不通过
|
|
||||||
*/
|
|
||||||
private String audtiStatus;
|
private String audtiStatus;
|
||||||
|
|
||||||
/**
|
|
||||||
* 流程状态 0.待试验 1.待审阅 2.待审核 3.待审批 4.试验结束 5.待重新审阅
|
|
||||||
*/
|
|
||||||
private String processStatus;
|
|
||||||
/**
|
/**
|
||||||
* 备注
|
* 备注
|
||||||
*/
|
*/
|
||||||
|
|
|
||||||
|
|
@ -78,10 +78,20 @@ public interface ExperimentalService {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 试验数据详情
|
* 试验数据详情
|
||||||
|
*
|
||||||
* @param data
|
* @param data
|
||||||
* @return ServerResponse
|
* @return ServerResponse
|
||||||
* @author cwchen
|
* @author cwchen
|
||||||
* @date 2024/7/21 20:06
|
* @date 2024/7/21 20:06
|
||||||
*/
|
*/
|
||||||
ServerResponse viewTestData(ParamsDto data);
|
ServerResponse viewTestData(ParamsDto data);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 试验管理-提交审查
|
||||||
|
* @param data
|
||||||
|
* @return ServerResponse
|
||||||
|
* @author cwchen
|
||||||
|
* @date 2024/7/22 14:25
|
||||||
|
*/
|
||||||
|
ServerResponse commitCheckTestData(ParamsDto data);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -303,6 +303,22 @@ public class ExperimentalServiceImpl implements ExperimentalService {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
@Transactional(rollbackFor = Exception.class)
|
||||||
|
public ServerResponse commitCheckTestData(ParamsDto dto) {
|
||||||
|
try {
|
||||||
|
if(dto.getIds() == null || dto.getIds().length == 0){
|
||||||
|
return ServerResponse.createByErrorMsg(HttpStatus.ERROR,"未提交审查数据");
|
||||||
|
}
|
||||||
|
|
||||||
|
} catch (Exception e) {
|
||||||
|
log.error(e.toString(), e);
|
||||||
|
TransactionAspectSupport.currentTransactionStatus().setRollbackOnly();
|
||||||
|
return ServerResponse.createByErrorMsg(HttpStatus.ERROR, "操作失败");
|
||||||
|
}
|
||||||
|
return ServerResponse.createBySuccessMsg("操作成功");
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 验证参数是否为空
|
* 验证参数是否为空
|
||||||
*
|
*
|
||||||
|
|
|
||||||
|
|
@ -234,8 +234,17 @@
|
||||||
su2.user_name AS dispatchUserName,
|
su2.user_name AS dispatchUserName,
|
||||||
DATE_FORMAT(ts.sample_date, '%Y-%m-%d') AS sampleDate,
|
DATE_FORMAT(ts.sample_date, '%Y-%m-%d') AS sampleDate,
|
||||||
tt.team_name AS teamName,
|
tt.team_name AS teamName,
|
||||||
ts.audti_status AS audtiStatus,
|
CASE WHEN process_status IS NULL THEN '待试验'
|
||||||
ts.process_status AS processStatus,
|
WHEN process_status = 0 AND audti_status = 0 THEN '待提交'
|
||||||
|
WHEN process_status = 1 AND audti_status = 0 THEN '待审阅'
|
||||||
|
WHEN process_status = 1 AND audti_status = 2 THEN '审阅不通过'
|
||||||
|
WHEN process_status = 2 AND audti_status = 0 THEN '待审核'
|
||||||
|
WHEN process_status = 2 AND audti_status = 2 THEN '审核不通过'
|
||||||
|
WHEN process_status = 3 AND audti_status = 0 THEN '待审批'
|
||||||
|
WHEN process_status = 3 AND audti_status = 2 THEN '审批不通过'
|
||||||
|
WHEN process_status = 4 AND audti_status = 1 THEN '试验结束'
|
||||||
|
ELSE '待试验'
|
||||||
|
END AS audtiStatus,
|
||||||
ts.remarks
|
ts.remarks
|
||||||
FROM tb_sample ts
|
FROM tb_sample ts
|
||||||
LEFT JOIN tb_custom tc ON ts.custom_id = tc.id
|
LEFT JOIN tb_custom tc ON ts.custom_id = tc.id
|
||||||
|
|
@ -248,7 +257,7 @@
|
||||||
WHERE del_falg = 0
|
WHERE del_falg = 0
|
||||||
GROUP BY sample_id
|
GROUP BY sample_id
|
||||||
) tsd ON tsd.sample_id = ts.id
|
) tsd ON tsd.sample_id = ts.id
|
||||||
WHERE ts.del_flag = 0 AND process_status IN (0,5)
|
WHERE ts.del_flag = 0
|
||||||
<if test="keyWord != null and keyWord!=''">
|
<if test="keyWord != null and keyWord!=''">
|
||||||
AND (
|
AND (
|
||||||
INSTR(tt.team_name,#{keyWord}) > 0 OR
|
INSTR(tt.team_name,#{keyWord}) > 0 OR
|
||||||
|
|
@ -264,7 +273,7 @@
|
||||||
<if test="devTypeCode != null and devTypeCode!=''">
|
<if test="devTypeCode != null and devTypeCode!=''">
|
||||||
AND INSTR(tsd.sampleDevCode,#{devTypeCode})
|
AND INSTR(tsd.sampleDevCode,#{devTypeCode})
|
||||||
</if>
|
</if>
|
||||||
ORDER BY dispatch_time ASC
|
ORDER BY FIELD(audtiStatus, '审阅不通过','审核不通过','审批不通过','待试验','待提交','待审阅','待审核','待审批','试验结束') ASC,dispatch_time ASC
|
||||||
</select>
|
</select>
|
||||||
<!--试验详情列表-->
|
<!--试验详情列表-->
|
||||||
<select id="getDetailList" resultType="com.bonus.aqgqj.basis.entity.vo.ExperimentalDetailVo">
|
<select id="getDetailList" resultType="com.bonus.aqgqj.basis.entity.vo.ExperimentalDetailVo">
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue