From e5bf216882f1f523bf32496a02ee2d7b6cb6a3cd Mon Sep 17 00:00:00 2001 From: liuxm <liuxm@fescotech.com> Date: 星期二, 23 四月 2024 18:09:43 +0800 Subject: [PATCH] 日志管理相关 --- pms-parent/pms-web-base/src/main/java/com/dy/pmsBase/user/UserCtrl.java | 10 +++++++++- 1 files changed, 9 insertions(+), 1 deletions(-) diff --git a/pms-parent/pms-web-base/src/main/java/com/dy/pmsBase/user/UserCtrl.java b/pms-parent/pms-web-base/src/main/java/com/dy/pmsBase/user/UserCtrl.java index 29e4c59..603ad0d 100644 --- a/pms-parent/pms-web-base/src/main/java/com/dy/pmsBase/user/UserCtrl.java +++ b/pms-parent/pms-web-base/src/main/java/com/dy/pmsBase/user/UserCtrl.java @@ -6,6 +6,7 @@ import com.dy.common.webUtil.BaseResponse; import com.dy.common.webUtil.BaseResponseUtils; import com.dy.common.webUtil.QueryResultVo; +import com.dy.pmsGlobal.aop.OperationDescription; import com.dy.pmsGlobal.pojoBa.BaUser; import com.dy.pmsGlobal.util.Constant; import com.mysql.cj.util.StringUtils; @@ -44,6 +45,7 @@ * @return 榛樿瀵嗙爜 */ @GetMapping(path = "defaultPassword") + @OperationDescription("瀹㈡埛绔姹傚緱鍒伴粯璁ゅ瘑鐮�") public BaseResponse<String> defaultPassword(){ if(defaultTrueRandomFalsePassword){ return BaseResponseUtils.buildSuccess(defaultPassword) ; @@ -60,6 +62,7 @@ @PostMapping(path = "some", consumes = MediaType.APPLICATION_JSON_VALUE) //@SsoAop() //鍙湁鐧诲綍楠岃瘉锛屾病鏈夋潈闄愰獙璇� @SsoPowerAop(power = "10100010") //鐧诲綍涓庢潈闄愬悓鏃堕獙璇� + @OperationDescription("鍒嗛〉鏌ヨ鐢ㄦ埛") public BaseResponse<QueryResultVo<List<BaUser>>> some(@RequestBody QueryVo vo) { try { QueryResultVo<List<BaUser>> res = this.sv.selectSome(vo); @@ -78,6 +81,7 @@ @GetMapping(path = "one") //@SsoAop() //鍙湁鐧诲綍楠岃瘉锛屾病鏈夋潈闄愰獙璇� @SsoPowerAop(power = "10100010") //鐧诲綍涓庢潈闄愬悓鏃堕獙璇� + @OperationDescription("鏌ヨ鍗曚釜鐢ㄦ埛") public BaseResponse<BaUser> one(String id) { try { return BaseResponseUtils.buildSuccess(this.sv.selectById(Long.parseLong(id))); @@ -96,6 +100,7 @@ @PostMapping(path = "save", consumes = MediaType.APPLICATION_JSON_VALUE) //@SsoAop() //鍙湁鐧诲綍楠岃瘉锛屾病鏈夋潈闄愰獙璇� @SsoPowerAop(power = "10100011") //鐧诲綍涓庢潈闄愬悓鏃堕獙璇� + @OperationDescription("淇濆瓨鐢ㄦ埛淇℃伅") public BaseResponse<Boolean> save(@RequestBody @Valid BaUser po, BindingResult bindingResult) { if (bindingResult != null && bindingResult.hasErrors()) { return BaseResponseUtils.buildFail(Objects.requireNonNull(bindingResult.getFieldError()).getDefaultMessage()); @@ -136,6 +141,7 @@ @PostMapping(path = "update", consumes = MediaType.APPLICATION_JSON_VALUE) //@SsoAop() //鍙湁鐧诲綍楠岃瘉锛屾病鏈夋潈闄愰獙璇� @SsoPowerAop(power = "10100011") //鐧诲綍涓庢潈闄愬悓鏃堕獙璇� + @OperationDescription("鏇存柊鐢ㄦ埛淇℃伅") public BaseResponse<Boolean> update(@RequestBody @Validated BaUser po, BindingResult bindingResult) { int count; try { @@ -168,6 +174,7 @@ //@GetMapping(path = "changePassword", consumes = MediaType.TEXT_PLAIN_VALUE) @GetMapping(path = "changePassword") @SsoAop() + @OperationDescription("淇敼瀵嗙爜") public BaseResponse<Boolean> changePassword(String id, String oldPassword, String newPassword) { int count; try { @@ -220,6 +227,7 @@ @PostMapping(path = "resetPassword", consumes = MediaType.APPLICATION_JSON_VALUE) //@SsoAop() //鍙湁鐧诲綍楠岃瘉锛屾病鏈夋潈闄愰獙璇� @SsoPowerAop(power = "10100011") //鐧诲綍涓庢潈闄愬悓鏃堕獙璇� + @OperationDescription("閲嶇疆瀵嗙爜") public BaseResponse<Boolean> resetPassword(@RequestBody @Validated ResetPasswordVo vo, BindingResult bindingResult) { int count; try { @@ -241,7 +249,7 @@ if (count <= 0) { return BaseResponseUtils.buildFail("鏁版嵁搴撳瓨鍌ㄥけ璐�"); } else { - return BaseResponseUtils.buildSuccess("淇敼瀵嗙爜鎴愬姛"); + return BaseResponseUtils.buildSuccess("閲嶇疆瀵嗙爜鎴愬姛"); } } -- Gitblit v1.8.0