Commit c9c89d36 authored by 竹天卫's avatar 竹天卫

校核计算优化

parent 477f2972
......@@ -183,6 +183,7 @@ public class ReportController {
one.setEnclosureUrl(query.getEnclosureUrl());
one.setExtName(query.getExtName());
one.setUpdateTime(LocalDateTime.now());
one.setPdfUrl(query.getPdfUrl());
iEntityEnclosureService.updateById(one);
return BaseResponse.okData(true);
}
......
......@@ -14,6 +14,9 @@
<if test="params.status != null">
and e.status = #{params.status}
</if>
<if test="params.reportStatus != null">
and e.status <![CDATA[>=]]> #{params.reportStatus}
</if>
<if test="params.clientName != null and params.clientName != ''">
and c.name like concat('%', #{params.clientName}, '%')
</if>
......
......@@ -93,6 +93,7 @@
SELECT t.name
FROM team t
WHERE t.group_id = #{groupId} and t.status = 1
and t.remark != 'no_check'
</select>
<!--根据检测组id 获取所有检测项信息-->
......
......@@ -30,6 +30,9 @@ public class SampleHandleVo {
@ApiModelProperty("项目编号")
private String projectCode;
@ApiModelProperty("样品处理项id")
private Integer handleId;
@ApiModelProperty("样品数量")
private Integer sampleNum;
......
......@@ -196,7 +196,7 @@ public class CommonServiceImpl {
countMap.put(name,CheckCountUtil.checkCount(name,resultMap));
}else if(name.equals("TiO<sub>2</sub>")){
countMap.put(name,CheckCountUtil.checkCount(name,resultMap));
}else if(name.equals("重量法_SO<sub>3</sub>")){
}else if(name.equals("重量法SO<sub>3</sub>")){
countMap.put(name,CheckCountUtil.checkCount(name,resultMap));
}else if(name.equals("K<sub>2</sub>O")){
countMap.put(name,CheckCountUtil.checkCount(name,resultMap));
......@@ -204,7 +204,7 @@ public class CommonServiceImpl {
countMap.put(name,CheckCountUtil.checkCount(name,resultMap));
}else if(name.equals("MnO")){
countMap.put(name,CheckCountUtil.checkCount(name,resultMap));
}else if(name.equals("Cl")){
}else if(name.equals("Cl<sup>-</sup>")){
countMap.put(name,CheckCountUtil.checkCount(name,resultMap));
}else if(name.equals("Mad1")){
countMap.put(name,CheckCountUtil.checkCount(name,resultMap));
......@@ -218,7 +218,7 @@ public class CommonServiceImpl {
countMap.put(name, CheckCountUtil.checkCount(name, resultMap));
}else if(name.equals("St,ad")){
countMap.put(name, CheckCountUtil.checkCount(name, resultMap));
}else if(name.equals("易磨性等级")){
}else if(name.equals("易磨性")){
countMap.put(name, CheckCountUtil.countYMXGrade(resultMap));
}else if(name.equals("易磨性校验码")){
countMap.put(name, CheckCountUtil.countYMXCode(resultMap));
......@@ -241,9 +241,6 @@ public class CommonServiceImpl {
}else if(name.equals("AM")){
String countAM = CheckCountUtil.countAM(countMap);
countMap.put(name, countAM);
}else if(name.equals("易烧性等级")){
String burnupLevel = CheckCountUtil.countBurnupLevel(resultMap,countMap);
countMap.put(name, burnupLevel);
}else if(name.equals("报出_Mad")){
String countBCMad = CheckCountUtil.countBCMad(countMap);
countMap.put(name, countBCMad);
......@@ -277,6 +274,9 @@ public class CommonServiceImpl {
}else if(name.equals("Ad")) {
String countAd = CheckCountUtil.countAd(countMap);
countMap.put(name, countAd);
}else if(name.equals("易烧性")){
String burnupLevel = CheckCountUtil.countBurnupLevel(resultMap,countMap);
countMap.put(name, burnupLevel);
}
}
......
......@@ -427,18 +427,6 @@ public class EntrustServiceImpl extends ServiceImpl<EntrustMapper, Entrust> impl
List<EntrustApproval> approvalList = approvalMapper.selectList(approvalWrapper);
EntrustApproval approval = approvalList.get(0);
entrustVo.setOpinion(approval.getOpinion());
//查询报告,如果有上传的委托报告,用户可已进行下载
QueryWrapper<EntityEnclosure> wrapper = new QueryWrapper<>();
wrapper.eq("entity_type", EntityEnclosure.EntityType.ENTRUST_REPORT);
wrapper.eq("entity_id", entrustVo.getId());
wrapper.eq("is_deleted", 1);
List<EntityEnclosure> entityEnclosureList = entityEnclosureMapper.selectList(wrapper);
if(entityEnclosureList != null && entityEnclosureList.size()>0 ){
EntityEnclosure entityEnclosure = entityEnclosureList.get(0);
entrustVo.setAlias(entityEnclosure.getAlias());
entrustVo.setEnclosureUrl(entityEnclosure.getPdfUrl());
entrustVo.setExtName(entityEnclosure.getExtName());
}
} else {
QueryWrapper<SampleTmp> queryWrapper = new QueryWrapper<>();
queryWrapper.eq("entrust_id", entrustVo.getId());
......@@ -623,6 +611,19 @@ public class EntrustServiceImpl extends ServiceImpl<EntrustMapper, Entrust> impl
}
}
entrustVo.setSampleList(sampleVoList);//样品列表(展示平行样样品)
//查询报告,如果有上传的委托报告,用户可已进行下载
QueryWrapper<EntityEnclosure> wrapper = new QueryWrapper<>();
wrapper.eq("entity_type", EntityEnclosure.EntityType.ENTRUST_REPORT);
wrapper.eq("entity_id", entrustVo.getId());
wrapper.eq("is_deleted", 1);
List<EntityEnclosure> entityEnclosureList = entityEnclosureMapper.selectList(wrapper);
if(entityEnclosureList != null && entityEnclosureList.size()>0 ){
EntityEnclosure entityEnclosure = entityEnclosureList.get(0);
entrustVo.setAlias(entityEnclosure.getAlias());
entrustVo.setEnclosureUrl(entityEnclosure.getPdfUrl());
entrustVo.setExtName(entityEnclosure.getExtName());
}
}
return BaseResponse.okData(entrustVo);
}
......@@ -1206,7 +1207,14 @@ public class EntrustServiceImpl extends ServiceImpl<EntrustMapper, Entrust> impl
return BaseResponse.errorMsg("接受或完成的状态信息错误");
}
handleStatus = shVo.getStatus() == 1 ? 1 : (shVo.getStatus() == 2 ? 2 : 0);
String contentName = "";
Handle handle = handleMapper.selectById(shVo.getHandleId());
if (handle == null) {
return BaseResponse.errorMsg("选择的处理项信息有误");
}
String contentName = handle.getName();
/* String contentName = "";
if (shVo.getContent() != null) {
String[] handIdS = shVo.getContent().split("、");
List<SampleHandleEnclosure> sampleHandleEnclosureList = new ArrayList<>();
......@@ -1217,7 +1225,7 @@ public class EntrustServiceImpl extends ServiceImpl<EntrustMapper, Entrust> impl
}
contentName = contentName.equals("") ? handle.getName() : contentName + "、" + handle.getName();
}
}
}*/
shVo.setContentName(contentName);
}
}
......@@ -2473,7 +2481,7 @@ public class EntrustServiceImpl extends ServiceImpl<EntrustMapper, Entrust> impl
Map<String, Object> params = new HashMap<>();
params.put("startDate", startDate);
params.put("endDate", endDate);
params.put("status", 8);
params.put("reportStatus", 4);
params.put("clientId", clientId);
params.put("projectName", projectName);
params.put("projectCode", projectCode);
......
......@@ -103,7 +103,8 @@ public class TeamServiceImpl extends ServiceImpl<TeamMapper, Team> implements IT
return BaseResponse.errorMsg(query.getName() + "已存在");
}
BeanUtils.copyProperties(query, create);
create.setStatus(1).setCreateTime(LocalDateTime.now());
//no_check 标识校核计算的时候不显示计算的结果,因为没有公式
create.setStatus(1).setCreateTime(LocalDateTime.now()).setRemark("no_check");
teamMapper.insert(create);
return BaseResponse.okData(create);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment