| | |
| | | } |
| | | |
| | | @PostMapping |
| | | @PreAuthorize("hasAuthority('filesUpload:add')") |
| | | public void addFilesUpload(@NotNull(message = "{required}") Long folderid, MultipartFile file) throws FebsException { |
| | | try { |
| | | this.filesUploadService.createFilesUpload(folderid, file); |
| | |
| | | } catch (Exception e) { |
| | | String message = "修改FilesUpload失败"; |
| | | log.error(message, e); |
| | | throw new FebsException(message); |
| | | throw new FebsException(e.getMessage()); |
| | | } |
| | | } |
| | | |
| | |
| | | try { |
| | | this.filesUploadService.mvFiles(fileids,folderid); |
| | | } catch (Exception e) { |
| | | String message = "修改FilesUpload失败"; |
| | | String message = "移动文件失败"; |
| | | log.error(message, e); |
| | | throw new FebsException(message); |
| | | } |
| | | } |
| | | |
| | | @GetMapping("image/{filesid}") |
| | | public void getImage(@PathVariable String filesid, HttpServletResponse response) throws FebsException { |
| | | try { |
| | | this.filesUploadService.getImage(filesid,response); |
| | | } catch (Exception e) { |
| | | String message = "获取员工图片异常"; |
| | | log.error(message, e); |
| | | throw new FebsException(message); |
| | | } |