ソースを参照

修改取人脸信息

DESKTOP-USV654P\pc 2 年 前
コミット
fc79c8e4e3

+ 1 - 1
src/main/java/com/xjrsoft/common/sms/SmsCtcc.java

@@ -70,7 +70,7 @@ public class SmsCtcc {
         String content = String.format("验证码为%s,有效时间为%d分钟,请勿将验证码泄露给其他人。", code, 2);
 //        JSONObject result = send(mobile, content);
 //        if (result.getInt("status") == 1) {
-//            redisUtil.set(key, code, 120L);
+            redisUtil.set(key, code, 120L);
 //        }
 //        return result;
         return null;

+ 1 - 3
src/main/java/com/xjrsoft/module/personnel/controller/FaceManagementController.java

@@ -81,9 +81,7 @@ public class FaceManagementController {
     @ApiOperation(value = "根据当前用户查询人脸信息")
     @SaCheckPermission("facemanager:detail")
     public R detail() {
-        SaSession tokenSession = StpUtil.getTokenSession();
-        User user = tokenSession.get(GlobalConstant.LOGIN_USER_INFO_KEY, new User());
-        FaceManagement faceManagement = faceManagementService.getOneDeep(Wrappers.lambdaQuery(FaceManagement.class).eq(FaceManagement::getUserId, user.getId()));
+        FaceManagement faceManagement = faceManagementService.getOneDeep(Wrappers.lambdaQuery(FaceManagement.class).eq(FaceManagement::getUserId, StpUtil.getLoginIdAsLong()));
         if (faceManagement == null) {
             return R.error("找不到此数据!");
         }