소스 검색

Merge remote-tracking branch 'origin/master'

周箭河 4 년 전
부모
커밋
f4e9528c0c

+ 10 - 0
mec-biz/src/main/java/com/ym/mec/biz/dal/dto/StudentGoodsSellDto.java

@@ -8,10 +8,20 @@ public class StudentGoodsSellDto extends StudentPaymentOrder {
 
     private String goodsJson;
 
+    private String userName;
+
     private BigDecimal totalAmount;
 
     private BigDecimal marketAmount;
 
+    public String getUserName() {
+        return userName;
+    }
+
+    public void setUserName(String userName) {
+        this.userName = userName;
+    }
+
     public String getGoodsJson() {
         return goodsJson;
     }

+ 0 - 11
mec-biz/src/main/java/com/ym/mec/biz/dal/entity/MusicGroupStudentFee.java

@@ -58,9 +58,6 @@ public class MusicGroupStudentFee {
 	@ApiModelProperty(value = "最近缴费时间", required = false)
 	private Date latestPaidTime;
 
-	@ApiModelProperty(value = "缴费有效期结束时间", required = false)
-	private String paymentValidEndDate;
-
 	@ApiModelProperty(value = "连续旷到次数", required = false)
 	private Integer continuousAbsenteeismTimes;
 
@@ -101,14 +98,6 @@ public class MusicGroupStudentFee {
 	public MusicGroupStudentFee() {
 	}
 
-	public String getPaymentValidEndDate() {
-		return paymentValidEndDate;
-	}
-
-	public void setPaymentValidEndDate(String paymentValidEndDate) {
-		this.paymentValidEndDate = paymentValidEndDate;
-	}
-
 	public SysUser getSysUser() {
 		return sysUser;
 	}

+ 0 - 1
mec-biz/src/main/java/com/ym/mec/biz/service/StudentGoodsSellService.java

@@ -5,7 +5,6 @@ import com.ym.mec.biz.dal.dto.StudentGoodsSellDto;
 import com.ym.mec.biz.dal.entity.StudentGoodsSell;
 import com.ym.mec.biz.dal.page.GoodsSellQueryInfo;
 import com.ym.mec.common.page.PageInfo;
-import com.ym.mec.common.page.QueryInfo;
 import com.ym.mec.common.service.BaseService;
 
 public interface StudentGoodsSellService extends BaseService<Integer, StudentGoodsSell> {

+ 0 - 1
mec-biz/src/main/java/com/ym/mec/biz/service/impl/MusicGroupServiceImpl.java

@@ -1757,7 +1757,6 @@ public class MusicGroupServiceImpl extends BaseServiceImpl<String, MusicGroup> i
                 musicGroupStudentFee.setRemainNetworkClassTimes(getRemainNetworkClassTimes + 1);
             }
 //            musicGroupStudentFee.setNextPaymentDate(musicGroupPaymentCalenderService.getNextPaymentDate(musicGroupId, musicGroupStudentFee.getNextPaymentDate(), musicGroupStudentFee));
-            musicGroupStudentFee.setPaymentValidEndDate(musicGroupPaymentCalender.getPaymentValidEndDate());
             musicGroupStudentFeeDao.update(musicGroupStudentFee);
 
             //更新学生的缴费记录状态

+ 1 - 1
mec-biz/src/main/java/com/ym/mec/biz/service/impl/StudentGoodsSellServiceImpl.java

@@ -34,7 +34,7 @@ public class StudentGoodsSellServiceImpl extends BaseServiceImpl<Integer, Studen
 	public PageInfo<StudentGoodsSellDto> queryStudentGoodsOrders(GoodsSellQueryInfo queryInfo) {
 		//根据订单状态和教务老师获取订单列表
 		PageInfo<StudentGoodsSellDto> pageInfo = new PageInfo<>(queryInfo.getPage(), queryInfo.getRows());
-		Map<String, Object> params = new HashMap<String, Object>();
+		Map<String, Object> params = new HashMap<>();
 		MapUtil.populateMap(params, queryInfo);
 		List<StudentGoodsSellDto> dataList = null;
 		int count = studentGoodsSellDao.countStudentGoodsOrders(params);

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

@@ -713,9 +713,6 @@ public class StudentRegistrationServiceImpl extends BaseServiceImpl<Long, Studen
             if (musicGroup.getFeeType() != null && musicGroup.getFeeType() != MusicGroupPaymentCalender.FeeType.OFFLINE && musicGroupStudentFee.getTemporaryCourseFee().doubleValue() * 100 == 0) {
                 musicGroupStudentFee.setRemainNetworkClassTimes(musicGroupStudentFee.getRemainNetworkClassTimes() + 1);
             }
-            if (studentRegistration.getPaymentStatus() == PaymentStatusEnum.YES) {
-                musicGroupStudentFee.setPaymentValidEndDate(musicGroup.getPaymentValidEndDate());
-            }
             musicGroupStudentFeeDao.insert(musicGroupStudentFee);
 //            musicGroupStudentFeeDao.insert(new MusicGroupStudentFee(musicGroupId,
 //                    userId, studentRegistration.getSubjectId(), studentAddDto.getCourseFee(),
@@ -881,7 +878,6 @@ public class StudentRegistrationServiceImpl extends BaseServiceImpl<Long, Studen
                 if (musicGroup.getFeeType() != null && musicGroup.getFeeType() != MusicGroupPaymentCalender.FeeType.OFFLINE) {
                     musicGroupStudentFee.setRemainNetworkClassTimes(musicGroupStudentFee.getRemainNetworkClassTimes() + 1);
                 }
-                musicGroupStudentFee.setPaymentValidEndDate(musicGroup.getPaymentValidEndDate());
                 musicGroupStudentFee.setUpdateTime(nowDate);
                 musicGroupStudentFeeDao.update(musicGroupStudentFee);
                 //添加学生

+ 4 - 8
mec-biz/src/main/resources/config/mybatis/MusicGroupStudentFeeMapper.xml

@@ -15,7 +15,6 @@
         <result column="course_fee_" property="courseFee"/>
         <result column="next_payment_date_" property="nextPaymentDate"/>
         <result column="latest_paid_time_" property="latestPaidTime"/>
-        <result column="payment_valid_end_date_" property="paymentValidEndDate"/>
         <result column="continuous_absenteeism_times_" property="continuousAbsenteeismTimes"/>
         <result column="create_time_" property="createTime"/>
         <result column="update_time_" property="updateTime"/>
@@ -45,19 +44,19 @@
             keyColumn="id" keyProperty="id">
 		INSERT INTO music_group_student_fee_ (id_,music_group_id_,user_id_,course_fee_,create_time_,
 		update_time_,next_payment_date_,latest_paid_time_,continuous_absenteeism_times_,subject_id_,
-		payment_status_,temporary_course_fee_,payment_period_list_,remain_network_class_times_,payment_valid_end_date_)
+		payment_status_,temporary_course_fee_,payment_period_list_,remain_network_class_times_)
 		VALUES(#{id},#{musicGroupId},#{userId},#{courseFee},now(),now(),#{nextPaymentDate},#{latestPaidTime},
 		#{continuousAbsenteeismTimes},#{subjectId},#{paymentStatus,typeHandler=com.ym.mec.common.dal.CustomEnumTypeHandler},
-		#{temporaryCourseFee},#{paymentPeriodList},#{remainNetworkClassTimes},#{paymentValidEndDate})
+		#{temporaryCourseFee},#{paymentPeriodList},#{remainNetworkClassTimes})
 	</insert>
 
     <insert id="batchInsert" parameterType="com.ym.mec.biz.dal.entity.MusicGroupStudentFee">
         INSERT INTO music_group_student_fee_ (music_group_id_,user_id_,create_time_,update_time_,next_payment_date_,
-        subject_id_,payment_status_,course_fee_,payment_period_list_,remain_network_class_times_,payment_valid_end_date_)
+        subject_id_,payment_status_,course_fee_,payment_period_list_,remain_network_class_times_)
 		VALUES
 		<foreach collection="musicGroupStudentFees" item="item" separator=",">
             (#{item.musicGroupId},#{item.userId},NOW(),NOW(),#{nextPaymentDate},#{item.subjectId},
-            #{paymentStatus},#{item.courseFee},#{item.paymentPeriodList},#{item.remainNetworkClassTimes},#{item.paymentValidEndDate})
+            #{paymentStatus},#{item.courseFee},#{item.paymentPeriodList},#{item.remainNetworkClassTimes})
         </foreach>
     </insert>
 
@@ -65,9 +64,6 @@
     <update id="update" parameterType="com.ym.mec.biz.dal.entity.MusicGroupStudentFee">
         UPDATE music_group_student_fee_
         <set>
-            <if test="paymentValidEndDate != null">
-                payment_valid_end_date_ = #{paymentValidEndDate},
-            </if>
             <if test="userId != null">
                 user_id_ = #{userId},
             </if>

+ 7 - 1
mec-biz/src/main/resources/config/mybatis/StudentGoodsSellMapper.xml

@@ -80,12 +80,14 @@
     <select id="countStudentGoodsOrders" resultType="java.lang.Integer">
 		SELECT COUNT(spo.id_) FROM student_payment_order spo
 		LEFT JOIN student_goods_sell sgs ON spo.order_no_ = sgs.order_no_
+		LEFT JOIN sys_user su ON sgs.user_id_ = su.id_
 		<include refid="queryStudentGoodsOrdersSql"/>
 	</select>
 	<resultMap type="com.ym.mec.biz.dal.dto.StudentGoodsSellDto" id="StudentGoodsSellDto" extends="com.ym.mec.biz.dal.dao.StudentPaymentOrderDao.StudentPaymentOrder">
 		<result column="goods_json_" property="goodsJson" />
 		<result column="total_amount_" property="totalAmount" />
 		<result column="market_amount_" property="marketAmount" />
+		<result column="user_name_" property="userName" />
 	</resultMap>
 	<sql id="queryStudentGoodsOrdersSql">
 		<where>
@@ -98,11 +100,15 @@
 			<if test="status != null">
 				AND spo.status_ = #{status}
 			</if>
+			<if test="search != null and search != ''">
+				AND (su.user_name_ LIKE CONCAT('%',#{search},'%') OR su.phone_ LIKE CONCAT('%',#{search},'%'))
+			</if>
 		</where>
 	</sql>
 	<select id="queryStudentGoodsOrders" resultMap="StudentGoodsSellDto">
-		SELECT spo.*,sgs.goods_json_,sgs.total_amount_,sgs.market_amount_ FROM student_payment_order spo
+		SELECT spo.*,sgs.goods_json_,sgs.total_amount_,sgs.market_amount_,su.user_name_ FROM student_payment_order spo
 		LEFT JOIN student_goods_sell sgs ON spo.order_no_ = sgs.order_no_
+		LEFT JOIN sys_user su ON sgs.user_id_ = su.id_
 		<include refid="queryStudentGoodsOrdersSql"/>
 		ORDER BY spo.create_time_ DESC
 		<include refid="global.limit"/>