Jelajahi Sumber

登录后返回的信息

Reiskuchen 5 tahun lalu
induk
melakukan
410452afd4

+ 9 - 9
fhKeeper/formulahousekeeper/management-platform/src/main/java/com/management/platform/controller/ReportController.java

@@ -25,12 +25,12 @@ public class ReportController {
 
     /**
      * 分页获取报告列表
-     * 分页页数 pageIndex
-     * 分页大小 pageSize
-     * 可传 报告人id id
-     * 可传 报告种类 type 0-日报 1-月报
-     * 可传 检索开始时间 startDate
-     * 可传 检索结束时间 endDate
+     * pageIndex 分页页数
+     * pageSize 分页大小
+     * id 报告人id 可传
+     * type 报告种类 0-日报 1-月报 可传
+     * startDate 可传 检索开始时间(尚未约定格式)
+     * endDate 可传 检索结束时间
      */
     @RequestMapping("/getReportList")
     public HttpRespMsg getReportList(@RequestParam Integer pageIndex, @RequestParam Integer pageSize,
@@ -40,8 +40,8 @@ public class ReportController {
 
     /**
      * 根据id编辑报告
-     * 报告id id
-     * 报告内容 content
+     * id 报告id
+     * content 报告内容
      */
     @RequestMapping("/editReport")
     public HttpRespMsg editReport(@RequestParam Integer id, @RequestParam String content) {
@@ -50,7 +50,7 @@ public class ReportController {
 
     /**
      * 根据id删除报告
-     * 报告id id
+     * id 报告id
      */
     @RequestMapping("/deleteReport")
     public HttpRespMsg deleteReport(@RequestParam Integer id) {

+ 4 - 2
fhKeeper/formulahousekeeper/management-platform/src/main/java/com/management/platform/service/impl/UserServiceImpl.java

@@ -47,8 +47,9 @@ public class UserServiceImpl extends ServiceImpl<UserMapper, User> implements Us
         } else if (MD5Util.getPassword(password).equals(userList.get(0).getPassword())) {
             //检测密码正确时
             Map<String, Object> resultMap = new HashMap<>();
+            resultMap.put("name", userList.get(0).getName());
             resultMap.put("portraitUrl", userList.get(0).getPortraitUrl());
-            //将头像的url返回回去
+            //将名字和头像的url返回回去
             httpRespMsg.data = resultMap;
         } else {
             httpRespMsg.setError("密码错误");
@@ -76,8 +77,9 @@ public class UserServiceImpl extends ServiceImpl<UserMapper, User> implements Us
         } else if (MD5Util.getPassword(password).equals(userList.get(0).getPassword())) {
             //检测密码正确时
             Map<String, Object> resultMap = new HashMap<>();
+            resultMap.put("name", userList.get(0).getName());
             resultMap.put("portraitUrl", userList.get(0).getPortraitUrl());
-            //将头像的url返回回去
+            //将名字和头像的url返回回去
             httpRespMsg.data = resultMap;
         } else {
             httpRespMsg.setError("密码错误");