diff --git a/src/main/java/com/xkrs/straw/service/impl/SysUserServiceImpl.java b/src/main/java/com/xkrs/straw/service/impl/SysUserServiceImpl.java index 14d0ce5..8105f4d 100644 --- a/src/main/java/com/xkrs/straw/service/impl/SysUserServiceImpl.java +++ b/src/main/java/com/xkrs/straw/service/impl/SysUserServiceImpl.java @@ -14,6 +14,7 @@ import com.xkrs.straw.model.entity.RelUserRoleEntity; import com.xkrs.straw.model.entity.SysRoleEntity; import com.xkrs.straw.model.entity.SysUserEntity; import com.xkrs.straw.service.SysUserService; +import com.xkrs.straw.utils.VipTimeRangeUtils; import org.apache.http.util.TextUtils; import org.springframework.context.i18n.LocaleContextHolder; import org.springframework.data.domain.Sort; @@ -149,9 +150,15 @@ public class SysUserServiceImpl implements SysUserService { sysUserEntity.setAccountType("县级"); } if (9 == countyCode.length()) {//街道账号7天后过期 - sysUserEntity.setOverTime(dateTimeToString(LocalDateTime.now().plusDays(7L))); + //生成新的VIP时间范围Json内容 + String newVipTimeRangeJson = VipTimeRangeUtils.obtainNewVipTimeRangeJson(null, LocalDateTime.now().plusDays(7L)); + //更新字段 + sysUserEntity.setVipTimeRangeJson(newVipTimeRangeJson); } else {//省市区县账号5天后过期 - sysUserEntity.setOverTime(dateTimeToString(LocalDateTime.now().plusDays(5L))); + //生成新的VIP时间范围Json内容 + String newVipTimeRangeJson = VipTimeRangeUtils.obtainNewVipTimeRangeJson(null, LocalDateTime.now().plusDays(5L)); + //更新字段 + sysUserEntity.setVipTimeRangeJson(newVipTimeRangeJson); } sysUserEntity.setAddTime(dateTimeToString(LocalDateTime.now())); sysUserEntity.setLoginNum(0);