| | |
| | | public CommonResult<List<Map<String,Object>>> available(){ return success(service.seals(true)); } |
| | | @PostMapping("/upload") @PreAuthorize("@ss.hasPermission('mes:pd-seal:manage')") |
| | | public CommonResult<Long> upload(@RequestParam String name,@RequestParam MultipartFile file) throws Exception { return success(service.upload(name,file,getLoginUserId())); } |
| | | @PutMapping("/update") @PreAuthorize("@ss.hasPermission('mes:pd-seal:manage')") |
| | | public CommonResult<Boolean> update(@RequestParam long id,@RequestParam String name,@RequestParam(required=false) MultipartFile file) throws Exception { service.update(id,name,file); return success(true); } |
| | | @DeleteMapping("/delete") @PreAuthorize("@ss.hasPermission('mes:pd-seal:manage')") |
| | | public CommonResult<Boolean> delete(@RequestParam long id){ service.delete(id); return success(true); } |
| | | @PutMapping("/enabled") @PreAuthorize("@ss.hasPermission('mes:pd-seal:manage')") |
| | | public CommonResult<Boolean> enabled(@RequestParam long id,@RequestParam boolean enabled){service.setEnabled(id,enabled);return success(true);} |
| | | public record ApplyReq(Long projectId, Long sealId, String reason) {} |