| | |
| | | |
| | | import javax.annotation.Resource; |
| | | |
| | | import com.yeshi.fanli.exception.user.vip.UserVIPUpgradeException; |
| | | import org.springframework.stereotype.Component; |
| | | |
| | | import com.aliyun.openservices.ons.api.Action; |
| | |
| | | UserVIPPreInfo vipInfo = userVIPPreInfoService.getLatestProcessInfo(uid); |
| | | if (vipInfo == null) { |
| | | // 计算等级 |
| | | userVIPPreInfoService.upgradeVipByMyOrder(uid); |
| | | userVIPPreInfoService.upgradeVipByTeamNum(uid); |
| | | try { |
| | | userVIPPreInfoService.upgradeVipByMyOrder(uid); |
| | | } catch (UserVIPUpgradeException e) { |
| | | e.printStackTrace(); |
| | | } |
| | | try { |
| | | userVIPPreInfoService.upgradeVipByTeamNum(uid); |
| | | } catch (UserVIPUpgradeException e) { |
| | | e.printStackTrace(); |
| | | } |
| | | vipInfo = userVIPPreInfoService.getLatestProcessInfo(uid); |
| | | if (vipInfo == null) {// 没有生成高级及以上会员 |
| | | UserInfoExtra extra = userInfoExtraService.getUserInfoExtra(uid); |
| | |
| | | && vipInfo.getCreateTime().getTime() < TimeUtil |
| | | .convertToTimeTemp("2020-04-30 14:10:00", "yyyy-MM-dd HH:mm:ss")) { |
| | | // 计算等级 |
| | | userVIPPreInfoService.upgradeVipByMyOrder(uid); |
| | | userVIPPreInfoService.upgradeVipByTeamNum(uid); |
| | | try { |
| | | userVIPPreInfoService.upgradeVipByMyOrder(uid); |
| | | } catch (UserVIPUpgradeException e) { |
| | | e.printStackTrace(); |
| | | } |
| | | try { |
| | | userVIPPreInfoService.upgradeVipByTeamNum(uid); |
| | | } catch (UserVIPUpgradeException e) { |
| | | e.printStackTrace(); |
| | | } |
| | | } |
| | | } |
| | | } |