From a8ddac646d5129e9818ea82f404d0c0a8d2bc239 Mon Sep 17 00:00:00 2001
From: Lius <Lius2225@163.com>
Date: 星期四, 09 十一月 2023 10:39:25 +0800
Subject: [PATCH] 设备参数阈值管理接口
---
lxzn-module-eam/src/main/java/org/jeecg/modules/eam/controller/PrecisionInspectionController.java | 23 ++++++++++++++++-------
1 files changed, 16 insertions(+), 7 deletions(-)
diff --git a/lxzn-module-eam/src/main/java/org/jeecg/modules/eam/controller/PrecisionInspectionController.java b/lxzn-module-eam/src/main/java/org/jeecg/modules/eam/controller/PrecisionInspectionController.java
index e51a1fb..b6375ac 100644
--- a/lxzn-module-eam/src/main/java/org/jeecg/modules/eam/controller/PrecisionInspectionController.java
+++ b/lxzn-module-eam/src/main/java/org/jeecg/modules/eam/controller/PrecisionInspectionController.java
@@ -2,6 +2,7 @@
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
+import com.baomidou.mybatisplus.core.toolkit.StringUtils;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
@@ -13,10 +14,7 @@
import org.jeecg.common.system.query.QueryGenerator;
import org.jeecg.common.system.vo.LoginUser;
import org.jeecg.modules.eam.entity.*;
-import org.jeecg.modules.eam.service.IDailyMaintenanceOrderService;
-import org.jeecg.modules.eam.service.IPrecisionInspectionDetailService;
-import org.jeecg.modules.eam.service.IPrecisionInspectionService;
-import org.jeecg.modules.eam.service.IPrecisionParametersService;
+import org.jeecg.modules.eam.service.*;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;
import org.springframework.web.servlet.ModelAndView;
@@ -49,6 +47,9 @@
@Autowired
private IPrecisionParametersService precisionParametersService;
+
+ @Autowired
+ private IEamEquipmentService equipmentService;
/**
* 鍒嗛〉鍒楄〃鏌ヨ
@@ -203,8 +204,11 @@
LoginUser sysUser = (LoginUser) SecurityUtils.getSubject().getPrincipal();
String userId = sysUser.getId();
+ String receipts = precisionInspection.getReceipts();//绮惧害妫�楠屽崟鍗曟嵁id
PrecisionInspection preInspection = precisionInspectionService.getById(precisionInspection.getId());
DailyMaintenanceOrder maintenanceOrder = dailyMaintenanceOrderService.getById(preInspection.getMaintenanceOrderId());
+ String maintenanceOrderUda4 = maintenanceOrder.getMaintenanceOrderUda4();
+ Equipment equipment = equipmentService.getById(maintenanceOrder.getEquipmentId());
String precisionInspectionStatus = maintenanceOrder.getPrecisionInspectionStatus();
if ("0".equals(precisionInspectionStatus)){
@@ -237,13 +241,18 @@
preInspection.setJudgmentResult(precisionInspection.getJudgmentResult());
maintenanceOrder.setPrecisionInspectionStatus("5");
- maintenanceOrder.setStatus("8");
+// maintenanceOrder.setStatus("8");
+ //鏇存柊璁惧鎶�鏈姸鎬�
+ equipment.setTechnologyStatus(precisionInspection.getJudgmentResult());
}
- preInspection.setRemark(precisionInspection.getRemark());
+ if(StringUtils.isBlank(maintenanceOrderUda4)){
+ maintenanceOrder.setMaintenanceOrderUda4(receipts);
+ }
dailyMaintenanceOrderService.updateById(maintenanceOrder);
+ preInspection.setRemark(precisionInspection.getRemark());
precisionInspectionService.updateById(preInspection);
-
+ equipmentService.updateById(equipment);
return Result.OK("瀹℃壒鎴愬姛!");
}
--
Gitblit v1.9.3