增加接受上传文件功能

This commit is contained in:
Kane 2023-01-23 00:20:35 +08:00
parent 8786ca207c
commit 0067999831
1 changed files with 32 additions and 0 deletions

View File

@ -0,0 +1,32 @@
/*
* @Author: Kane
* @Date: 2023-01-22 23:11:26
* @LastEditors: Kane
* @LastEditTime: 2023-01-22 23:47:15
* @FilePath: \AdminSys\src\main\java\com\cpic\xim\web\controllers\FileUpload\FileUpload.java
* @Description: 用于接受上传文件的Controller
*
* Copyright (c) ${2022} by Kane, All Rights Reserved.
*/
package com.cpic.xim.web.controllers.FileUpload;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.multipart.MultipartFile;
@SuppressWarnings( "unused" )
@Controller
@RequestMapping( path = "/file" )
public class FileUpload
{
@RequestMapping( path = "/file-upload.do" )
public void getUploadFile( @RequestParam( "task-name" ) String taskName,
@RequestParam( "file" ) MultipartFile[] files )
{
int fileCount = files.length;
return;
}
}