From f7a2fcdda7f1120498c5c5f75c5a99955fc54b43 Mon Sep 17 00:00:00 2001
From: 廖井涛 <2265517004@qq.com>
Date: 星期二, 16 十二月 2025 16:54:09 +0800
Subject: [PATCH] Merge branch 'master' of http://10.153.19.25:10105/r/ERP_override
---
north-glass-erp/src/main/java/com/example/erp/controller/mm/FinishedGoodsInventoryController.java | 227 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++
1 files changed, 227 insertions(+), 0 deletions(-)
diff --git a/north-glass-erp/src/main/java/com/example/erp/controller/mm/FinishedGoodsInventoryController.java b/north-glass-erp/src/main/java/com/example/erp/controller/mm/FinishedGoodsInventoryController.java
new file mode 100644
index 0000000..a5df64c
--- /dev/null
+++ b/north-glass-erp/src/main/java/com/example/erp/controller/mm/FinishedGoodsInventoryController.java
@@ -0,0 +1,227 @@
+package com.example.erp.controller.mm;
+
+
+
+import cn.dev33.satoken.annotation.SaCheckPermission;
+import com.example.erp.common.Constants;
+import com.example.erp.common.Result;
+import com.example.erp.dto.mm.FinishedOperateLogDTO;
+import com.example.erp.entity.mm.FinishedOperateLog;
+import com.example.erp.entity.pp.FlowCard;
+import com.example.erp.entity.sd.Order;
+import com.example.erp.entity.sd.OrderDetail;
+import com.example.erp.exception.ServiceException;
+import com.example.erp.service.mm.FinishedGoodsInventoryService;
+import com.example.erp.tools.DownExcel;
+import io.swagger.annotations.Api;
+import io.swagger.annotations.ApiOperation;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.*;
+import com.example.erp.entity.mm.FinishedGoodsInventory;
+
+
+import javax.servlet.http.HttpServletResponse;
+import java.io.IOException;
+import java.time.LocalDate;
+import java.util.List;
+import java.util.Map;
+
+@RestController
+@RequestMapping("/finishedGoodsInventory")
+@Api(value="鎴愬搧搴撳瓨controller",tags={"鎴愬搧搴撳瓨鎿嶄綔鎺ュ彛"})
+public class FinishedGoodsInventoryController {
+ @Autowired
+ FinishedGoodsInventoryService finishedGoodsInventoryService;
+
+ /*鎴愬搧搴撳瓨鏌ヨ*/
+ @ApiOperation("鎴愬搧搴撳瓨鏌ヨ鎺ュ彛")
+ @SaCheckPermission("productStockList.search")
+ @PostMapping("/getSelect/{pageNum}/{pageSize}")
+ public Result defaultDateFinishedGoodsInventory(@PathVariable Integer pageNum, @PathVariable Integer pageSize, @RequestBody FinishedGoodsInventory finishedGoodsInventory){
+ return Result.success(finishedGoodsInventoryService.defaultDateFinishedGoodsInventory(pageNum,pageSize,finishedGoodsInventory));
+ }
+
+ /*鏌ヨ鍙叆搴撶殑鎴愬搧鏁版嵁*/
+ @ApiOperation("鍙叆搴撶殑鎴愬搧鏌ヨ鎺ュ彛")
+ @SaCheckPermission("createProductStock.search")
+ @PostMapping("/getSelectWarehousing/{pageNum}/{pageSize}")
+ public Result getSelectWarehousing(@PathVariable Integer pageNum, @PathVariable Integer pageSize, @RequestBody FlowCard flowCard){
+ return Result.success(finishedGoodsInventoryService.getSelectWarehousing(pageNum,pageSize,flowCard));
+ }
+
+ /*鎴愬搧鍏ュ簱*/
+ @ApiOperation("鎴愬搧鍏ュ簱鎺ュ彛")
+ @SaCheckPermission("createProductStock.add")
+ @PostMapping("/addSelectWarehousing")
+ public Result addSelectWarehousing( @RequestBody Map<String,Object> object){
+ return Result.success(finishedGoodsInventoryService.addSelectWarehousing(object));
+
+ }
+
+ /*鏌ヨ鍙彂璐х殑鎴愬搧鏁版嵁*/
+ @ApiOperation("鍙彂璐х殑鎴愬搧鏌ヨ鎺ュ彛")
+ @SaCheckPermission("finishedProductOut.search")
+ @PostMapping("/getSelectDeliveryDetail/{pageNum}/{pageSize}")
+ public Result getSelectDeliveryDetail(@PathVariable Integer pageNum, @PathVariable Integer pageSize, @RequestBody OrderDetail orderDetail){
+ return Result.success(finishedGoodsInventoryService.getSelectDeliveryDetail(pageNum,pageSize,orderDetail));
+ }
+
+ /*鎴愬搧鍙戣揣*/
+ @ApiOperation("鎴愬搧鍙戣揣鎺ュ彛")
+ @SaCheckPermission("finishedProductOut.add")
+ @PostMapping("/addDeliveryDetail")
+ public Result addDeliveryDetail( @RequestBody Map<String,Object> object){
+ return Result.success(finishedGoodsInventoryService.addDeliveryDetail(object));
+ }
+
+ /* 璋冩嫧鏌ヨ*/
+ @ApiOperation("鍙皟鎷ㄦ暟鎹煡璇㈡帴鍙�")
+ @SaCheckPermission("orderAllocation.search")
+ @PostMapping("/getSelectAllocate/{pageNum}/{pageSize}")
+ public Result getSelectAllocate(@PathVariable Integer pageNum, @PathVariable Integer pageSize, @RequestBody OrderDetail orderDetail){
+ return Result.success(finishedGoodsInventoryService.getSelectAllocate(pageNum,pageSize,orderDetail));
+ }
+
+ /*璁㈠崟璋冩嫧*/
+ @ApiOperation("璁㈠崟璋冩嫧鎺ュ彛")
+ @SaCheckPermission("orderAllocation.add")
+ @PostMapping("/updateFinishedGoodsInventoryAllocate")
+ public Result updateFinishedGoodsInventoryAllocate( @RequestBody Map<String,Object> object){
+ return Result.success(finishedGoodsInventoryService.updateFinishedGoodsInventoryAllocate(object));
+ }
+
+ /*璋冩嫧璁板綍鏌ヨ*/
+ @ApiOperation("璋冩嫧璁板綍鏌ヨ鎺ュ彛")
+ @SaCheckPermission("transferRecord.search")
+ @PostMapping("/getSelectAllocateFinishedOperateLog/{pageNum}/{pageSize}/{selectDate}")
+ public Result getSelectAllocateFinishedOperateLog(@PathVariable Integer pageNum, @PathVariable Integer pageSize,@PathVariable List<String> selectDate, @RequestBody FinishedOperateLog finishedOperateLog){
+ return Result.success(finishedGoodsInventoryService.getSelectAllocateFinishedOperateLog(pageNum,pageSize,selectDate,finishedOperateLog));
+ }
+
+ /*璁㈠崟棰嗗嚭*/
+ @ApiOperation("璁㈠崟棰嗗嚭鎺ュ彛")
+ @SaCheckPermission("finishedGoodsIssue.add")
+ @PostMapping("/updateFinishedGoodsInventoryTakeOut")
+ public Result updateFinishedGoodsInventoryTakeOut( @RequestBody Map<String,Object> object){
+ return Result.success(finishedGoodsInventoryService.updateFinishedGoodsInventoryTakeOut(object));
+ }
+
+ /*棰嗗嚭璁板綍鏌ヨ*/
+ @ApiOperation("棰嗗嚭璁板綍鏌ヨ鎺ュ彛")
+ @SaCheckPermission("takeOutRecord.search")
+ @PostMapping("/getSelectOperateRecord/{pageNum}/{pageSize}/{selectDate}")
+ public Result getSelectOperateRecord(@PathVariable Integer pageNum, @PathVariable Integer pageSize,@PathVariable List<String> selectDate, @RequestBody FinishedOperateLog finishedOperateLog){
+ return Result.success(finishedGoodsInventoryService.getSelectOperateRecord(pageNum,pageSize,selectDate,finishedOperateLog));
+ }
+
+ /*璁㈠崟杩斿伐*/
+ @ApiOperation("璁㈠崟杩斿伐鏌ヨ鎺ュ彛")
+ @PostMapping("/updateFinishedGoodsInventoryRework")
+ public Result updateFinishedGoodsInventoryRework( @RequestBody Map<String,Object> object){
+ return Result.success(finishedGoodsInventoryService.updateFinishedGoodsInventoryRework(object));
+ }
+
+
+
+ /*璁㈠崟瀹℃牳*/
+ @ApiOperation("璁㈠崟瀹℃牳鎺ュ彛")
+ @SaCheckPermission("takeOutRecord.review")
+ @PostMapping("/updateFinishedGoodsInventoryToExamine")
+ public Result updateFinishedGoodsInventoryToExamine( @RequestBody Map<String,Object> object){
+ return Result.success(finishedGoodsInventoryService.updateFinishedGoodsInventoryToExamine(object,"瀹℃牳"));
+ }
+ /*璁㈠崟鍙嶅*/
+ @ApiOperation("璁㈠崟鍙嶅鎺ュ彛")
+ @SaCheckPermission("takeOutRecord.review")
+ @PostMapping("/updateFinishedGoodsInventoryCounterExamination")
+ public Result updateFinishedGoodsInventoryCounterExamination( @RequestBody Map<String,Object> object){
+ return Result.success(finishedGoodsInventoryService.updateFinishedGoodsInventoryToExamine(object,"鍙嶅"));
+ }
+
+ /*璁㈠崟浣滃簾*/
+ @ApiOperation("璁㈠崟浣滃簾鎺ュ彛")
+ @SaCheckPermission("takeOutRecord.update")
+ @PostMapping("/cancelFinishedGoodsInventoryToExamine")
+ public Result cancelFinishedGoodsInventoryToExamine( @RequestBody Map<String,Object> object){
+ return Result.success(finishedGoodsInventoryService.cancelFinishedGoodsInventoryToExamine(object));
+ }
+
+ /*鍑哄叆搴撹褰曟煡璇�*/
+ @ApiOperation("鍑哄叆搴撹褰曟煡璇㈡帴鍙�")
+ @SaCheckPermission("storageRecord.search")
+ @PostMapping("/getSelectStorageRecord/{pageNum}/{pageSize}/{selectDate}/{type}")
+ public Result getSelectStorageRecord(@PathVariable Integer pageNum, @PathVariable Integer pageSize,@PathVariable List<String> selectDate,@PathVariable String type, @RequestBody FinishedOperateLog finishedOperateLog){
+ return Result.success(finishedGoodsInventoryService.getSelectStorageRecord(pageNum,pageSize,selectDate,type,finishedOperateLog));
+ }
+
+ /*鍑哄叆搴撹繑鍥�*/
+ @ApiOperation("鍑哄叆搴撹繑鍥炴帴鍙�")
+ @SaCheckPermission("storageRecord.update")
+ @PostMapping("/cancelFinishedGoodsInventoryStorage")
+ public Result cancelFinishedGoodsInventoryStorage( @RequestBody Map<String,Object> object){
+ return Result.success(finishedGoodsInventoryService.cancelFinishedGoodsInventoryStorage(object));
+ }
+
+ @ApiOperation("鎴愬搧搴撳瓨璁板綍鏌ヨ鎺ュ彛")
+ @SaCheckPermission("warehouseReport.search")
+ @PostMapping("/getSelectFinishedOperateLogReport/{type}/{pageNum}/{pageSize}/{selectDate}")
+ public Result getSelectFinishedOperateLogReport(@PathVariable String type,@PathVariable Integer pageNum, @PathVariable Integer pageSize,@PathVariable List<String> selectDate, @RequestBody FinishedOperateLog finishedOperateLog){
+ return Result.success(finishedGoodsInventoryService.getSelectFinishedOperateLogReport(type,pageNum,pageSize,selectDate,finishedOperateLog));
+ }
+
+ @ApiOperation("鎴愬搧鎶ヨ〃瀵煎嚭")
+ @PostMapping("/exportFinishedOperateLogReport/{type}")
+ public void exportFinishedOperateLogReport(@PathVariable String type,HttpServletResponse response, @RequestBody List<LocalDate> dates) throws IOException, IllegalAccessException, InstantiationException {
+ //鍙傛暟锛氱浉搴旂殑鏁版嵁锛屽疄浣撶被淇℃伅锛岀浉搴旂殑鏂规硶锛堟暟鎹幏鍙栵級锛岀敓鎴愮殑excel鍚嶅瓧
+ DownExcel.download(response, FinishedOperateLogDTO.class, finishedGoodsInventoryService.exportFinishedOperateLogReport(dates,type),"orderReport");
+ }
+
+
+ /*璁㈠崟涓�閿叆搴�*/
+ @ApiOperation("璁㈠崟涓�閿叆搴�")
+ @SaCheckPermission("createProductStock.add")
+ @PostMapping("/oneClickStorage/{orderId}/{userName}")
+ public Result oneClickStorage( @PathVariable String orderId,@PathVariable String userName){
+ return Result.success(finishedGoodsInventoryService.oneClickStorage(orderId,userName));
+
+ }
+
+ /*瑁呯鎵撳嵃鏌ヨ*/
+ @ApiOperation("瑁呯鎵撳嵃鏌ヨ鎺ュ彛")
+ @SaCheckPermission("storageRecordPint.search")
+ @PostMapping("/getSelectStorageRecordPint/{pageNum}/{pageSize}/{selectDate}")
+ public Result getSelectStorageRecordPint(@PathVariable Integer pageNum, @PathVariable Integer pageSize,@PathVariable List<String> selectDate, @RequestBody FinishedOperateLog finishedOperateLog){
+ return Result.success(finishedGoodsInventoryService.getSelectStorageRecordPint(pageNum,pageSize,selectDate,finishedOperateLog));
+ }
+
+ /*瑁呯鎵撳嵃鏌ヨ*/
+ @ApiOperation("瑁呯鎵撳嵃鍐呭鏌ヨ鎺ュ彛")
+ @SaCheckPermission("storageRecordPint.search")
+ @PostMapping("/getSelectPrint")
+ public Result getSelectPrint( @RequestBody Map<String, Object> object){
+ return Result.success(finishedGoodsInventoryService.getSelectPrintSv(object));
+ }
+
+ /*瑁呯鎵撳嵃鏌ヨ*/
+ @ApiOperation("瑁呯鎵撳嵃鍐呭鏌ヨ鎺ュ彛")
+ @SaCheckPermission("storageRecordPint.search")
+ @PostMapping("/getSelectPrints")
+ public Result getSelectPrints( @RequestBody Map<String, Object> object){
+ return Result.success(finishedGoodsInventoryService.getSelectPrintSvs(object));
+ }
+ /*瑁呯鎵撳嵃鏌ヨ*/
+ @ApiOperation("搴撳瓨瑁呯鎵撳嵃鍐呭鏌ヨ鎺ュ彛")
+ @SaCheckPermission("createProductStock.search")
+ @PostMapping("/getInventoryPrints")
+ public Result getInventoryPrints( @RequestBody List<FinishedGoodsInventory> finishedGoodsInventories){
+ return Result.success(finishedGoodsInventoryService.getInventoryPrints(finishedGoodsInventories));
+ }
+
+ @ApiOperation("鎴愬搧瑁呯璋冩灦")
+ @SaCheckPermission("createProductStock.add")
+ @PostMapping("/changeRack/{user}")
+ public Result changeRack( @RequestBody FinishedGoodsInventory finishedGoodsInventory,@PathVariable String user){
+ return Result.success(finishedGoodsInventoryService.changeRack(finishedGoodsInventory,user));
+
+ }
+}
--
Gitblit v1.8.0