口蹄疫兰所单板临界值数据修改

dev
litao 3 years ago
parent c2105eae7a
commit 6957a7450a
  1. 79
      lab-service/lab-capital/src/main/java/org/springblade/lims/goods/controller/ApplyController.java
  2. 1
      lab-service/lab-lims/src/main/java/org/springblade/lims/controller/ContractController.java
  3. 2
      lab-service/lab-lims/src/main/java/org/springblade/lims/controller/RepairApplicationController.java
  4. 2
      lab-service/lab-lims/src/main/java/org/springblade/lims/controller/RetentionSimpleDestroyLogController.java
  5. 2
      lab-service/lab-lims/src/main/java/org/springblade/lims/controller/ScrapApplicationController.java
  6. 2
      lab-service/lab-lims/src/main/java/org/springblade/lims/service/impl/EntrustServiceImpl.java
  7. 1
      lab-service/lab-lims/src/main/java/org/springblade/lims/service/impl/TaskBlueprintServiceImpl.java

@ -3,7 +3,6 @@ package org.springblade.lims.goods.controller;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage; import com.baomidou.mybatisplus.core.metadata.IPage;
import com.mysql.cj.util.StringUtils;
import io.swagger.annotations.Api; import io.swagger.annotations.Api;
import lombok.AllArgsConstructor; import lombok.AllArgsConstructor;
import org.springblade.core.boot.ctrl.BladeController; import org.springblade.core.boot.ctrl.BladeController;
@ -23,12 +22,9 @@ import org.springblade.lims.goods.service.IGoodsService;
import org.springblade.lims.goods.vo.ApplyVO; import org.springblade.lims.goods.vo.ApplyVO;
import org.springblade.resource.enums.SysTypeEnum; import org.springblade.resource.enums.SysTypeEnum;
import org.springblade.resource.feign.IMessageClient; import org.springblade.resource.feign.IMessageClient;
import org.springblade.system.cache.DictBizCache;
import org.springblade.system.enums.DictBizEnum;
import org.springblade.system.feign.ISysClient; import org.springblade.system.feign.ISysClient;
import org.springblade.system.user.entity.User; import org.springblade.system.user.entity.User;
import org.springblade.system.user.feign.IUserClient; import org.springblade.system.user.feign.IUserClient;
import org.springframework.transaction.annotation.Transactional;
import org.springframework.web.bind.annotation.*; import org.springframework.web.bind.annotation.*;
import javax.servlet.http.HttpServletResponse; import javax.servlet.http.HttpServletResponse;
@ -168,6 +164,7 @@ public class ApplyController extends BladeController {
// 消息通知 // 消息通知
if (userList != null) { if (userList != null) {
for (User user : userList) { for (User user : userList) {
// id硬编码
if ("1542095624162525185".equals(user.getRoleId())) { if ("1542095624162525185".equals(user.getRoleId())) {
apply.setApproveUserId(user.getId()); apply.setApproveUserId(user.getId());
apply.setApproveUser(user.getName()); apply.setApproveUser(user.getName());
@ -176,6 +173,7 @@ public class ApplyController extends BladeController {
} }
} }
} }
// id硬编码
messageClient.event(SysTypeEnum.INFORM.getValue(), "申领出库", messageClient.event(SysTypeEnum.INFORM.getValue(), "申领出库",
"你有新的申领单待出库,请及时处理", 1, 5, "1533753689484058625", "/capital/shenlingList"); "你有新的申领单待出库,请及时处理", 1, 5, "1533753689484058625", "/capital/shenlingList");
} else { } else {
@ -183,6 +181,7 @@ public class ApplyController extends BladeController {
// 消息通知 // 消息通知
if (userList != null) { if (userList != null) {
for (User user : userList) { for (User user : userList) {
// id硬编码
if ("1542095624162525185".equals(user.getRoleId())) { if ("1542095624162525185".equals(user.getRoleId())) {
messageClient.event(SysTypeEnum.INFORM.getValue(), "申领审核", messageClient.event(SysTypeEnum.INFORM.getValue(), "申领审核",
"你有新的申领单待审核,请及时处理", 1, 5, user.getId().toString(), "/capital/shenlingList"); "你有新的申领单待审核,请及时处理", 1, 5, user.getId().toString(), "/capital/shenlingList");
@ -248,6 +247,7 @@ public class ApplyController extends BladeController {
// 通过 // 通过
if (apply.getStatus() == 1) { if (apply.getStatus() == 1) {
// 消息通知 // 消息通知
// id硬编码
messageClient.event(SysTypeEnum.INFORM.getValue(), "申领出库", messageClient.event(SysTypeEnum.INFORM.getValue(), "申领出库",
"你有新的申领单待出库,请及时处理", 1, 5, "1533753689484058625", "/capital/shenlingList"); "你有新的申领单待出库,请及时处理", 1, 5, "1533753689484058625", "/capital/shenlingList");
} }
@ -376,44 +376,7 @@ public class ApplyController extends BladeController {
*/ */
@PostMapping("/return") @PostMapping("/return")
public void reture(@RequestBody Apply apply) { public void reture(@RequestBody Apply apply) {
boolean isComplete = true; applyService.reture(apply);
List<ApplyDetail> applyDetails = apply.getApplyDetails();
if (applyDetails != null && applyDetails.size() > 0) {
for (ApplyDetail detail : applyDetails) {
// 库存入库
Goods goods = goodsService.getById(detail.getProductId());
goods.setNum(goods.getNum() + detail.getReturnNum());
goodsService.updateById(goods);
//批次数量回填(批次数量入库)
LambdaQueryWrapper<ProductStoreDetial> wrapper = new LambdaQueryWrapper<>();
wrapper.eq(ProductStoreDetial::getGoodsId, detail.getProductId())
.eq(ProductStoreDetial::getPNum, detail.getBatchNum());
ProductStoreDetial productStoreDetail = productStoreDetialService.getOne(wrapper);
productStoreDetail.setNum(productStoreDetail.getNum() + detail.getReturnNum());
productStoreDetialService.updateById(productStoreDetail);
if (detail.getIsReturn() != 1) {
ApplyDetail byId = applyDetailService.getById(detail.getId());
if (byId != null) {
Integer total = byId.getReturnNum() + detail.getReturnNum();
if (detail.getOutNum().equals(total)) {
detail.setIsReturn(1);
}
detail.setReturnNum(total);
}
}
}
for (ApplyDetail detail : applyDetails) {
if (detail.getIsReturn() == 0) {
isComplete = false;
break;
}
}
}
apply.setStatus(isComplete ? 4 : 3);
applyService.updateById(apply);
applyDetailService.updateBatchById(applyDetails);
} }
/** /**
@ -428,7 +391,6 @@ public class ApplyController extends BladeController {
// 申领详情 // 申领详情
LambdaQueryWrapper<ApplyDetail> wrapper = new LambdaQueryWrapper<>(); LambdaQueryWrapper<ApplyDetail> wrapper = new LambdaQueryWrapper<>();
wrapper.eq(ApplyDetail::getApplyId, apply.getId()); wrapper.eq(ApplyDetail::getApplyId, apply.getId());
// wrapper.isNotNull(ApplyDetail::getReturnTime);
List<ApplyDetail> applyDetails = applyDetailService.list(wrapper); List<ApplyDetail> applyDetails = applyDetailService.list(wrapper);
if (applyDetails != null && applyDetails.size() > 0) { if (applyDetails != null && applyDetails.size() > 0) {
for (ApplyDetail detail : applyDetails) { for (ApplyDetail detail : applyDetails) {
@ -442,7 +404,7 @@ public class ApplyController extends BladeController {
} }
/** /**
* 8.查看详情 * 9.查看详情
*/ */
@GetMapping("/applyInfo") @GetMapping("/applyInfo")
public R<Apply> applyInfo(Apply apply) { public R<Apply> applyInfo(Apply apply) {
@ -464,42 +426,19 @@ public class ApplyController extends BladeController {
} }
/** /**
* 9.更改申领单或申领物品信息 * 10.更改申领单或申领物品信息
*/ */
@PostMapping("/updateApplyOrDetails") @PostMapping("/updateApplyOrDetails")
@Transactional(rollbackFor = Exception.class)
public boolean updateApplyOrDetails(@RequestBody Apply apply) { public boolean updateApplyOrDetails(@RequestBody Apply apply) {
// List<ApplyDetail> applyDetails = apply.getApplyDetails(); return applyService.updateApplyOrDetails(apply);
// if (applyDetails != null && applyDetails.size() > 0) {
// for (ApplyDetail applyDetail : applyDetails) {
// applyDetail.setOutNum(applyDetail.getNewOutNum());
// }
// applyDetailService.updateBatchById(applyDetails);
// }
// return applyService.updateById(apply);
LambdaQueryWrapper<ApplyDetail> wrapper = new LambdaQueryWrapper<>();
wrapper.eq(ApplyDetail::getApplyId, apply.getId());
List<ApplyDetail> details = applyDetailService.list(wrapper);
for (ApplyDetail detail : details) {
if (detail.getReturnTime() != null) {
apply.setStatus(3);
break;
} else {
apply.setStatus(4);
}
}
return applyService.updateById(apply);
} }
/** /**
* 10.出库单打印 * 11.出库单打印
*/ */
@GetMapping("/print") @GetMapping("/print")
public void print(String id, HttpServletResponse response) { public void print(String id, HttpServletResponse response) {
applyService.print(id, response); applyService.print(id, response);
} }
} }

@ -133,6 +133,7 @@ public class ContractController extends BladeController {
&& byId.getAssessorId() != null && byId.getAssessorId() != null
&& byId.getAssessorId().split(",").length == byId.getAppointAssessorId().split(",").length) { && byId.getAssessorId().split(",").length == byId.getAppointAssessorId().split(",").length) {
// 消息通知1 // 消息通知1
// id硬编码
messageClient.event(SysTypeEnum.INFORM.getValue(), "新增委托", messageClient.event(SysTypeEnum.INFORM.getValue(), "新增委托",
"您的合同已评审完成,请及时处理", 1, 5, "1542330472226856962","/plugin/workflow/process/contractList"); "您的合同已评审完成,请及时处理", 1, 5, "1542330472226856962","/plugin/workflow/process/contractList");
byId.setStatus(1); byId.setStatus(1);

@ -101,6 +101,7 @@ public class RepairApplicationController extends BladeController {
// 确认 // 确认
if (repairApplication.getStatus() == 1) { if (repairApplication.getStatus() == 1) {
// 发送提示消息 // 发送提示消息
// id硬编码
messageClient.event(SysTypeEnum.INFORM.getValue(), "报修审核", messageClient.event(SysTypeEnum.INFORM.getValue(), "报修审核",
"您有新的报修申请单待审核,请及时处理", 1, 5, "1555122570980995073","/repair/proposer"); "您有新的报修申请单待审核,请及时处理", 1, 5, "1555122570980995073","/repair/proposer");
repairApplication.setApplyDeptUser(AuthUtil.getUserId()); repairApplication.setApplyDeptUser(AuthUtil.getUserId());
@ -110,6 +111,7 @@ public class RepairApplicationController extends BladeController {
// 审核 // 审核
if (repairApplication.getStatus() == 2) { if (repairApplication.getStatus() == 2) {
// 发送提示消息 // 发送提示消息
// id硬编码
messageClient.event(SysTypeEnum.INFORM.getValue(), "报修审批", messageClient.event(SysTypeEnum.INFORM.getValue(), "报修审批",
"您有新的报修申请单待审批,请及时处理", 1, 5, "1552118581265973249","/repair/proposer"); "您有新的报修申请单待审批,请及时处理", 1, 5, "1552118581265973249","/repair/proposer");
repairApplication.setReviewDate(new Date()); repairApplication.setReviewDate(new Date());

@ -71,6 +71,7 @@ public class RetentionSimpleDestroyLogController extends BladeController {
public R update(@RequestBody RetentionSimpleDestroyLog retentionSample) { public R update(@RequestBody RetentionSimpleDestroyLog retentionSample) {
if (retentionSample.getStatus() == 1) { if (retentionSample.getStatus() == 1) {
// 发送提示消息 // 发送提示消息
// id硬编码
messageClient.event(SysTypeEnum.INFORM.getValue(), "销毁处理", messageClient.event(SysTypeEnum.INFORM.getValue(), "销毁处理",
"你有样品销毁申请待处理,请及时查看", 1, 5, "1542096837247541250","/limsConfig/destruction"); "你有样品销毁申请待处理,请及时查看", 1, 5, "1542096837247541250","/limsConfig/destruction");
} }
@ -100,6 +101,7 @@ public class RetentionSimpleDestroyLogController extends BladeController {
retentionSample.setManagerSuggertTime(new Date()); retentionSample.setManagerSuggertTime(new Date());
retentionSample.setStatus(0); retentionSample.setStatus(0);
// 发送提示消息 // 发送提示消息
// id硬编码
messageClient.event(SysTypeEnum.INFORM.getValue(), "销毁审批", messageClient.event(SysTypeEnum.INFORM.getValue(), "销毁审批",
"你有样品销毁申请待审批,请及时处理", 1, 5, "","/limsConfig/destruction"); "你有样品销毁申请待审批,请及时处理", 1, 5, "","/limsConfig/destruction");
return R.data(service.save(retentionSample)); return R.data(service.save(retentionSample));

@ -73,6 +73,7 @@ public class ScrapApplicationController extends BladeController {
// 确认 // 确认
if (scrapApplication.getStatus() == 1) { if (scrapApplication.getStatus() == 1) {
// 发送提示消息 // 发送提示消息
// id硬编码
messageClient.event(SysTypeEnum.INFORM.getValue(), "报修审核", messageClient.event(SysTypeEnum.INFORM.getValue(), "报修审核",
"您有新的报修申请单待审核,请及时处理", 1, 5, "1555122570980995073","/repair/proposer"); "您有新的报修申请单待审核,请及时处理", 1, 5, "1555122570980995073","/repair/proposer");
scrapApplication.setApplyDeptUser(AuthUtil.getUserId()); scrapApplication.setApplyDeptUser(AuthUtil.getUserId());
@ -82,6 +83,7 @@ public class ScrapApplicationController extends BladeController {
// 审核 // 审核
if (scrapApplication.getStatus() == 2) { if (scrapApplication.getStatus() == 2) {
// 发送提示消息 // 发送提示消息
// id硬编码
messageClient.event(SysTypeEnum.INFORM.getValue(), "报修审批", messageClient.event(SysTypeEnum.INFORM.getValue(), "报修审批",
"您有新的报修申请单待审批,请及时处理", 1, 5, "1552118581265973249","/repair/proposer"); "您有新的报修申请单待审批,请及时处理", 1, 5, "1552118581265973249","/repair/proposer");
scrapApplication.setReviewDate(new Date()); scrapApplication.setReviewDate(new Date());

@ -1638,7 +1638,7 @@ public class EntrustServiceImpl extends BaseServiceImpl<EntrustMapper, Entrust>
String format2 = df.format((collect.get(1) + collect.get(2)) / 4); String format2 = df.format((collect.get(1) + collect.get(2)) / 4);
ExamineDataArrVO examineDataArrVO = new ExamineDataArrVO(); ExamineDataArrVO examineDataArrVO = new ExamineDataArrVO();
examineDataArrVO.setNum("临界值"); examineDataArrVO.setNum("临界值");
examineDataArrVO.setValue(format2); examineDataArrVO.setLog2(format2);
examineDataArrVO.setResult(""); examineDataArrVO.setResult("");
list1.add(examineDataArrVO); list1.add(examineDataArrVO);
list1.addAll(voList); list1.addAll(voList);

@ -303,6 +303,7 @@ public class TaskBlueprintServiceImpl extends BaseServiceImpl<TaskBlueprintMappe
if (userList != null) { if (userList != null) {
for (User user : userList) { for (User user : userList) {
// position1 // position1
// id硬编码
if ("1432876315142520834".equals(user.getRoleId())) { if ("1432876315142520834".equals(user.getRoleId())) {
messageClient.event(SysTypeEnum.INFORM.getValue(), "新的检验", messageClient.event(SysTypeEnum.INFORM.getValue(), "新的检验",
"你有新的检验待领取,请及时处理", 1, 5, user.getId().toString(), "/plugin/workflow/process/experimentcrew"); "你有新的检验待领取,请及时处理", 1, 5, user.getId().toString(), "/plugin/workflow/process/experimentcrew");

Loading…
Cancel
Save