From bd96ecd68841a7115231131bce5ba874914b89b5 Mon Sep 17 00:00:00 2001
From: yxFwq <1>
Date: 星期五, 03 一月 2025 15:33:58 +0800
Subject: [PATCH] #
---
src/main/java/com/zy/asrs/controller/OrderController.java | 30 ++++++++++++++++++++++++++++++
1 files changed, 30 insertions(+), 0 deletions(-)
diff --git a/src/main/java/com/zy/asrs/controller/OrderController.java b/src/main/java/com/zy/asrs/controller/OrderController.java
index fd50042..bf673f9 100644
--- a/src/main/java/com/zy/asrs/controller/OrderController.java
+++ b/src/main/java/com/zy/asrs/controller/OrderController.java
@@ -12,12 +12,14 @@
import com.zy.asrs.entity.result.WrkTraceVo;
import com.zy.asrs.service.*;
+import com.zy.asrs.utils.FileSaveExampleUtil;
import com.zy.common.model.DetlDto;
import com.zy.common.web.BaseController;
import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.transaction.annotation.Transactional;
import org.springframework.web.bind.annotation.*;
+import org.springframework.web.multipart.MultipartFile;
import java.util.*;
@@ -417,4 +419,32 @@
return R.ok();
}
+ @RequestMapping(value = "/order/insert/labelUp/file/auth")
+// @ManagerAuth
+ public R insertLabelUpFile(@RequestParam("orderId") String orderId,@RequestParam MultipartFile file){
+ String[] split = orderId.split("-");
+ int id = Integer.parseInt(split[1]);
+ System.out.println("---寮�濮�---");
+ String savePath = "D:/order/labelUp/file/"+id+"/"; // 鎸囧畾淇濆瓨鏂囦欢鐨勮矾寰�
+ try{
+ FileSaveExampleUtil.saveFile(file, savePath);
+ }catch (Exception e){
+ return R.error();
+ }
+ return R.ok();
+ }
+
+ @RequestMapping(value = "/order/view/labelUp/file/auth")
+// @ManagerAuth
+ public R viewLabelUpFile(@RequestParam("orderId") Long orderId){
+// int id = Integer.parseInt(orderId);
+ String savePath = "D:/order/labelUp/file/"+orderId+"/"; // 鎸囧畾淇濆瓨鏂囦欢鐨勮矾寰�
+ try{
+ List<FileSaveExampleUtil.FileDTO> fileDTOS = FileSaveExampleUtil.viewFileList(savePath);
+ return R.ok(fileDTOS);
+ }catch (Exception e){
+ return R.error();
+ }
+ }
+
}
--
Gitblit v1.9.1