zhuangchong commented on a change in pull request #5882:
URL: https://github.com/apache/dolphinscheduler/pull/5882#discussion_r677113459



##########
File path: 
dolphinscheduler-api/src/main/java/org/apache/dolphinscheduler/api/controller/AccessTokenController.java
##########
@@ -128,13 +128,13 @@ public Result queryAccessTokenList(@ApiIgnore 
@RequestAttribute(value = Constant
                                        @RequestParam(value = "searchVal", 
required = false) String searchVal,
                                        @RequestParam("pageSize") Integer 
pageSize) {
 
-        Map<String, Object> result = checkPageParams(pageNo, pageSize);
-        if (result.get(Constants.STATUS) != Status.SUCCESS) {
-            return returnDataListPaging(result);
+        Result result = checkPageParams(pageNo, pageSize);
+        if (!result.checkResult()) {
+            return error(result.getCode(),result.getMsg());

Review comment:
       Return the result directly

##########
File path: 
dolphinscheduler-api/src/main/java/org/apache/dolphinscheduler/api/service/AccessTokenService.java
##########
@@ -35,7 +36,7 @@
      * @param pageSize page size
      * @return token list for page number and page size
      */
-    Map<String, Object> queryAccessTokenList(User loginUser, String searchVal, 
Integer pageNo, Integer pageSize);
+    PageInfo queryAccessTokenList(User loginUser, String searchVal, Integer 
pageNo, Integer pageSize);

Review comment:
       Other interfaces return Result type, please keep the same




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to