|  | @@ -86,14 +86,14 @@
 | 
	
		
			
				|  |  |          INSERT INTO student_payment_order
 | 
	
		
			
				|  |  |          (id_, group_type_, user_id_, organ_id_, routing_organ_id_, type_, expect_amount_, actual_amount_, com_amount_,
 | 
	
		
			
				|  |  |           per_amount_,
 | 
	
		
			
				|  |  | -         balance_payment_amount_, remit_fee_,course_remit_fee_, trans_no_,
 | 
	
		
			
				|  |  | +         balance_payment_amount_, remit_fee_, course_remit_fee_, trans_no_,
 | 
	
		
			
				|  |  |           status_, memo_, create_time_, update_time_, payment_channel_, payment_business_channel_,
 | 
	
		
			
				|  |  |           payment_account_no_, mer_nos_, order_no_, music_group_id_, class_group_id_, pay_time_)
 | 
	
		
			
				|  |  |          VALUES (#{id}, #{groupType,typeHandler=com.ym.mec.common.dal.CustomEnumTypeHandler},
 | 
	
		
			
				|  |  |                  #{userId}, #{organId}, #{routingOrganId},
 | 
	
		
			
				|  |  |                  #{type,typeHandler=com.ym.mec.common.dal.CustomEnumTypeHandler},
 | 
	
		
			
				|  |  |                  #{expectAmount}, #{actualAmount}, #{comAmount}, #{perAmount}, #{balancePaymentAmount},
 | 
	
		
			
				|  |  | -                #{remitFee},#{courseRemitFee}, #{transNo},
 | 
	
		
			
				|  |  | +                #{remitFee}, #{courseRemitFee}, #{transNo},
 | 
	
		
			
				|  |  |                  #{status,typeHandler=com.ym.mec.common.dal.CustomEnumTypeHandler}, #{memo}, now(), now(),
 | 
	
		
			
				|  |  |                  #{paymentChannel}, #{paymentBusinessChannel}, #{paymentAccountNo}, #{merNos}, #{orderNo},
 | 
	
		
			
				|  |  |                  #{musicGroupId},
 | 
	
	
		
			
				|  | @@ -205,7 +205,6 @@
 | 
	
		
			
				|  |  |      </select>
 | 
	
		
			
				|  |  |  
 | 
	
		
			
				|  |  |      <sql id="queryPaymentOrder">
 | 
	
		
			
				|  |  | -        <![CDATA[
 | 
	
		
			
				|  |  |          <where>
 | 
	
		
			
				|  |  |              <if test="userIds != null">
 | 
	
		
			
				|  |  |                  AND spo.user_id_ IN
 | 
	
	
		
			
				|  | @@ -254,10 +253,10 @@
 | 
	
		
			
				|  |  |                  AND spo.balance_payment_amount_ >= #{balancePaymentAmount}
 | 
	
		
			
				|  |  |              </if>
 | 
	
		
			
				|  |  |              <if test="lessActualAmount != null">
 | 
	
		
			
				|  |  | -                AND spo.actual_amount_ <= #{lessActualAmount}
 | 
	
		
			
				|  |  | -           </if>
 | 
	
		
			
				|  |  | +                <![CDATA[ AND spo.actual_amount_ <= #{lessActualAmount}]]>
 | 
	
		
			
				|  |  | +            </if>
 | 
	
		
			
				|  |  |              <if test="lessBalancePaymentAmount != null">
 | 
	
		
			
				|  |  | -                AND spo.balance_payment_amount_ <= #{lessBalancePaymentAmount}
 | 
	
		
			
				|  |  | +                <![CDATA[AND spo.balance_payment_amount_ <= #{lessBalancePaymentAmount}]]>
 | 
	
		
			
				|  |  |              </if>
 | 
	
		
			
				|  |  |              <if test="orderNo != null">
 | 
	
		
			
				|  |  |                  AND spo.order_no_ = #{orderNo}
 | 
	
	
		
			
				|  | @@ -273,7 +272,6 @@
 | 
	
		
			
				|  |  |                  AND sci.charge_type_ = #{chargeType,typeHandler=com.ym.mec.common.dal.CustomEnumTypeHandler}
 | 
	
		
			
				|  |  |              </if>
 | 
	
		
			
				|  |  |          </where>
 | 
	
		
			
				|  |  | -         ]]>
 | 
	
		
			
				|  |  |      </sql>
 | 
	
		
			
				|  |  |  
 | 
	
		
			
				|  |  |      <select id="queryApplyGoodsList" resultMap="Goods" parameterType="map">
 | 
	
	
		
			
				|  | @@ -705,11 +703,17 @@
 | 
	
		
			
				|  |  |      </select>
 | 
	
		
			
				|  |  |  
 | 
	
		
			
				|  |  |      <select id="getUsers" resultType="com.ym.mec.biz.dal.dto.BasicUserDto">
 | 
	
		
			
				|  |  | -            SELECT username_ name ,id_ userId,phone_ phone FROM sys_user
 | 
	
		
			
				|  |  | -            WHERE id_ = #{search} OR username_ LIKE CONCAT('%',#{search},'%') OR phone_ LIKE CONCAT('%',#{search},'%')
 | 
	
		
			
				|  |  | +        SELECT username_ name, id_ userId, phone_ phone
 | 
	
		
			
				|  |  | +        FROM sys_user
 | 
	
		
			
				|  |  | +        WHERE id_ = #{search}
 | 
	
		
			
				|  |  | +           OR username_ LIKE CONCAT('%', #{search}, '%')
 | 
	
		
			
				|  |  | +           OR phone_ LIKE CONCAT('%', #{search}, '%')
 | 
	
		
			
				|  |  |      </select>
 | 
	
		
			
				|  |  |  
 | 
	
		
			
				|  |  |      <select id="lockOrder" resultMap="StudentPaymentOrder">
 | 
	
		
			
				|  |  | -        SELECT * FROM student_payment_order WHERE id_ = #{id} FOR UPDATE
 | 
	
		
			
				|  |  | +        SELECT *
 | 
	
		
			
				|  |  | +        FROM student_payment_order
 | 
	
		
			
				|  |  | +        WHERE id_ = #{id} FOR
 | 
	
		
			
				|  |  | +        UPDATE
 | 
	
		
			
				|  |  |      </select>
 | 
	
		
			
				|  |  |  </mapper>
 |