From f8b251573040d2762507909a02f274a6cf4d751c Mon Sep 17 00:00:00 2001 From: heheng <heheng@123456> Date: 星期四, 23 一月 2025 14:40:27 +0800 Subject: [PATCH] 特种作业非煤缴费版本优化 --- exam-system/src/main/resources/mapper/pay/NonCoalPayMapper.xml | 69 ++++++++++++++++++++++++++++++++++ 1 files changed, 69 insertions(+), 0 deletions(-) diff --git a/exam-system/src/main/resources/mapper/pay/NonCoalPayMapper.xml b/exam-system/src/main/resources/mapper/pay/NonCoalPayMapper.xml index b273dae..352ec81 100644 --- a/exam-system/src/main/resources/mapper/pay/NonCoalPayMapper.xml +++ b/exam-system/src/main/resources/mapper/pay/NonCoalPayMapper.xml @@ -202,6 +202,75 @@ </select> + <resultMap type="com.gkhy.exam.pay.dto.rep.NonCoalPayOrder" id="getNonCoalPayResultOrder"> + <result property="id" column="id"/> + <result property="batchName" column="batch_name"/> + <result property="amount" column="amount"/> + <result property="payPersonType" column="pay_person_type"/> + <result property="payCompanyName" column="pay_company_name"/> + <result property="payCompanyCard" column="pay_company_card"/> + <collection property="nonCoalPayCategoryList" javaType="java.util.List" + resultMap="nonCoalPayCategoryListOrder"/> + <collection property="nonCoalStuList" javaType="java.util.List" + resultMap="nonCoalPayStuListOrder"/> + </resultMap> + <resultMap id="nonCoalPayCategoryListOrder" type="com.gkhy.exam.pay.dto.rep.NonCoalCateRep"> + <result property="id" column="non_category_id"/> + <result property="businessCode" column="business_code"/> + <result property="companyCode" column="company_code"/> + <result property="invoicingCompanyCode" column="invoicing_company_code"/> + <result property="drawer" column="drawer"/> + <result property="reviewer" column="reviewer"/> + <result property="categoryId" column="category_id"/> + <result property="subjectName" column="subject_name"/> + <result property="categoryType" column="category_type"/> + <result property="categoryAmount" column="category_amount"/> + </resultMap> + + <resultMap id="nonCoalPayStuListOrder" type="com.gkhy.exam.pay.dto.rep.NonCoalStuRep"> + <result property="id" column="non_coal_student_id"/> + <result property="phone" column="phone"/> + <result property="idCard" column="id_card"/> + <result property="studentName" column="student_name"/> + <result property="payStatus" column="pay_status"/> + <result property="orderId" column="order_id"/> + </resultMap> + + + <select id="selectNonCoalPayOrderByParam" resultMap="getNonCoalPayResultOrder"> + select a.id, + a.batch_name, + a.pay_type, + a.amount, + a.pay_person_type, + a.pay_company_name, + a.pay_company_card, + b.id as non_category_id, + b.category_id, + c.subject_name, + c.category_type, + c.business_code, + c.company_code, + c.drawer, + c.reviewer, + c.invoicing_company_code, + b.category_amount, + t.id as non_coal_student_id, + t.phone, + t.id_card, + t.name as student_name, + t.pay_status, + t.order_id + from non_coal_pay a + inner join non_coal_pay_student t on t.non_coal_pay_id = a.id and t.del_flag = 0 and t.pay_status = 0 + inner join non_coal_pay_category b on a.id = b.non_coal_pay_id and b.del_flag = 0 + left join non_coal_category c on b.category_id = c.id and c.del_flag = 0 + where a.del_flag = 0 + <if test="payType != null and payType == 2 ">and a.id = #{dataId} and t.pay_type = #{payType}</if> + <if test="payType != null and payType == 1 ">and t.id = #{dataId} and t.pay_type = #{payType}</if> + + </select> + <insert id="insertNonCoalPay" parameterType="NonCoalPay" useGeneratedKeys="true" keyProperty="id"> insert into non_coal_pay -- Gitblit v1.9.2