From 30e1905f0b5d29e973937658452e9fb1ff489b46 Mon Sep 17 00:00:00 2001 From: fuliqi <fuliqi@qq.com> Date: 星期四, 11 四月 2024 18:22:57 +0800 Subject: [PATCH] Merge remote-tracking branch 'origin/master' --- ycl-server/src/main/java/com/ycl/platform/controller/YwPeopleController.java | 14 +++++--------- 1 files changed, 5 insertions(+), 9 deletions(-) diff --git a/ycl-server/src/main/java/com/ycl/platform/controller/YwPeopleController.java b/ycl-server/src/main/java/com/ycl/platform/controller/YwPeopleController.java index 46900da..8d6617a 100644 --- a/ycl-server/src/main/java/com/ycl/platform/controller/YwPeopleController.java +++ b/ycl-server/src/main/java/com/ycl/platform/controller/YwPeopleController.java @@ -5,6 +5,8 @@ import org.springframework.security.access.prepost.PreAuthorize; import org.springframework.validation.annotation.Validated; import lombok.RequiredArgsConstructor; + +import java.util.Arrays; import java.util.List; import jakarta.validation.constraints.NotEmpty; import io.swagger.annotations.Api; @@ -42,16 +44,10 @@ return ywPeopleService.update(form); } - @DeleteMapping("/{id}") - @ApiOperation(value = "ID鍒犻櫎", notes = "ID鍒犻櫎") - public Result removeById(@PathVariable("id") String id) { - return ywPeopleService.removeById(id); - } - - @DeleteMapping("/batch") + @DeleteMapping("/{ids}") @ApiOperation(value = "鎵归噺鍒犻櫎", notes = "鎵归噺鍒犻櫎") - public Result remove(@RequestBody @NotEmpty(message = "璇烽�夋嫨鏁版嵁") List<String> ids) { - return ywPeopleService.remove(ids); + public Result remove(@PathVariable String ids) { + return ywPeopleService.remove(Arrays.asList(ids.split(","))); } // @PreAuthorize("@ss.hasPermi('unit:people:page')") -- Gitblit v1.8.0