fix: 按钮权限调整
This commit is contained in:
@@ -44,7 +44,7 @@ public class CommentController {
|
||||
|
||||
@PostMapping("/create")
|
||||
@Operation(summary = "创建评论")
|
||||
// @PreAuthorize("@ss.hasPermission('license:comment:create')")
|
||||
@PreAuthorize("@ss.hasPermission('license:project:comment')")
|
||||
public CommonResult<Long> createComment(@Valid @RequestBody CommentSaveReqVO createReqVO) {
|
||||
return success(commentService.createComment(createReqVO));
|
||||
}
|
||||
|
||||
@@ -173,7 +173,7 @@ public class CustomerController {
|
||||
@Parameter(name = "file", description = "Excel 文件", required = true),
|
||||
@Parameter(name = "updateSupport", description = "是否支持更新,默认为 false", example = "true")
|
||||
})
|
||||
@PreAuthorize("@ss.hasPermission('system:user:import')")
|
||||
@PreAuthorize("@ss.hasPermission('license:customer:export')")
|
||||
public CommonResult<ImportRespVO> importExcel(@RequestParam("file") MultipartFile file,
|
||||
@RequestParam(value = "updateSupport", required = false, defaultValue = "false") Boolean updateSupport) throws Exception {
|
||||
List<CustomerImportRespVO> list = ExcelUtils.read(file, CustomerImportRespVO.class);
|
||||
|
||||
@@ -56,7 +56,7 @@ public class LicenseController {
|
||||
|
||||
@PostMapping("/create")
|
||||
@Operation(summary = "创建License")
|
||||
@PreAuthorize("@ss.hasPermission('license:license:create')")
|
||||
@PreAuthorize("@ss.hasPermission('license:license:apply')")
|
||||
public CommonResult<Long> createLicense(@Valid @RequestBody LicenseSaveReqVO createReqVO) {
|
||||
return success(licenseService.createLicense(createReqVO, false));
|
||||
}
|
||||
@@ -79,7 +79,7 @@ public class LicenseController {
|
||||
|
||||
@PutMapping("/reapply")
|
||||
@Operation(summary = "重新申请License")
|
||||
@PreAuthorize("@ss.hasPermission('license:license:apply')")
|
||||
@PreAuthorize("@ss.hasPermission('license:license:reapply')")
|
||||
public CommonResult<Boolean> reapplyLicense(@Valid @RequestBody LicenseSaveReqVO updateReqVO) {
|
||||
licenseService.reapplyLicense(updateReqVO);
|
||||
return success(true);
|
||||
@@ -221,7 +221,7 @@ public class LicenseController {
|
||||
@Parameter(name = "file", description = "Excel 文件", required = true),
|
||||
@Parameter(name = "updateSupport", description = "是否支持更新,默认为 false", example = "true")
|
||||
})
|
||||
@PreAuthorize("@ss.hasPermission('system:user:import')")
|
||||
@PreAuthorize("@ss.hasPermission('license:license:import')")
|
||||
public CommonResult<ImportRespVO> importExcel(@RequestParam("file") MultipartFile file,
|
||||
@RequestParam(value = "updateSupport", required = false, defaultValue = "false") Boolean updateSupport) throws Exception {
|
||||
List<LicenseImportExcelVO> list = ExcelUtils.read(file, LicenseImportExcelVO.class);
|
||||
|
||||
@@ -157,7 +157,7 @@ public class ProjectController {
|
||||
@Parameter(name = "file", description = "Excel 文件", required = true),
|
||||
@Parameter(name = "updateSupport", description = "是否支持更新,默认为 false", example = "true")
|
||||
})
|
||||
@PreAuthorize("@ss.hasPermission('system:user:import')")
|
||||
@PreAuthorize("@ss.hasPermission('license:project:import')")
|
||||
public CommonResult<ImportRespVO> importExcel(@RequestParam("file") MultipartFile file,
|
||||
@RequestParam(value = "updateSupport", required = false, defaultValue = "false") Boolean updateSupport) throws Exception {
|
||||
List<ProjectImportRespVO> list = ExcelUtils.read(file, ProjectImportRespVO.class);
|
||||
|
||||
Reference in New Issue
Block a user