From c18749c2f61a87b7ec17e9c859bbcbebc99b708f Mon Sep 17 00:00:00 2001 From: Administrator <Administrator@Admin> Date: 星期四, 29 十一月 2018 17:19:20 +0800 Subject: [PATCH] 安卓 队员返回一个接口 --- fanli/src/main/java/com/yeshi/fanli/controller/client/UserInfoController.java | 37 +++++++++++++++++++++++++++++++++++++ 1 files changed, 37 insertions(+), 0 deletions(-) diff --git a/fanli/src/main/java/com/yeshi/fanli/controller/client/UserInfoController.java b/fanli/src/main/java/com/yeshi/fanli/controller/client/UserInfoController.java index a69c22b..b6afc6e 100644 --- a/fanli/src/main/java/com/yeshi/fanli/controller/client/UserInfoController.java +++ b/fanli/src/main/java/com/yeshi/fanli/controller/client/UserInfoController.java @@ -1609,6 +1609,43 @@ resultData = threeSaleSerivce.getMySecondTeam((page - 1) * pageSize, pageSize, uid); } + // 瀹夊崜绯荤粺杩斿洖鎵�鏈夋暟鎹� + String platform = acceptData.getPlatform(); + if ("android".equalsIgnoreCase(platform)) { + long firstTeam = threeSaleSerivce.countFirstTeam(uid, 1); + long firstTeamTotal = threeSaleSerivce.countFirstTeam(uid, null); + + long secondTeam = threeSaleSerivce.countSecondTeam(uid, 1); + long secondTeamTotal = threeSaleSerivce.countSecondTeam(uid, null); + + JSONObject bossData = new JSONObject(); + ThreeSale threeSale = threeSaleSerivce.getMyBoss(uid); + if (threeSale != null) { + + UserInfo boss = threeSale.getBoss(); + if (boss != null) { + bossData.put("nickName", boss.getNickName()); + bossData.put("portrait", boss.getPortrait()); + } + + SimpleDateFormat sdf = new SimpleDateFormat("yyyy.MM.dd"); + Long createTime = threeSale.getCreateTime(); + Date inviteTime = new Date(createTime); + bossData.put("inviteTime", "閭�璇锋椂闂�: " + sdf.format(inviteTime)); + } + + String helpLink = configService.get("team_help_url"); + if (helpLink == null) { + helpLink = ""; + } + resultData.put("helpLink", helpLink); + resultData.put("firstTeam", firstTeam); + resultData.put("firstTeamTotal", firstTeamTotal); + resultData.put("secondTeam", secondTeam); + resultData.put("secondTeamTotal", secondTeamTotal); + resultData.put("boss", bossData); + } + out.print(JsonUtil.loadTrueResult(resultData)); } -- Gitblit v1.8.0