From 266ef8384174dd23f91a0a3723a25b9a6d7fd88e Mon Sep 17 00:00:00 2001 From: gongbiao Date: Thu, 8 Aug 2019 13:59:37 +0800 Subject: [PATCH] =?UTF-8?q?[=E8=B4=A6=E5=8D=95][=E4=BF=AE=E6=94=B9][?= =?UTF-8?q?=E5=AF=BC=E5=85=A5=E4=B9=8B=E5=90=8E=E7=9A=84=E8=B4=A6=E5=8D=95?= =?UTF-8?q?=E7=8A=B6=E6=80=81]?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../service/impl/WxBillAllServiceImpl.java | 36 +++++++++---------- 1 file changed, 18 insertions(+), 18 deletions(-) diff --git a/mallinkService/src/main/java/com/iformall/service/impl/WxBillAllServiceImpl.java b/mallinkService/src/main/java/com/iformall/service/impl/WxBillAllServiceImpl.java index 00fc9ef0b..03afa4958 100644 --- a/mallinkService/src/main/java/com/iformall/service/impl/WxBillAllServiceImpl.java +++ b/mallinkService/src/main/java/com/iformall/service/impl/WxBillAllServiceImpl.java @@ -1233,26 +1233,26 @@ public class WxBillAllServiceImpl implements WxBillAllService { if (expiredDay > timePeriod) { rent.setExpiredDay((long) expiredDay); } - } else { - Date now = new Date(); - int day = DateUtils.daysBetween(startDate, now); - int timePeriod = 0; - if (day < timePeriod) { - rent.setStatus(EnumBillRentStatus.NOT_PAID.getCode()); - long expiredDay = Long.valueOf(Math.abs(day)); - rent.setExpiredDay(expiredDay); + return rent; + } + Date now = new Date(); + int day = DateUtils.daysBetween(startDate, now); + int timePeriod = 0; + if (day > timePeriod) { + rent.setStatus(EnumBillRentStatus.NOT_PAID.getCode()); + rent.setExpiredDay((long) day); + return rent; + } + if (flag) { + timePeriod = 30; + long expiredDay = Long.valueOf(Math.abs(day)); + if (expiredDay > timePeriod) { + rent.setStatus(EnumBillRentStatus.NOT_EXPIRED.getCode()); } else { - if (flag) { - timePeriod = 30; - if (day > timePeriod) { - rent.setStatus(EnumBillRentStatus.NOT_EXPIRED.getCode()); - } else { - rent.setStatus(EnumBillRentStatus.WAIT_PAY.getCode()); - } - } else { - rent.setStatus(EnumBillRentStatus.WAIT_PAY.getCode()); - } + rent.setStatus(EnumBillRentStatus.WAIT_PAY.getCode()); } + } else { + rent.setStatus(EnumBillRentStatus.WAIT_PAY.getCode()); } return rent; }