新增APP查询文件列表接口
This commit is contained in:
parent
68c869fc8e
commit
d4f52b82b8
@ -7,6 +7,7 @@ import com.cm.common.constants.ISystemConstant;
|
||||
import com.cm.common.enums.UploadTypeEnum;
|
||||
import com.cm.common.exception.base.SystemException;
|
||||
import com.cm.common.plugin.service.file.IFileService;
|
||||
import com.cm.common.pojo.dtos.FileDTO;
|
||||
import com.cm.common.result.ErrorResult;
|
||||
import com.cm.common.result.SuccessResultData;
|
||||
import io.swagger.annotations.*;
|
||||
@ -15,6 +16,8 @@ import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
@ -102,6 +105,17 @@ public class FileAppController extends AbstractController {
|
||||
return fileService.wangEditorImage(image, UploadTypeEnum.IMAGE, params);
|
||||
}
|
||||
|
||||
@ApiOperation(value = "文件列表", notes = "文件列表接口")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "ids", value = "id列表,逗号分隔", paramType = "query")
|
||||
})
|
||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
||||
@GetMapping("listfilebyids")
|
||||
public List<FileDTO> listFileByFileId(@RequestParam("ids") String ids) {
|
||||
List<String> idList = Arrays.asList(ids.split(","));
|
||||
return fileService.listFileByFileId(idList);
|
||||
}
|
||||
|
||||
/**
|
||||
* 上传文件
|
||||
*
|
||||
|
Loading…
Reference in New Issue
Block a user