chengf
2025-08-13 f44187822ea6217070c0f6fc585c3feadea03cb1
java110-db/src/main/resources/mapper/fee/FeeServiceDaoImplMapper.xml
@@ -136,7 +136,7 @@
        pfa2.`value` ownerName,t.batch_id,t.batch_id batchId,
        pfc.pay_online payOnline,pfc.scale,pfc.decimal_place decimalPlace,pfc.units,pfc.prepayment_period
        prepaymentPeriod,
        pfrb.rule_id ruleId,pfrb.month_cycle monthCycle
        pfrb.rule_id ruleId,pfrb.month_cycle monthCycle,t.is_contract_fee isContractFee
        from pay_fee t
        INNER join pay_fee_config pfc on t.config_id = pfc.config_id and
        pfc.status_cd = '0'
@@ -235,6 +235,13 @@
        <if test="curYear !=null and curYear != ''">
            and DATE_FORMAT(t.end_time,'%Y') = #{curYear}
        </if>
        <if test="isContractFee != null">
            and t.is_contract_fee = #{isContractFee}
        </if>
        <if test="isContractFee == null">
            and t.is_contract_fee IS NULL
        </if>
        order by t.create_time desc
        <if test="page != -1 and page != null ">
            limit #{page}, #{row}
@@ -274,6 +281,13 @@
        <if test="payerObjId != null and payerObjId != ''">  <!-- 修正原条件中的变量错误 -->
            and t.payer_obj_id = #{payerObjId}
        </if>
        <if test="isContractFee != null">
            and t.is_contract_fee = #{isContractFee}
        </if>
        <if test="isContractFee == null">
            and t.is_contract_fee IS NULL
        </if>
    </select>
    <!-- 修改费用信息 add by wuxw 2018-07-03 -->
@@ -314,6 +328,9 @@
        </if>
        <if test="feeFlag !=null and feeFlag != ''">
            , t.fee_flag= #{feeFlag}
        </if>
        <if test="isContractFee !=null and isContractFee != ''">
            , t.is_contract_fee = #{isContractFee}
        </if>
        where 1=1
        <if test="bId !=null and bId != ''">
@@ -383,6 +400,14 @@
            and t.community_id= #{communityId}
            and pfc.community_id in (#{communityId},'9999')
        </if>
        <if test="isContractFee != null">
            and is_contract_fee = #{isContractFee}
        </if>
        <if test="isContractFee == null">
            and is_contract_fee IS NULL
        </if>
        <if test="bId !=null and bId != ''">
            and t.b_id= #{bId}
        </if>
@@ -814,11 +839,11 @@
    <!-- 批量插入费用 -->
    <insert id="insertFees" parameterType="Map">
        insert into pay_fee (amount,status_cd,income_obj_id,fee_type_cd,secondary_fee_type_cd,start_time,end_time,community_id,b_id,fee_id,
        user_id,payer_obj_id,fee_flag,state,config_id,payer_obj_type,batch_id)
        user_id,payer_obj_id,fee_flag,state,config_id,payer_obj_type,batch_id,is_contract_fee)
        VALUES
        <foreach collection="payFeePos" item="item" separator=",">
            (#{item.amount},'0',#{item.incomeObjId},#{item.feeTypeCd},#{item.secondaryFeeTypeCd},#{item.startTime},#{item.endTime},#{item.communityId},
            '-1',#{item.feeId},#{item.userId},#{item.payerObjId},#{item.feeFlag},#{item.state},#{item.configId},#{item.payerObjType},#{item.batchId})
            '-1',#{item.feeId},#{item.userId},#{item.payerObjId},#{item.feeFlag},#{item.state},#{item.configId},#{item.payerObjType},#{item.batchId},#{item.isContractFee})
        </foreach>
    </insert>