From ec7d3b867e7b7f5073dda1684a8720424b9da5ad Mon Sep 17 00:00:00 2001
From: gongchunyi <deslre0381@gmail.com>
Date: 星期二, 24 三月 2026 15:38:00 +0800
Subject: [PATCH] feat: 生产报工的详情、修改、删除接口
---
src/main/java/com/ruoyi/production/controller/ProductionRecordController.java | 26 +++++++++++++++++++++-----
1 files changed, 21 insertions(+), 5 deletions(-)
diff --git a/src/main/java/com/ruoyi/production/controller/ProductionRecordController.java b/src/main/java/com/ruoyi/production/controller/ProductionRecordController.java
index dd77ee0..dff868e 100644
--- a/src/main/java/com/ruoyi/production/controller/ProductionRecordController.java
+++ b/src/main/java/com/ruoyi/production/controller/ProductionRecordController.java
@@ -8,10 +8,6 @@
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;
-import org.springframework.web.multipart.MultipartFile;
-
-import java.util.ArrayList;
-import java.util.List;
/**
* <br>
@@ -37,7 +33,6 @@
return AjaxResult.success(vo);
}
-
@PostMapping("/add")
@ApiOperation("鐢熶骇鎶ュ伐-鏂板")
public AjaxResult addProductionRecordService(@RequestBody ProductionRecordDto dto) {
@@ -45,4 +40,25 @@
return AjaxResult.success();
}
+ @DeleteMapping("/{productMainId}")
+ @ApiOperation("鐢熶骇鎶ュ伐-鍒犻櫎")
+ public AjaxResult deleteProductMain(@PathVariable Long productMainId) {
+ productionRecordService.deleteProductMain(productMainId);
+ return AjaxResult.success();
+ }
+
+ @GetMapping("/detail/{productMainId}")
+ @ApiOperation("鐢熶骇鎶ュ伐-璇︽儏")
+ public AjaxResult detailProductMain(@PathVariable Long productMainId) {
+ ProductionRecordDto dto = productionRecordService.detailProductMain(productMainId);
+ return AjaxResult.success(dto);
+ }
+
+ @PostMapping("/edit")
+ @ApiOperation("鐢熶骇鎶ュ伐-缂栬緫")
+ public AjaxResult editProductMain(@RequestBody ProductionRecordDto dto) {
+ productionRecordService.editProductMain(dto);
+ return AjaxResult.success();
+ }
+
}
--
Gitblit v1.9.3