|
@@ -47,6 +47,10 @@ public class CmVipCouponService extends CrudService<CmCouponVipDao, CmVipCoupon>
|
|
calendar.add(Calendar.MONTH,2);
|
|
calendar.add(Calendar.MONTH,2);
|
|
Date time = calendar.getTime();
|
|
Date time = calendar.getTime();
|
|
vipCoupon.setEndTime(simpleDateFormat.format(time));
|
|
vipCoupon.setEndTime(simpleDateFormat.format(time));
|
|
|
|
+ Date newParse = simpleDateFormat.parse("2023-02");
|
|
|
|
+ if (parse.before(newParse)) {
|
|
|
|
+ vipCoupon.setEndTime(vipCoupon.getUseTime());
|
|
|
|
+ }
|
|
} catch (ParseException e) {
|
|
} catch (ParseException e) {
|
|
e.printStackTrace();
|
|
e.printStackTrace();
|
|
}
|
|
}
|
|
@@ -76,6 +80,10 @@ public class CmVipCouponService extends CrudService<CmCouponVipDao, CmVipCoupon>
|
|
calendar.add(Calendar.MONTH,2);
|
|
calendar.add(Calendar.MONTH,2);
|
|
Date time = calendar.getTime();
|
|
Date time = calendar.getTime();
|
|
vipCoupon.setEndTime(simpleDateFormat.format(time));
|
|
vipCoupon.setEndTime(simpleDateFormat.format(time));
|
|
|
|
+ Date newParse = simpleDateFormat.parse("2023-02");
|
|
|
|
+ if (parse.before(newParse)) {
|
|
|
|
+ vipCoupon.setEndTime(vipCoupon.getUseTime());
|
|
|
|
+ }
|
|
} catch (ParseException e) {
|
|
} catch (ParseException e) {
|
|
e.printStackTrace();
|
|
e.printStackTrace();
|
|
}
|
|
}
|
|
@@ -108,6 +116,10 @@ public class CmVipCouponService extends CrudService<CmCouponVipDao, CmVipCoupon>
|
|
calendar.add(Calendar.MONTH,2);
|
|
calendar.add(Calendar.MONTH,2);
|
|
Date time = calendar.getTime();
|
|
Date time = calendar.getTime();
|
|
vipCoupon.setEndTime(simpleDateFormat.format(time));
|
|
vipCoupon.setEndTime(simpleDateFormat.format(time));
|
|
|
|
+ Date newParse = simpleDateFormat.parse("2023-02");
|
|
|
|
+ if (parse.before(newParse)) {
|
|
|
|
+ vipCoupon.setEndTime(vipCoupon.getUseTime());
|
|
|
|
+ }
|
|
} catch (ParseException e) {
|
|
} catch (ParseException e) {
|
|
e.printStackTrace();
|
|
e.printStackTrace();
|
|
}
|
|
}
|