admin
2019-05-08 c5410b7f48a774e4ecd50019b46bc9173f2483ae
fanli/src/main/java/com/yeshi/fanli/controller/client/UserInfoController.java
@@ -518,7 +518,6 @@
            }
         }
      }
      GsonBuilder gsonBuilder = new GsonBuilder().excludeFieldsWithoutExposeAnnotation();
@@ -577,12 +576,12 @@
      int welfareCenterNews = 0;
      String invitCode = null;
      UserInfoExtra userInfoExtra = userInfoExtraService.getUserInfoExtra(user.getId());
      if (userInfoExtra != null  ) {
         if(userInfoExtra.getCouponNews() != null) {
      if (userInfoExtra != null) {
         if (userInfoExtra.getCouponNews() != null) {
            welfareCenterNews = userInfoExtra.getCouponNews();
         }
         if(userInfoExtra.getInviteCode() != null && userInfoExtra.getInviteCode().trim().length() > 0) {
         if (userInfoExtra.getInviteCode() != null && userInfoExtra.getInviteCode().trim().length() > 0) {
            invitCode = userInfoExtra.getInviteCode();
         }
      }
@@ -1052,7 +1051,6 @@
      return;
   }
   /**
    * 新版提现
    * 
@@ -1158,13 +1156,17 @@
               } catch (UnsupportedEncodingException e) {
                  e.printStackTrace();
               }
               AdminUser adminUser = adminUserService.selectByPrimaryKey(4L);
               long[] targetUids = new long[] { 3L, 4L };
               Config config = configService.getConfig("extract_code_email_from");
               String[] sts = config.getValue().split(",");
               String account = sts[0];
               String pwd = sts[1];
               String msg = "提现审核链接:" + url;
               boolean isS = MailSenderUtil.sendEmail(adminUser.getEmail(), account, pwd, "有新的提现审核", msg);
               for (long adminId : targetUids) {
                  AdminUser adminUser = adminUserService.selectByPrimaryKey(adminId);
                  String msg = "提现审核链接:" + url;
                  boolean isS = MailSenderUtil.sendEmail(adminUser.getEmail(), account, pwd, "有新的提现审核", msg);
               }
            }
         });
         return;
@@ -1174,6 +1176,10 @@
         out.print(JsonUtil.loadFalseResult("已超过当日提现金额"));
      } else if (etype == 3) {
         out.print(JsonUtil.loadFalseResult("提现金额大于我的红包"));
      } else if (etype == 111) {
         out.print(JsonUtil.loadFalseResult("更换了手机号后7天内不允许提现"));
      } else if (etype == 110) {
         out.print(JsonUtil.loadFalseResult(Constant.znxConfig.getExtractWrongMsg()));
      }
   }
@@ -1650,7 +1656,6 @@
   }
   /**
    * 用户队员列表查询 1.5.3查询有效队员
    * 
@@ -1722,9 +1727,7 @@
         e.printStackTrace();
      }
   }
   /**
    * 用户队员统计 1.4.1
    * 
@@ -1996,7 +1999,7 @@
         e.printStackTrace();
      }
   }
   /**
    * 获取用户信息
    * 
@@ -2014,14 +2017,14 @@
            out.print(JsonUtil.loadFalseResult("系统不存在"));
            return;
         }
         if (uid == null) {
            out.print(JsonUtil.loadFalseResult("请求参数为空"));
            return;
         }
         UserInfo userInfo = userInfoService.getUserInfo(uid);
         // 添加用户活跃记录
         UserActiveLog userActiveLog = new UserActiveLog();
         userActiveLog.setChannel(acceptData.getChannel());
@@ -2031,23 +2034,14 @@
         userActiveLog.setOsVersion(acceptData.getOsVersion());
         userActiveLog.setDeviceType(acceptData.getDeviceType());
         userActiveLogService.addUserActiveLog(userActiveLog);
         // 处理用户信息
         outUserInfoHandle(userInfo);
         GsonBuilder gsonBuilder = new GsonBuilder().excludeFieldsWithoutExposeAnnotation();
         JSONObject data = new JSONObject();
         data.put("user", JsonUtil.getConvertBigDecimalToStringBuilder(gsonBuilder).create().toJson(userInfo));
//         if ("ios".equalsIgnoreCase(acceptData.getPlatform())
//               && configService.iosOnLining(Integer.parseInt(acceptData.getVersion()))) {
//            data.put("inviteList", String.format("http://%s/%s/client/share/friends_new_online.html",
//                  Constant.systemCommonConfig.getProjectHost(), Constant.systemCommonConfig.getProjectName()));
//         } else {
//            data.put("inviteList", configService.get("team_list"));
//         }
//
         // 界面状态
         UserSettingsVO mySettings = null;
         try {
@@ -2074,19 +2068,18 @@
         }
         data.put("moduleState", mySettings);
         int welfareCenterNews = 0;
         String invitCode = null;
         UserInfoExtra userInfoExtra = userInfoExtraService.getUserInfoExtra(uid);
         if (userInfoExtra != null  ) {
            if(userInfoExtra.getCouponNews() != null) {
         if (userInfoExtra != null) {
            if (userInfoExtra.getCouponNews() != null) {
               welfareCenterNews = userInfoExtra.getCouponNews();
            }
            if(userInfoExtra.getInviteCode() != null && userInfoExtra.getInviteCode().trim().length() > 0) {
            if (userInfoExtra.getInviteCode() != null && userInfoExtra.getInviteCode().trim().length() > 0) {
               invitCode = userInfoExtra.getInviteCode();
            }
            if (userInfoExtra.getUserRank() != null) {
               String picture = userInfoExtra.getUserRank().getPicture();
               String icon = userInfoExtra.getUserRank().getIcon();
@@ -2097,7 +2090,7 @@
               userInfo.setRankIcon(null);
            }
         }
         data.put("invitCode", invitCode); // 邀请码
         data.put("welfareCenterNews", welfareCenterNews);// 福利中心消息
         out.print(JsonUtil.loadTrueResult(data));
@@ -2120,7 +2113,7 @@
               }
            }
         });
      } catch (UserInfoException e) {
         out.print(JsonUtil.loadFalseResult(e.getCode(), e.getMsg()));
      } catch (Exception e) {
@@ -2128,9 +2121,9 @@
         e.printStackTrace();
      }
   }
   private void outUserInfoHandle(UserInfo user) {
      // 红包处理
      user.setTotalHongBao(new BigDecimal(0));
      user.setNoOpenHongBao(new BigDecimal(0));
@@ -2145,7 +2138,7 @@
            user.setPhone(phone);
         }
      }
      UserInfoExtraVO userInfoExtra = userInfoExtraService.getInfoExtraVOByUid(user.getId());
      if (userInfoExtra != null && userInfoExtra.getUserRank() != null) {
         String picture = userInfoExtra.getUserRank().getPicture();
@@ -2154,5 +2147,5 @@
         user.setRankIcon(icon);
      }
   }
}