| | |
| | | @Autowired |
| | | private SysCommonService commonService; |
| | | |
| | | @ApiOperation(value = "上传头像") |
| | | @PostMapping("/uploadIcon") |
| | | public CommonResult<UploadObjectVO> uploadIcon(MultipartFile file){ |
| | | @ApiOperation(value = "上传图片/文件") |
| | | @PostMapping("/uploadFile") |
| | | public CommonResult<UploadObjectVO> uploadFile(MultipartFile file){ |
| | | return CommonResult.success(commonService.uploadFile(file)); |
| | | } |
| | | |
| | | |
| | | @ApiOperation(value = "删除图片") |
| | | @DeleteMapping("/removeFile") |
| | | public CommonResult removeFile(@RequestParam(required = true) String path){ |
| | | return CommonResult.success(commonService.removeFile(path)); |
| | | } |
| | | |
| | | |
| | | } |