From 9212801fbac08dd12b8205c217bdeb925529ab7c Mon Sep 17 00:00:00 2001
From: wangfei <3597712270@qq.com>
Date: 星期四, 27 二月 2025 09:55:22 +0800
Subject: [PATCH] Merge remote-tracking branch 'origin/master'

---
 hangzhoumesParent/moduleService/TemperingGlassModule/src/main/java/com/mes/temperingglass/controller/TemperingGlassInfoController.java |   31 +++++++++++++++++++++++++------
 1 files changed, 25 insertions(+), 6 deletions(-)

diff --git a/hangzhoumesParent/moduleService/TemperingGlassModule/src/main/java/com/mes/temperingglass/controller/TemperingGlassInfoController.java b/hangzhoumesParent/moduleService/TemperingGlassModule/src/main/java/com/mes/temperingglass/controller/TemperingGlassInfoController.java
index cb9a49f..e7cdac4 100644
--- a/hangzhoumesParent/moduleService/TemperingGlassModule/src/main/java/com/mes/temperingglass/controller/TemperingGlassInfoController.java
+++ b/hangzhoumesParent/moduleService/TemperingGlassModule/src/main/java/com/mes/temperingglass/controller/TemperingGlassInfoController.java
@@ -1,9 +1,13 @@
 package com.mes.temperingglass.controller;
+
 import com.mes.damage.entity.Damage;
 import com.mes.damage.service.DamageService;
-import com.mes.temperingglass.service.TemperingGlassInfoService;
+import com.mes.glassinfo.entity.GlassInfo;
+import com.mes.glassinfo.entity.LoadGlassInfo;
 import com.mes.temperingglass.entity.TemperingGlassInfo;
+import com.mes.temperingglass.service.TemperingGlassInfoService;
 import com.mes.utils.Result;
+import io.swagger.annotations.Api;
 import io.swagger.annotations.ApiOperation;
 import lombok.extern.slf4j.Slf4j;
 import org.springframework.beans.factory.annotation.Autowired;
@@ -15,6 +19,7 @@
 /**
  * @author SNG-010
  */
+@Api(tags = "閽㈠寲鏄剧ず")
 @RestController
 @RequestMapping("/temperingGlassInfo")
 @Slf4j
@@ -25,6 +30,7 @@
     private TemperingGlassInfoService temperingGlassInfoService;
     @Autowired
     private DamageService damageService;
+
 
     @ApiOperation("鏌ヨ閽㈠寲绛夌墖涓殑鐗堝浘淇℃伅,鐘舵�佷负1鐨勪负宸插埌,鐘舵�佷负0鐨勪负绛夊緟涓�")
     @GetMapping("/selectWaitingGlass") // 鏌ヨ閽㈠寲绛夌墖涓殑鐗堝浘淇℃伅,鐘舵�佷负1鐨勪负宸插埌,鐘舵�佷负0鐨勪负绛夊緟涓�
@@ -49,13 +55,26 @@
         temperingGlassInfo.setState(damage.getStatus());
         temperingGlassInfo.setGlassId(damage.getGlassId());
         int result=temperingGlassInfoService.updateTemperingState(temperingGlassInfo);
-//        if(damage.getStatus()>5) {
-//            damage.setType(damage.getStatus());
-//            damage.setStatus(1);
-//            damageService.insertDamage(damage);
-//        }
+        if (damage.getStatus() > 5) {
+            damageService.autoSubmitReport(damage.getGlassId(), damage.getLine()
+                    , damage.getWorkingProcedure(), "閽㈠寲鐐�", damage.getStatus());
+        }
         return Result.build(200, "鐮存崯鎴愬姛", result);
     }
 
+    @ApiOperation("//鏌ヨ褰撳墠宸ョ▼鍙锋墍鏈夌殑鐐夊彿")
+    @PostMapping("/selectTempering") //鏌ヨ褰撳墠宸ョ▼鍙锋墍鏈夌殑鐐夊彿
+    public Result<GlassInfo> selectTempering(@RequestBody GlassInfo glassInfo) {
+        GlassInfo glass = temperingGlassInfoService.selectTempering(glassInfo);
+        return Result.build(200, "鏌ヨ鎴愬姛", glass);
+    }
+
+    @ApiOperation("//鏌ヨ褰撳墠宸ョ▼鍙风殑閽㈠寲鐗堝浘")
+    @PostMapping("/selectTemperingGlass") //鏌ヨ褰撳墠宸ョ▼鍙锋墍鏈夌殑鐐夊彿
+    public Result<List<LoadGlassInfo>> selectTemperingGlass(@RequestBody GlassInfo glassInfo) {
+        List<LoadGlassInfo> glass = temperingGlassInfoService.selectTemperingGlass(glassInfo);
+        return Result.build(200, "鏌ヨ鎴愬姛", glass);
+    }
+
 
 }

--
Gitblit v1.8.0