zjh
2025-06-18 b115eea2b161adddeb92c5e885019aba8763bb0e
ltkj-hosp/src/main/resources/mapper/hosp/TjDwGroupingMapper.xml
@@ -24,7 +24,22 @@
    </resultMap>
    <sql id="selectTjDwGroupingVo">
        select id, dw_id, dw_name, dw_dept_id, dw_dept_name, grouping_name, limit, pac_name, pay_type, sex, gt_age, lt_age, create_by, update_time, update_by, deleted
        select id,
               dw_id,
               dw_name,
               dw_dept_id,
               dw_dept_name,
               grouping_name,
               limit,
               pac_name,
               pay_type,
               sex,
               gt_age,
               lt_age,
               create_by,
               update_time,
               update_by,
               deleted
        from tj_dw_grouping
    </sql>
@@ -74,6 +89,19 @@
            resultMap="TjDwGroupingResult">
            <include refid="selectTjDwGroupingVo"/>
            where id = #{id}
    </select>
    <select id="huoqutuantitaocanxiangmuhuoqutuantitaocanxiangmuList" parameterType="string"
            resultType="com.ltkj.hosp.domain.TjPackage">
        SELECT a.id pac_id,grouping_name pac_name,a.ys_price price , GROUP_CONCAT(b.pro_name ORDER BY b.pro_name)
        allProName FROM
        tj_dw_grouping a JOIN tj_grouping_pro b ON b.grouping_id=a.id
        <where>
            <if test="dwId != null" >
                and a.dw_id = #{dwId}
            </if>
            and a.deleted=0 GROUP BY b.grouping_id
        </where>
    </select>
    <insert id="insertTjDwGrouping" parameterType="TjDwGrouping">
@@ -202,7 +230,8 @@
    <delete id="deleteTjDwGroupingById" parameterType="String">
        delete
        from tj_dw_grouping where id = #{id}
        from tj_dw_grouping
        where id = #{id}
    </delete>
    <delete id="deleteTjDwGroupingByIds" parameterType="String">