| | |
| | | import org.yeshi.utils.JsonUtil;
|
| | | import org.yeshi.utils.encrypt.DESUtil;
|
| | |
|
| | | import com.yeshi.fanli.dto.user.UserInviteLevelEnum;
|
| | | import com.yeshi.fanli.entity.accept.AcceptData;
|
| | | import com.yeshi.fanli.entity.bus.homemodule.FloatAD;
|
| | | import com.yeshi.fanli.entity.bus.homemodule.FloatAD.FloatADTypeEnum;
|
| | |
| | | import com.yeshi.fanli.entity.bus.msg.MsgDeviceReadState;
|
| | | import com.yeshi.fanli.entity.bus.user.UserActiveLog;
|
| | | import com.yeshi.fanli.entity.bus.user.UserInfo;
|
| | | import com.yeshi.fanli.entity.bus.user.vip.UserVIPInfo;
|
| | | import com.yeshi.fanli.entity.bus.user.vip.UserVIPPreInfo;
|
| | | import com.yeshi.fanli.entity.common.JumpDetailV2;
|
| | | import com.yeshi.fanli.entity.config.AppHomeFloatImg;
|
| | | import com.yeshi.fanli.entity.system.ConfigKeyEnum;
|
| | |
| | | import com.yeshi.fanli.service.inter.user.UserInfoExtraService;
|
| | | import com.yeshi.fanli.service.inter.user.UserInfoService;
|
| | | import com.yeshi.fanli.service.inter.user.notify.UserActivedRecordService;
|
| | | import com.yeshi.fanli.service.inter.user.vip.UserVIPInfoService;
|
| | | import com.yeshi.fanli.service.inter.user.vip.UserVIPPreInfoService;
|
| | | import com.yeshi.fanli.util.Constant;
|
| | | import com.yeshi.fanli.util.StringUtil;
|
| | | import com.yeshi.fanli.util.ThreadUtil;
|
| | |
| | |
|
| | | @Resource
|
| | | private UserInfoService userInfoService;
|
| | | |
| | | |
| | | @Resource
|
| | | private UserVIPInfoService userVIPInfoService;
|
| | | |
| | | @Resource
|
| | | private UserVIPPreInfoService userVIPPreInfoService;
|
| | |
|
| | | /**
|
| | | * s 首页配置信息
|
| | |
| | |
|
| | | String tearcherLink = configService.getByVersion(ConfigKeyEnum.tearcherLink.getKey(),
|
| | | acceptData.getPlatform(), Integer.parseInt(acceptData.getVersion()));
|
| | | if (userActivedRecordService.canNotifyAddTearcher(uid)) {
|
| | | if (userActivedRecordService.canNotifyAddTearcher(uid) && !StringUtil.isNullOrEmpty(tearcherLink)) {
|
| | | UserInfo userInfo = userInfoService.selectAvailableByPrimaryKey(uid);
|
| | | if (userInfo != null) {
|
| | | JumpDetailV2 jumpDetail = jumpDetailV2Service.getByTypeCache("web",
|
| | |
| | |
|
| | | data.put("tearcherLink", tearcherLink);
|
| | | }
|
| | |
|
| | | }
|
| | | |
| | | if (VersionUtil.greaterThan_2_1(acceptData.getPlatform(), acceptData.getVersion())) {
|
| | | // TODO 验证是否是导师
|
| | | |
| | | JSONObject inner = new JSONObject();
|
| | | inner.put("link", "https://www.baidu.com/");
|
| | | inner.put("ion", "http://img.flqapp.com/resource/vip/icon_vip.png");
|
| | | inner.put("title", "免费升级 享会员权益");
|
| | | inner.put("btnName", "升级会员");
|
| | | |
| | | if (uid != null) {
|
| | | // 是否导师 TODO
|
| | | |
| | | if (userVIPInfoService.isVIP(uid)) {
|
| | | inner.put("link", "https://www.baidu.com/");
|
| | | inner.put("ion", "http://img.flqapp.com/resource/vip/icon_tearcher.png");
|
| | | inner.put("title", "拿五险与津贴 享导师权益");
|
| | | inner.put("btnName", "升级会员");
|
| | | } else {
|
| | | UserVIPPreInfo userVIPPreInfo = userVIPPreInfoService.getLatestProcessInfo(uid);
|
| | | if (userVIPPreInfo != null) {
|
| | | if (userVIPPreInfo.getProcess() == UserVIPPreInfo.PROCESS_1) {
|
| | | inner.put("btnName", "升级高级会员");
|
| | | } else if (userVIPPreInfo.getProcess() == UserVIPPreInfo.PROCESS_2) {
|
| | | inner.put("btnName", "升级超级会员");
|
| | | }
|
| | | }
|
| | | }
|
| | | }
|
| | | data.put("vip", inner);
|
| | | }
|
| | | out.print(JsonUtil.loadTrueResult(data));
|
| | | } catch (Exception e) {
|
| | |
| | | }
|
| | |
|
| | | }
|
| | | |
| | | |
| | | |
| | |
|
| | | /**
|
| | | * 订单解析配置
|