浏览代码

Merge remote-tracking branch 'origin/master'

zouxuan 4 年之前
父节点
当前提交
c70762d654

+ 11 - 0
mec-biz/src/main/java/com/ym/mec/biz/dal/page/RepairStudentQueryInfo.java

@@ -34,6 +34,9 @@ public class RepairStudentQueryInfo extends QueryInfo {
     @ApiModelProperty(value = "特权减免金额",required = false)
     private BigDecimal exemptionAmount;
 
+    @ApiModelProperty(value = "是否有减免金额0-否 1-是",required = false)
+    private Integer hasExemptionAmount;
+
 
     public Integer getSubjectId() {
         return subjectId;
@@ -122,4 +125,12 @@ public class RepairStudentQueryInfo extends QueryInfo {
     public void setExemptionAmount(BigDecimal exemptionAmount) {
         this.exemptionAmount = exemptionAmount;
     }
+
+    public Integer getHasExemptionAmount() {
+        return hasExemptionAmount;
+    }
+
+    public void setHasExemptionAmount(Integer hasExemptionAmount) {
+        this.hasExemptionAmount = hasExemptionAmount;
+    }
 }

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

@@ -259,10 +259,10 @@ public class VipGroupServiceImpl extends BaseServiceImpl<Long, VipGroup> impleme
 			}
 		}
 
-		if(Objects.nonNull(vipGroupActivity.getAttribute3())){
+		if(Objects.nonNull(vipGroupActivity.getAttribute3())&&StringUtils.isNotBlank(vipGroupActivity.getAttribute3())){
 			Integer maxCourseNum = Integer.parseInt(vipGroupActivity.getAttribute3());
 			Integer requestCourseNum = vipGroupApplyBaseInfoDto.getOnlineClassesNum() + vipGroupApplyBaseInfoDto.getOfflineClassesNum();
-			if(requestCourseNum.compareTo(maxCourseNum)>0){
+			if(requestCourseNum.compareTo(maxCourseNum)!=0){
 				throw new BizException("该活动课时数为{}节", maxCourseNum);
 			}
 		}

+ 4 - 1
mec-biz/src/main/resources/config/mybatis/StudentRepairMapper.xml

@@ -209,9 +209,12 @@
             <if test="studentInstrumentId != null">
                 AND sr.student_instrument_id_ = #{studentInstrumentId}
             </if>
-            <if test="exemptionAmount != null">
+            <if test="hasExemptionAmount != null and hasExemptionAmount ==1">
                 AND sr.exemption_amount_ > #{exemptionAmount}
             </if>
+            <if test="hasExemptionAmount != null and hasExemptionAmount ==0">
+                AND sr.exemption_amount_ = 0
+            </if>
         </where>
     </sql>
     <select id="queryCount" resultType="int">