From a1f2eefe4641764955c846ad58ebdbcedd96699d Mon Sep 17 00:00:00 2001
From: yxh <172933527@qq.com>
Date: 星期三, 28 十月 2026 17:31:58 +0800
Subject: [PATCH] 修改了统计

---
 ruoyi-project/src/main/resources/mapper/project/ServiceDonatecomporganMapper.xml |   30 +++++++++++++++++++++---------
 1 files changed, 21 insertions(+), 9 deletions(-)

diff --git a/ruoyi-project/src/main/resources/mapper/project/ServiceDonatecomporganMapper.xml b/ruoyi-project/src/main/resources/mapper/project/ServiceDonatecomporganMapper.xml
index 4f6387d..8cc779a 100644
--- a/ruoyi-project/src/main/resources/mapper/project/ServiceDonatecomporganMapper.xml
+++ b/ruoyi-project/src/main/resources/mapper/project/ServiceDonatecomporganMapper.xml
@@ -13,8 +13,8 @@
         <result property="abandonreason" column="AbandonReason"/>
         <result property="transplanttime" column="TransplantTime"/>
         <result property="transplantdoct" column="TransplantDoct"/>
-        <result property="transplanthospitalno" column="TransplantHospitalNo"/>
-        <result property="transplanthospitalname" column="TransplantHospitalName"/>
+        <result property="hospitalno" column="HospitalNo"/>
+        <result property="hospitalname" column="HospitalName"/>
         <result property="name" column="Name"/>
         <result property="sex" column="Sex"/>
         <result property="idcardtype" column="IDCardType"/>
@@ -34,11 +34,15 @@
         <result property="residencecommunityname" column="ResidenceCommunityName"/>
         <result property="residencecountycode" column="ResidenceCountyCode"/>
         <result property="residencecountyname" column="ResidenceCountyName"/>
+        <!-- 2026-10-23锛氬櫒瀹樻帓闃熷簭鍙� -->
+        <result property="sort" column="sort"/>
         <result property="delFlag" column="del_flag"/>
         <result property="createBy" column="create_by"/>
         <result property="createTime" column="create_time"/>
         <result property="updateBy" column="update_by"/>
         <result property="updateTime" column="update_time"/>
+        <result property="caseno" column="caseno"/>
+        <result property="donorname" column="donorname"/>
     </resultMap>
 
     <sql id="selectServiceDonatecomporganVo">
@@ -46,13 +50,15 @@
                InfoID,
                OrganNo,
                OrganName,
+               sort,
                transplantstate,
                AbandonReason,
                TransplantTime,
                TransplantDoct,
-               TransplantHospitalNo,
-               TransplantHospitalName,
+               HospitalNo,
+               HospitalName,
                Name,
+               caseno,
                Sex,
                IDCardType,
                IDCardNo,
@@ -75,7 +81,8 @@
                create_by,
                create_time,
                update_by,
-               update_time
+               update_time,
+               donorname
         from service_donatecomporgan
     </sql>
 
@@ -90,14 +97,15 @@
             <if test="abandonreason != null  and abandonreason != ''">and AbandonReason = #{abandonreason}</if>
             <if test="transplanttime != null ">and TransplantTime = #{transplanttime}</if>
             <if test="transplantdoct != null  and transplantdoct != ''">and TransplantDoct = #{transplantdoct}</if>
-            <if test="transplanthospitalno != null  and transplanthospitalno != ''">and TransplantHospitalNo =
-                #{transplanthospitalno}
+            <if test="hospitalno != null  and hospitalno != ''">and HospitalNo =
+                #{hospitalno}
             </if>
-            <if test="transplanthospitalname != null  and transplanthospitalname != ''">and TransplantHospitalName like
-                concat('%', #{transplanthospitalname}, '%')
+            <if test="hospitalname != null  and hospitalname != ''">and HospitalName like
+                concat('%', #{hospitalname}, '%')
             </if>
             <if test="name != null  and name != ''">and Name like concat('%', #{name}, '%')</if>
             <if test="sex != null ">and Sex = #{sex}</if>
+            <if test="caseno != null ">and caseno = #{caseno}</if>
             <if test="idcardtype != null ">and IDCardType = #{idcardtype}</if>
             <if test="idcardno != null  and idcardno != ''">and IDCardNo = #{idcardno}</if>
             <if test="age != null ">and Age = #{age}</if>
@@ -105,6 +113,8 @@
             <if test="birthday != null  and birthday != ''">and Birthday = #{birthday}</if>
             <if test="phone != null  and phone != ''">and Phone = #{phone}</if>
             <if test="residenceaddress != null  and residenceaddress != ''">and ResidenceAddress = #{residenceaddress}
+            </if>
+            <if test="donorname != null  and donorname != ''">and donorname = #{donorname}
             </if>
             <if test="residenceprovince != null  and residenceprovince != ''">and ResidenceProvince =
                 #{residenceprovince}
@@ -133,6 +143,8 @@
                 concat('%', #{residencecountyname}, '%')
             </if>
         </where>
+        <!-- 2026-10-23锛氭寜鍣ㄥ畼鎺掗槦搴忓彿鎺掑簭锛堢┖鐨勬帓鏈�鍚庯紝鍐嶆寜涓婚敭鍏滃簳锛� -->
+        order by (sort is null or sort = 0), sort asc, ID asc
     </select>
 
 </mapper>
\ No newline at end of file

--
Gitblit v1.9.3