Files
nanguangszwlback/mhd_finance/src/main/resources/mapper/branchBillOtherFee/BranchBillOtherFeeMapper.xml
T
2025-11-20 10:45:16 +08:00

81 lines
4.1 KiB
XML

<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.linke.finance.domain.branchBillOtherFee.repository.mapper.BranchBillOtherFeeMapper">
<resultMap type="com.linke.finance.domain.branchBillOtherFee.repository.po.BranchBillOtherFeePO" id="BranchBillOtherFeeResult">
<result property="branchBillOtherFeeId" column="branch_bill_other_fee_id" />
<result property="topOrganizationId" column="top_organization_id" />
<result property="organizationId" column="organization_id" />
<result property="organizationName" column="organization_name" />
<result property="firstSubject" column="first_subject" />
<result property="firstSubjectName" column="first_subject_name" />
<result property="secondSubject" column="second_subject" />
<result property="secondSubjectName" column="second_subject_name" />
<result property="revenueExpensesType" column="revenue_expenses_type" />
<result property="money" column="money" />
<result property="createTime" column="create_time" />
<result property="createBy" column="create_by" />
<result property="createByName" column="create_by_name" />
<result property="updateTime" column="update_time" />
<result property="updateBy" column="update_by" />
<result property="updateByName" column="update_by_name" />
<result property="delFlag" column="del_flag" />
</resultMap>
<sql id="selectBranchBillOtherFeePo">
select branch_bill_other_fee_id, top_organization_id, organization_id, organization_name, bill_code, first_subject, first_subject_name, second_subject, second_subject_name, revenue_expenses_type, money, create_time, create_by, create_by_name, update_time, update_by, update_by_name, del_flag from branch_bill_other_fee
</sql>
<sql id="selectBranchBillOtherFeePo1">
<where>
<if test="topOrganizationId != null ">
and top_organization_id = #{topOrganizationId}
</if>
<if test="organizationId != null ">
and organization_id = #{organizationId}
</if>
<if test="organizationName != null and organizationName != ''">
and organization_name like concat('%', #{organizationName}, '%')
</if>
<if test="billCode != null and billCode != ''">
and bill_code = #{billCode}
</if>
<if test="firstSubject != null and firstSubject != ''">
and first_subject = #{firstSubject}
</if>
<if test="firstSubjectName != null and firstSubjectName != ''">
and first_subject_name like concat('%', #{firstSubjectName}, '%')
</if>
<if test="secondSubject != null and secondSubject != ''">
and second_subject = #{secondSubject}
</if>
<if test="secondSubjectName != null and secondSubjectName != ''">
and second_subject_name like concat('%', #{secondSubjectName}, '%')
</if>
<if test="revenueExpensesType != null ">
and revenue_expenses_type = #{revenueExpensesType}
</if>
<if test="money != null ">
and money = #{money}
</if>
<if test="createByName != null and createByName != ''">
and create_by_name like concat('%', #{createByName}, '%')
</if>
<if test="updateByName != null and updateByName != ''">
and update_by_name like concat('%', #{updateByName}, '%')
</if>
<choose>
<when test=" delFlag != null "> AND del_flag = #{delFlag} </when>
<otherwise> AND del_flag = 1 </otherwise>
</choose>
</where>
</sql>
<select id="queryList" parameterType="com.linke.finance.domain.branchBillOtherFee.repository.todo.BranchBillOtherFeeDO" resultMap="BranchBillOtherFeeResult">
<include refid="selectBranchBillOtherFeePo"/>
<include refid="selectBranchBillOtherFeePo1"/>
</select>
</mapper>