Skip to content

Commit

Permalink
系统接口加了权限注解@RequiresPermissions未授权会提示无权限,暂时注释掉
Browse files Browse the repository at this point in the history
(无奈的修改,因为太多人问没权限的问题,请注重安全的项目,自行打开注解)
  • Loading branch information
zhangdaiscott committed Mar 7, 2023
1 parent 3c2038a commit 42eedcd
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ public Result<IPage<OssFile>> queryPageList(OssFile file,

@ResponseBody
@PostMapping("/upload")
@RequiresRoles("admin")
//@RequiresRoles("admin")
//@RequiresPermissions("system:ossFile:upload")
public Result upload(@RequestParam("file") MultipartFile multipartFile) {
Result result = new Result();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ public Result<?> queryPageList(QuartzJob quartzJob, @RequestParam(name = "pageNo
* @param quartzJob
* @return
*/
@RequiresRoles("admin")
//@RequiresRoles("admin")
//@RequiresPermissions("system:quartzJob:add")
@RequestMapping(value = "/add", method = RequestMethod.POST)
public Result<?> add(@RequestBody QuartzJob quartzJob) {
Expand All @@ -93,7 +93,7 @@ public Result<?> add(@RequestBody QuartzJob quartzJob) {
* @param quartzJob
* @return
*/
@RequiresRoles("admin")
//@RequiresRoles("admin")
//@RequiresPermissions("system:quartzJob:edit")
@RequestMapping(value = "/edit", method ={RequestMethod.PUT, RequestMethod.POST})
public Result<?> eidt(@RequestBody QuartzJob quartzJob) {
Expand All @@ -112,7 +112,7 @@ public Result<?> eidt(@RequestBody QuartzJob quartzJob) {
* @param id
* @return
*/
@RequiresRoles("admin")
//@RequiresRoles("admin")
//@RequiresPermissions("system:quartzJob:delete")
@RequestMapping(value = "/delete", method = RequestMethod.DELETE)
public Result<?> delete(@RequestParam(name = "id", required = true) String id) {
Expand All @@ -131,7 +131,7 @@ public Result<?> delete(@RequestParam(name = "id", required = true) String id) {
* @param ids
* @return
*/
@RequiresRoles("admin")
//@RequiresRoles("admin")
//@RequiresPermissions("system:quartzJob:deleteBatch")
@RequestMapping(value = "/deleteBatch", method = RequestMethod.DELETE)
public Result<?> deleteBatch(@RequestParam(name = "ids", required = true) String ids) {
Expand All @@ -151,7 +151,7 @@ public Result<?> deleteBatch(@RequestParam(name = "ids", required = true) String
* @param id
* @return
*/
@RequiresRoles("admin")
//@RequiresRoles("admin")
//@RequiresPermissions("system:quartzJob:pause")
@GetMapping(value = "/pause")
@ApiOperation(value = "停止定时任务")
Expand All @@ -170,7 +170,7 @@ public Result<Object> pauseJob(@RequestParam(name = "id") String id) {
* @param id
* @return
*/
@RequiresRoles("admin")
//@RequiresRoles("admin")
//@RequiresPermissions("system:quartzJob:resume")
@GetMapping(value = "/resume")
@ApiOperation(value = "启动定时任务")
Expand Down Expand Up @@ -271,7 +271,7 @@ public Result<?> importExcel(HttpServletRequest request, HttpServletResponse res
* @param id
* @return
*/
@RequiresRoles("admin")
//@RequiresRoles("admin")
//@RequiresPermissions("system:quartzJob:execute")
@GetMapping("/execute")
public Result<?> execute(@RequestParam(name = "id", required = true) String id) {
Expand Down

0 comments on commit 42eedcd

Please sign in to comment.