Browse Source

Merge remote-tracking branch 'origin/test' into test

zouxuan 4 years ago
parent
commit
05f8f9caf7

+ 3 - 2
mec-biz/src/main/java/com/ym/mec/biz/service/impl/EduPracticeGroupServiceImpl.java

@@ -192,7 +192,7 @@ public class EduPracticeGroupServiceImpl implements EduPracticeGroupService{
 
         Date now=new Date();
 
-        int studentExitChargePractices = practiceGroupDao.checkStudentExitChargePractice(practiceGroupBuyParams.getStudentId(), "2021-03-10 00:00:00");
+        int studentExitChargePractices = practiceGroupDao.checkStudentExitChargePractice(practiceGroupBuyParams.getStudentId(), "2021-03-09 00:00:00");
 
         LocalDate courseStartDay=LocalDate.now();
         LocalDate tempCourseLocalDate=LocalDate.parse("2020-03-01", DateUtil.dateFormatter);
@@ -287,7 +287,8 @@ public class EduPracticeGroupServiceImpl implements EduPracticeGroupService{
         BigDecimal oneMonthPrice;
         BigDecimal oneMonthOriginalPrice=practiceGroupBuyParams.getDrillTimesOnWeek()==1?practiceGroupSellPrice.getOnceOriginalPrice():practiceGroupSellPrice.getTwiceOriginalPrice();
         if(practiceBuyActivityExpireDate.after(now)&&Objects.nonNull(sysUser.getOrganId())&&sysUser.getOrganId()==14&&studentExitChargePractices<=0){
-            oneMonthPrice=practiceGroupBuyParams.getDrillTimesOnWeek()==1?practiceGroupSellPrice.getOnceActivityPrice():practiceGroupSellPrice.getTwiceActivityPrice();
+//            oneMonthPrice=practiceGroupBuyParams.getDrillTimesOnWeek()==1?practiceGroupSellPrice.getOnceActivityPrice():practiceGroupSellPrice.getTwiceActivityPrice();
+            oneMonthPrice=practiceGroupBuyParams.getDrillTimesOnWeek()==1?practiceGroupSellPrice.getOnceOriginalPrice():practiceGroupSellPrice.getTwiceOriginalPrice();
             if(!now.before(practicePromotionActivityStartDate)&&practiceGroupBuyParams.getBuyMonths()>=3&&studentExitChargePractices>0){
                 oneMonthPrice=practiceGroupBuyParams.getDrillTimesOnWeek()==1?practiceGroupSellPrice.getOnceQuartActivityPrice():practiceGroupSellPrice.getTwiceQuartActivityPrice();
             }else if(!now.before(practicePromotionActivityStartDate)&&studentExitChargePractices<=0){

+ 3 - 2
mec-biz/src/main/java/com/ym/mec/biz/service/impl/PracticeGroupServiceImpl.java

@@ -2786,7 +2786,7 @@ public class PracticeGroupServiceImpl extends BaseServiceImpl<Long, PracticeGrou
 
         Date now = new Date();
 
-        int studentExitChargePractices = practiceGroupDao.checkStudentExitChargePractice(practiceGroupBuyParams.getStudentId(),"2021-03-10 00:00:00");
+        int studentExitChargePractices = practiceGroupDao.checkStudentExitChargePractice(practiceGroupBuyParams.getStudentId(),"2021-03-09 00:00:00");
 
         LocalDate courseStartDay = LocalDate.now();
         LocalDate tempCourseLocalDate = LocalDate.parse("2020-03-01", DateUtil.dateFormatter);
@@ -2895,7 +2895,8 @@ public class PracticeGroupServiceImpl extends BaseServiceImpl<Long, PracticeGrou
         }
         BigDecimal oneMonthPrice;
         if (practiceBuyActivityExpireDate.after(now)&&Objects.nonNull(sysUser.getOrganId())&&sysUser.getOrganId()==14&& studentExitChargePractices <= 0) {
-            oneMonthPrice = practiceGroupBuyParams.getDrillTimesOnWeek() == 1 ? practiceGroupSellPrice.getOnceActivityPrice() : practiceGroupSellPrice.getTwiceActivityPrice();
+//            oneMonthPrice = practiceGroupBuyParams.getDrillTimesOnWeek() == 1 ? practiceGroupSellPrice.getOnceActivityPrice() : practiceGroupSellPrice.getTwiceActivityPrice();
+            oneMonthPrice = practiceGroupBuyParams.getDrillTimesOnWeek() == 1 ? practiceGroupSellPrice.getOnceOriginalPrice() : practiceGroupSellPrice.getTwiceOriginalPrice();
             if (!now.before(practicePromotionActivityStartDate) && practiceGroupBuyParams.getBuyMonths() >= 3 && studentExitChargePractices > 0) {
                 oneMonthPrice = practiceGroupBuyParams.getDrillTimesOnWeek() == 1 ? practiceGroupSellPrice.getOnceQuartActivityPrice() : practiceGroupSellPrice.getTwiceQuartActivityPrice();
             } else if (!now.before(practicePromotionActivityStartDate) && studentExitChargePractices <= 0) {

+ 2 - 0
mec-biz/src/main/java/com/ym/mec/biz/service/impl/StudentRegistrationServiceImpl.java

@@ -25,6 +25,8 @@ import org.apache.commons.lang3.ArrayUtils;
 import com.ym.mec.biz.dal.dao.*;
 import com.ym.mec.biz.dal.entity.*;
 import com.ym.mec.biz.dal.enums.*;
+import com.ym.mec.biz.event.source.GroupEventSource;
+import org.apache.commons.lang3.ArrayUtils;
 import org.apache.commons.lang3.StringUtils;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;

+ 1 - 1
mec-student/src/main/java/com/ym/mec/student/controller/PracticeGroupController.java

@@ -198,7 +198,7 @@ public class PracticeGroupController extends BaseController {
         if (sysUser == null) {
             return failed(HttpStatus.FORBIDDEN, "请登录");
         }
-        int studentExitChargePractices = practiceGroupDao.checkStudentExitChargePractice(sysUser.getId(),"2021-03-10 00:00:00");
+        int studentExitChargePractices = practiceGroupDao.checkStudentExitChargePractice(sysUser.getId(),"2021-03-09 00:00:00");
         Map<String, Integer> result=new HashMap<>();
         result.put("organId", sysUser.getOrganId());
         result.put("isNewStudent", studentExitChargePractices<=0?0:1);

+ 1 - 1
mec-web/src/main/java/com/ym/mec/web/controller/education/EduPracticeGroupController.java

@@ -166,7 +166,7 @@ public class EduPracticeGroupController extends BaseController {
             throw new BizException("请指定学生");
         }
         SysUser student = sysUserFeignService.queryUserById(studentId);
-        int studentExitChargePractices = practiceGroupDao.checkStudentExitChargePractice(studentId, "2021-03-10 00:00:00");
+        int studentExitChargePractices = practiceGroupDao.checkStudentExitChargePractice(studentId, "2021-03-09 00:00:00");
         Map<String, Integer> result=new HashMap<>();
         result.put("organId", student.getOrganId());
         result.put("isNewStudent", studentExitChargePractices<=0?0:1);