小生不才 1 year ago
parent
commit
e4ec0c8fa7

+ 1 - 2
jp-console/jeeplus-plugins/jeeplus-file/src/main/java/com/jeeplus/file/controller/FileController.java

@@ -14,7 +14,6 @@ import org.springframework.http.MediaType;
 import org.springframework.http.ResponseEntity;
 import org.springframework.util.StreamUtils;
 import org.springframework.web.bind.annotation.GetMapping;
-import org.springframework.web.bind.annotation.PostMapping;
 import org.springframework.web.bind.annotation.RequestMapping;
 import org.springframework.web.bind.annotation.RestController;
 import org.springframework.web.multipart.MultipartFile;
@@ -56,7 +55,7 @@ public class FileController {
      * @throws IOException
      * @throws IllegalStateException
      */
-    @PostMapping("download")
+    @GetMapping("download")
     public void download(String uploadPath, String name, HttpServletRequest request, HttpServletResponse response) throws Exception {
         String url = accessoryRepository.getURL ( uploadPath, name ,request, response);
         if( StrUtil.isNotEmpty ( url ) ){