Przeglądaj źródła

统计接口返回值格式修改

wangmh 7 lat temu
rodzic
commit
3638adfaf8

+ 3 - 3
sso-server/src/main/java/com/uas/sso/controller/UserManagerController.java

@@ -430,7 +430,7 @@ public class UserManagerController extends BaseController {
      */
     @RequestMapping(value = "/count", method = RequestMethod.GET)
     public ModelMap getUserCount() {
-        return success(new ModelMap("count", userService.getCount()));
+        return new ModelMap("count", userService.getCount());
     }
 
     /**
@@ -444,7 +444,7 @@ public class UserManagerController extends BaseController {
         start.set(start.get(Calendar.YEAR), start.get(Calendar.MONTH), 1, 0, 0, 0);
         Calendar end = Calendar.getInstance();
         end.set(start.get(Calendar.YEAR), start.get(Calendar.MONTH) + 1, 1, 0, 0, 0);
-        return success(new ModelMap("count", userService.getCountByRegisterDate(start, end)));
+        return new ModelMap("count", userService.getCountByRegisterDate(start, end));
     }
 
     /**
@@ -458,6 +458,6 @@ public class UserManagerController extends BaseController {
         start.set(start.get(Calendar.YEAR), start.get(Calendar.MONTH) - 1, 1, 0, 0, 0);
         Calendar end = Calendar.getInstance();
         end.set(start.get(Calendar.YEAR), start.get(Calendar.MONTH) + 1, 1, 0, 0, 0);
-        return success(new ModelMap("count", userService.getCountByRegisterDate(start, end)));
+        return new ModelMap("count", userService.getCountByRegisterDate(start, end));
     }
 }

+ 3 - 3
sso-server/src/main/java/com/uas/sso/controller/UserspaceManagerController.java

@@ -403,7 +403,7 @@ public class UserspaceManagerController extends BaseController {
      */
     @RequestMapping(value = "/count", method = RequestMethod.GET)
     public ModelMap getEnterpriseCount() {
-        return success(new ModelMap("count", userspaceService.getCount()));
+        return new ModelMap("count", userspaceService.getCount());
     }
 
     /**
@@ -417,7 +417,7 @@ public class UserspaceManagerController extends BaseController {
         start.set(start.get(Calendar.YEAR), start.get(Calendar.MONTH), 1, 0, 0, 0);
         Calendar end = Calendar.getInstance();
         end.set(start.get(Calendar.YEAR), start.get(Calendar.MONTH) + 1, 1, 0, 0, 0);
-        return success(new ModelMap("count", userspaceService.getCountByRegisterDate(start, end)));
+        return new ModelMap("count", userspaceService.getCountByRegisterDate(start, end));
     }
 
     /**
@@ -431,7 +431,7 @@ public class UserspaceManagerController extends BaseController {
         start.set(start.get(Calendar.YEAR), start.get(Calendar.MONTH) - 1, 1, 0, 0, 0);
         Calendar end = Calendar.getInstance();
         end.set(start.get(Calendar.YEAR), start.get(Calendar.MONTH) + 1, 1, 0, 0, 0);
-        return success(new ModelMap("count", userspaceService.getCountByRegisterDate(start, end)));
+        return new ModelMap("count", userspaceService.getCountByRegisterDate(start, end));
     }
 
 }