| | |
| | | <result property="organchargedesc" column="organchargedesc"/> |
| | | <result property="notgetreason" column="notgetreason"/> |
| | | <result property="transplantstate" column="transplantstate"/> |
| | | <result property="sort" column="sort"/> |
| | | </resultMap> |
| | | |
| | | <sql id="selectServiceDonateorganVo"> |
| | |
| | | InfoID, |
| | | DonorNo, |
| | | OrganNo, |
| | | sort, |
| | | OrganName, |
| | | OrganState, |
| | | OrganNumber, |
| | |
| | | <include refid="selectServiceDonateorganVo"/> |
| | | <where> |
| | | <if test="infoid != null ">and InfoID = #{infoid}</if> |
| | | <if test="sort != null ">and sort = #{sort}</if> |
| | | <if test="donorno != null and donorno != ''">and DonorNo = #{donorno}</if> |
| | | <if test="organno != null and organno != ''">and OrganNo = #{organno}</if> |
| | | <if test="organname != null and organname != ''">and OrganName like concat('%', #{organname}, '%')</if> |
| | |
| | | inner join service_donatebaseinfo b on b.id = d.InfoID |
| | | inner join base_organization o on b.TreatmentHospitalNo = o.OrganizationID |
| | | where b.del_flag=0 |
| | | AND d.transplantstate = "1" |
| | | AND d.del_flag=0 |
| | | AND d.TransplantTime IS NOT NULL |
| | | AND d.OrganNo != 'C00' |
| | | AND d.OrganNo != 'C69L' |
| | | AND d.OrganNo != 'C69R' |
| | | <if test="transplantstate != null">and d.transplantstate >= #{transplantstate}</if> |
| | | <if test="starttime != null">and d.TransplantTime >= #{starttime}</if> |
| | | <if test="endtime != null ">and d.TransplantTime <= #{endtime}</if> |
| | | <if test="city != null and city != ''">and o.City = #{city}</if> |
| | |
| | | `service_donatebaseinfo`.`ReportTime` AS `ReportTime`, |
| | | `service_donatebaseinfo`.`RecordState` AS `RecordState`, |
| | | `service_donateorgan`.`ID` AS `doID`, |
| | | `service_donateorgan`.`sort` AS `sort`, |
| | | `service_donateorgan`.`InfoID` AS `InfoID`, |
| | | `service_donateorgan`.`DonorNo` AS `doDonorNo`, |
| | | `service_donateorgan`.`OrganNo` AS `OrganNo`, |
| | |
| | | and OrganGetTime >= #{starttime} |
| | | and OrganGetTime <= #{endtime} |
| | | </select> |
| | | <select id="getDistinctOrgansCount" resultType="java.lang.Integer"> |
| | | select count(*) from service_donationwitnessorgan d |
| | | <select id="getDistinctOrgansCount" resultType="com.ruoyi.project.domain.vo.DistinctOrgansCount"> |
| | | select count(*) as gainsum,ifnull(sum( CASE WHEN transplantstate = 3 THEN 1 ELSE 0 END ),0) as abandonCount from service_donatecomporgan d |
| | | inner join service_donatebaseinfo b on b.id = d.InfoID |
| | | inner join base_organization o on b.TreatmentHospitalNo = o.OrganizationID |
| | | where d.OrganNo = #{organno} |
| | | -- and (OrganState = "3" or OrganState = "4" or OrganState = "5" or OrganState = "6") |
| | | and d.del_flag=0 |
| | | and d.del_flag=0 and b.del_flag = 0 and b.workflow>5 |
| | | -- and d.OrganGetTime IS NOT NULL |
| | | <if test="starttime != null ">and d.OrganGetTime >= #{starttime}</if> |
| | | <if test="endtime != null ">and d.OrganGetTime <= #{endtime}</if> |
| | | <if test="starttime != null ">and b.donatetime >= #{starttime}</if> |
| | | <if test="endtime != null ">and b.donatetime <= #{endtime}</if> |
| | | <if test="city != null and city != ''">and o.City = #{city}</if> |
| | | <if test="reporterno != null and reporterno != ''">and b.ReporterNo = #{reporterno}</if> |
| | | </select> |
| | |
| | | order by create_time desc |
| | | </select> |
| | | |
| | | </mapper> |
| | | </mapper> |