From 9abf3d239625426e2664f6dfc3a4bd40247a8d0d Mon Sep 17 00:00:00 2001
From: Fancy <Fancy.fx@outlook.com>
Date: 星期二, 16 七月 2024 09:08:52 +0800
Subject: [PATCH] add workid in history

---
 pms-parent/pms-web-station/src/main/java/com/dy/pmsStation/assemblyStep/AssemblyStepCtrl.java |   29 +++++++++++++++++++++++++++++
 1 files changed, 29 insertions(+), 0 deletions(-)

diff --git a/pms-parent/pms-web-station/src/main/java/com/dy/pmsStation/assemblyStep/AssemblyStepCtrl.java b/pms-parent/pms-web-station/src/main/java/com/dy/pmsStation/assemblyStep/AssemblyStepCtrl.java
index b120df7..3033db5 100644
--- a/pms-parent/pms-web-station/src/main/java/com/dy/pmsStation/assemblyStep/AssemblyStepCtrl.java
+++ b/pms-parent/pms-web-station/src/main/java/com/dy/pmsStation/assemblyStep/AssemblyStepCtrl.java
@@ -1,5 +1,6 @@
 package com.dy.pmsStation.assemblyStep;
 
+import com.alibaba.excel.util.StringUtils;
 import com.dy.common.webUtil.BaseResponse;
 import com.dy.common.webUtil.BaseResponseUtils;
 import com.dy.pmsGlobal.pojoPlt.PltProductFile;
@@ -7,12 +8,15 @@
 import com.dy.pmsGlobal.pojoPlt.PltProductQualityInspectionItems;
 import com.dy.pmsGlobal.pojoPlt.PltProductTestInspectionItems;
 import com.dy.pmsGlobal.pojoPr.PrProductionNode;
+import com.dy.pmsGlobal.pojoSta.StaDeviceLife;
+import com.dy.pmsGlobal.pojoSta.StaDeviceProductionLog;
 import jakarta.validation.Valid;
 import lombok.extern.slf4j.Slf4j;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.web.bind.annotation.*;
 
 import java.util.List;
+import java.util.Map;
 
 /**
  *璁板綍缁勮鍚勬楠�
@@ -109,4 +113,29 @@
             return BaseResponseUtils.buildSuccess(true);
         }
     }
+
+    @GetMapping(path = "queryByDeviceNo")
+    public BaseResponse<Map<String,String>> queryByDeviceNo(String deviceNo) {
+        log.info("AssemblyStepCtrl.queryByDeviceNo():"+deviceNo);
+        Map<String,String> result = sv.queryByDeviceNo(deviceNo);
+        if(StringUtils.isBlank(result.get("proName"))){
+            return BaseResponseUtils.buildFail("璇ョ紪鐮�("+deviceNo +")涓嶆槸涓昏鐗╂枡(绯荤粺涓鎺х殑鍏朵粬璁惧)");
+        }else{
+            return BaseResponseUtils.buildSuccess(result);
+        }
+    }
+
+    @GetMapping(path = "queryLifeByDeviceNo")
+    public BaseResponse<?> queryLifeByDeviceNo(String deviceNo) {
+        log.info("AssemblyStepCtrl.queryLifeByDeviceNo():"+deviceNo);
+        List<StaDeviceLife> result = sv.queryLifeByDeviceNo(deviceNo);
+        return BaseResponseUtils.buildSuccess(result);
+    }
+
+    @GetMapping(path = "queryLogByDeviceNo")
+    public BaseResponse<?> queryLogByDeviceNo(String deviceNo) {
+        log.info("AssemblyStepCtrl.queryLogByDeviceNo():"+deviceNo);
+        List<StaDeviceProductionLog> result = sv.queryLogByDeviceNo(deviceNo);
+        return BaseResponseUtils.buildSuccess(result);
+    }
 }

--
Gitblit v1.8.0