From dd6687b118561100e1677e88a9c2f5842a54c531 Mon Sep 17 00:00:00 2001
From: jialh <1972868360@qq.com>
Date: 星期四, 16 四月 2026 18:14:14 +0800
Subject: [PATCH] 水电话费
---
java110-db/src/main/resources/mapper/fee/MeterWaterV1ServiceDaoImplMapper.xml | 366 ++++++++++++++++++++++++++++-----------------------
1 files changed, 200 insertions(+), 166 deletions(-)
diff --git a/java110-db/src/main/resources/mapper/fee/MeterWaterV1ServiceDaoImplMapper.xml b/java110-db/src/main/resources/mapper/fee/MeterWaterV1ServiceDaoImplMapper.xml
index 6ee9778..52aeb71 100644
--- a/java110-db/src/main/resources/mapper/fee/MeterWaterV1ServiceDaoImplMapper.xml
+++ b/java110-db/src/main/resources/mapper/fee/MeterWaterV1ServiceDaoImplMapper.xml
@@ -5,36 +5,52 @@
<!-- 淇濆瓨姘寸數鎶勮〃淇℃伅 add by wuxw 2018-07-03 -->
<insert id="saveMeterWaterInfo" parameterType="Map">
- insert into meter_water(remark, obj_name, fee_id, cur_reading_time, water_id, cur_degrees, price, meter_type,
- pre_degrees, obj_id, pre_reading_time, community_id, obj_type, b_id,
- power_supply_bureau, household_name, household_number, electric_meter_id, handler,
- is_transferred, company_name_after_transfer, transfer_date, corresponding_household_count,
- last_payment_date, reading_type, multiplying_factor, unit_price, invoice_amount,
- amount_difference, auto_deduction, remark2, address, write_time, writer,
- check_apply_company_name, check_apply_dept_project, water_fee_payer, account_number,
- meter_read_book_no, water_consumption, sewage_treatment_water, collection_standard,
- arrears_unpaid, late_payment_fine, late_payment_surcharge, fee_payment_status,
- carry_over_balance, total_payable_amount)
- values (#{remark}, #{objName}, #{feeId}, #{curReadingTime}, #{waterId}, #{curDegrees}, #{price}, #{meterType},
- #{preDegrees}, #{objId}, #{preReadingTime}, #{communityId}, #{objType}, #{bId},
- #{powerSupplyBureau}, #{householdName}, #{householdNumber}, #{electricMeterId}, #{handler},
- #{isTransferred}, #{companyNameAfterTransfer}, #{transferDate}, #{correspondingHouseholdCount},
- #{lastPaymentDate}, #{readingType}, #{multiplyingFactor}, #{unitPrice}, #{invoiceAmount},
- #{amountDifference}, #{autoDeduction}, #{remark2}, #{address}, #{writeTime}, #{writer},
- #{checkApplyCompanyName}, #{checkApplyDeptProject}, #{waterFeePayer}, #{accountNumber},
- #{meterReadBookNo}, #{waterConsumption}, #{sewageTreatmentWater}, #{collectionStandard},
- #{arrearsUnpaid}, #{latePaymentFine}, #{latePaymentSurcharge}, #{feePaymentStatus},
- #{carryOverBalance}, #{totalPayableAmount})
+ insert into meter_water(
+ water_id, b_id, meter_type, obj_type, obj_id, pre_degrees, cur_degrees,
+ pre_reading_time, cur_reading_time, community_id, create_time, status_cd,
+ remark, fee_id, obj_name, price, power_supply_bureau, household_name,
+ household_number, electric_meter_id, handler, is_transferred,
+ company_name_after_transfer, transfer_date, corresponding_household_count,
+ last_payment_date, reading_type, multiplying_factor, unit_price, invoice_amount,
+ amount_difference, auto_deduction, remark2, address, write_time, writer,
+ check_apply_company_name, check_apply_dept_project, water_fee_payer, account_number,
+ meter_read_book_no, water_consumption, sewage_treatment_water, collection_standard,
+ arrears_unpaid, late_payment_fine, late_payment_surcharge, fee_payment_status,
+ carry_over_balance, total_payable_amount
+ ) values (
+ #{waterId}, #{bId}, #{meterType}, #{objType}, #{objId}, #{preDegrees}, #{curDegrees},
+ #{preReadingTime}, #{curReadingTime}, #{communityId}, #{createTime}, #{statusCd},
+ #{remark}, #{feeId}, #{objName}, #{price}, #{powerSupplyBureau}, #{householdName},
+ #{householdNumber}, #{electricMeterId}, #{handler}, #{isTransferred},
+ #{companyNameAfterTransfer}, #{transferDate}, #{correspondingHouseholdCount},
+ #{lastPaymentDate}, #{readingType}, #{multiplyingFactor}, #{unitPrice}, #{invoiceAmount},
+ #{amountDifference}, #{autoDeduction}, #{remark2}, #{address}, #{writeTime}, #{writer},
+ #{checkApplyCompanyName}, #{checkApplyDeptProject}, #{waterFeePayer}, #{accountNumber},
+ #{meterReadBookNo}, #{waterConsumption}, #{sewageTreatmentWater}, #{collectionStandard},
+ #{arrearsUnpaid}, #{latePaymentFine}, #{latePaymentSurcharge}, #{feePaymentStatus},
+ #{carryOverBalance}, #{totalPayableAmount}
+ )
</insert>
<!-- 鏌ヨ姘寸數鎶勮〃淇℃伅 add by wuxw 2018-07-03 -->
<select id="getMeterWaterInfo" parameterType="Map" resultType="Map">
- select t.status_cd,t.status_cd statusCd,t.remark,t.obj_name,t.obj_name objName,t.fee_id,t.fee_id feeId,
- t.cur_reading_time,t.cur_reading_time curReadingTime,t.water_id,t.water_id waterId,
- t.cur_degrees,t.cur_degrees curDegrees,t.price,t.meter_type,t.meter_type meterType,
- t.pre_degrees,t.pre_degrees preDegrees,t.obj_id,t.obj_id objId,t.pre_reading_time,
- t.pre_reading_time preReadingTime,t.community_id,t.community_id communityId,t.obj_type,
+ select
+ t.water_id waterId,
+ t.b_id bId,
+ t.meter_type meterType,
t.obj_type objType,
+ t.obj_id objId,
+ t.pre_degrees preDegrees,
+ t.cur_degrees curDegrees,
+ t.pre_reading_time preReadingTime,
+ t.cur_reading_time curReadingTime,
+ t.community_id communityId,
+ t.create_time createTime,
+ t.status_cd statusCd,
+ t.remark remark,
+ t.fee_id feeId,
+ t.obj_name objName,
+ t.price price,
t.power_supply_bureau powerSupplyBureau,
t.household_name householdName,
t.household_number householdNumber,
@@ -71,49 +87,54 @@
t.total_payable_amount totalPayableAmount
from meter_water t
where 1 =1
+ <if test="waterId !=null and waterId != ''">
+ and t.water_id= #{waterId}
+ </if>
+ <if test="bId !=null and bId != ''">
+ and t.b_id= #{bId}
+ </if>
+ <if test="meterType !=null and meterType != ''">
+ and t.meter_type= #{meterType}
+ </if>
+ <if test="objType !=null and objType != ''">
+ and t.obj_type= #{objType}
+ </if>
+ <if test="objId !=null and objId != ''">
+ and t.obj_id= #{objId}
+ </if>
+ <if test="preDegrees !=null and preDegrees != ''">
+ and t.pre_degrees= #{preDegrees}
+ </if>
+ <if test="curDegrees !=null and curDegrees != ''">
+ and t.cur_degrees= #{curDegrees}
+ </if>
+ <if test="preReadingTime !=null ">
+ and t.pre_reading_time= #{preReadingTime}
+ </if>
+ <if test="curReadingTime !=null ">
+ and t.cur_reading_time= #{curReadingTime}
+ </if>
+ <if test="communityId !=null and communityId != ''">
+ and t.community_id= #{communityId}
+ </if>
+ <if test="createTime !=null ">
+ and t.create_time= #{createTime}
+ </if>
<if test="statusCd !=null and statusCd != ''">
and t.status_cd= #{statusCd}
</if>
<if test="remark !=null and remark != ''">
and t.remark= #{remark}
</if>
- <if test="objName !=null and objName != ''">
- and t.obj_name= #{objName}
- </if>
<if test="feeId !=null and feeId != ''">
and t.fee_id= #{feeId}
</if>
- <if test="curReadingTime !=null and curReadingTime != ''">
- and t.cur_reading_time= #{curReadingTime}
- </if>
- <if test="waterId !=null and waterId != ''">
- and t.water_id= #{waterId}
- </if>
- <if test="curDegrees !=null and curDegrees != ''">
- and t.cur_degrees= #{curDegrees}
+ <if test="objName !=null and objName != ''">
+ and t.obj_name= #{objName}
</if>
<if test="price !=null and price != ''">
and t.price= #{price}
</if>
- <if test="meterType !=null and meterType != ''">
- and t.meter_type= #{meterType}
- </if>
- <if test="preDegrees !=null and preDegrees != ''">
- and t.pre_degrees= #{preDegrees}
- </if>
- <if test="objId !=null and objId != ''">
- and t.obj_id= #{objId}
- </if>
- <if test="preReadingTime !=null and preReadingTime != ''">
- and t.pre_reading_time= #{preReadingTime}
- </if>
- <if test="communityId !=null and communityId != ''">
- and t.community_id= #{communityId}
- </if>
- <if test="objType !=null and objType != ''">
- and t.obj_type= #{objType}
- </if>
- <!-- 鏂板瓧娈垫煡璇㈡潯浠� -->
<if test="powerSupplyBureau !=null and powerSupplyBureau != ''">
and t.power_supply_bureau= #{powerSupplyBureau}
</if>
@@ -135,13 +156,13 @@
<if test="companyNameAfterTransfer !=null and companyNameAfterTransfer != ''">
and t.company_name_after_transfer= #{companyNameAfterTransfer}
</if>
- <if test="transferDate !=null and transferDate != ''">
+ <if test="transferDate !=null ">
and t.transfer_date= #{transferDate}
</if>
<if test="correspondingHouseholdCount !=null and correspondingHouseholdCount != ''">
and t.corresponding_household_count= #{correspondingHouseholdCount}
</if>
- <if test="lastPaymentDate !=null and lastPaymentDate != ''">
+ <if test="lastPaymentDate !=null ">
and t.last_payment_date= #{lastPaymentDate}
</if>
<if test="readingType !=null and readingType != ''">
@@ -168,7 +189,7 @@
<if test="address !=null and address != ''">
and t.address= #{address}
</if>
- <if test="writeTime !=null and writeTime != ''">
+ <if test="writeTime !=null ">
and t.write_time= #{writeTime}
</if>
<if test="writer !=null and writer != ''">
@@ -224,148 +245,156 @@
<!-- 淇敼姘寸數鎶勮〃淇℃伅 add by wuxw 2018-07-03 -->
<update id="updateMeterWaterInfo" parameterType="Map">
- update meter_water t set t.status_cd = #{statusCd}
- <if test="newBId != null and newBId != ''">
- ,t.b_id = #{newBId}
+ update meter_water t set
+ <if test="waterId !=null and waterId != ''">
+ t.water_id = #{waterId},
</if>
- <if test="remark !=null and remark != ''">
- , t.remark= #{remark}
- </if>
- <if test="objName !=null and objName != ''">
- , t.obj_name= #{objName}
- </if>
- <if test="feeId !=null and feeId != ''">
- , t.fee_id= #{feeId}
- </if>
- <if test="curReadingTime !=null and curReadingTime != ''">
- , t.cur_reading_time= #{curReadingTime}
- </if>
- <if test="curDegrees !=null and curDegrees != ''">
- , t.cur_degrees= #{curDegrees}
- </if>
- <if test="price !=null and price != ''">
- , t.price= #{price}
+ <if test="bId !=null and bId != ''">
+ t.b_id = #{bId},
</if>
<if test="meterType !=null and meterType != ''">
- , t.meter_type= #{meterType}
- </if>
- <if test="preDegrees !=null and preDegrees != ''">
- , t.pre_degrees= #{preDegrees}
- </if>
- <if test="objId !=null and objId != ''">
- , t.obj_id= #{objId}
- </if>
- <if test="preReadingTime !=null and preReadingTime != ''">
- , t.pre_reading_time= #{preReadingTime}
- </if>
- <if test="communityId !=null and communityId != ''">
- , t.community_id= #{communityId}
+ t.meter_type = #{meterType},
</if>
<if test="objType !=null and objType != ''">
- , t.obj_type= #{objType}
+ t.obj_type = #{objType},
</if>
- <!-- 鏂板瓧娈典慨鏀归�昏緫 -->
+ <if test="objId !=null and objId != ''">
+ t.obj_id = #{objId},
+ </if>
+ <if test="preDegrees !=null and preDegrees != ''">
+ t.pre_degrees = #{preDegrees},
+ </if>
+ <if test="curDegrees !=null and curDegrees != ''">
+ t.cur_degrees = #{curDegrees},
+ </if>
+ <if test="preReadingTime !=null ">
+ t.pre_reading_time = #{preReadingTime},
+ </if>
+ <if test="curReadingTime !=null ">
+ t.cur_reading_time = #{curReadingTime},
+ </if>
+ <if test="communityId !=null and communityId != ''">
+ t.community_id = #{communityId},
+ </if>
+ <if test="createTime !=null ">
+ t.create_time = #{createTime},
+ </if>
+ <if test="statusCd !=null and statusCd != ''">
+ t.status_cd = #{statusCd},
+ </if>
+ <if test="remark !=null and remark != ''">
+ t.remark = #{remark},
+ </if>
+ <if test="feeId !=null and feeId != ''">
+ t.fee_id = #{feeId},
+ </if>
+ <if test="objName !=null and objName != ''">
+ t.obj_name = #{objName},
+ </if>
+ <if test="price !=null and price != ''">
+ t.price = #{price},
+ </if>
<if test="powerSupplyBureau !=null and powerSupplyBureau != ''">
- , t.power_supply_bureau= #{powerSupplyBureau}
+ t.power_supply_bureau = #{powerSupplyBureau},
</if>
<if test="householdName !=null and householdName != ''">
- , t.household_name= #{householdName}
+ t.household_name = #{householdName},
</if>
<if test="householdNumber !=null and householdNumber != ''">
- , t.household_number= #{householdNumber}
+ t.household_number = #{householdNumber},
</if>
<if test="electricMeterId !=null and electricMeterId != ''">
- , t.electric_meter_id= #{electricMeterId}
+ t.electric_meter_id = #{electricMeterId},
</if>
<if test="handler !=null and handler != ''">
- , t.handler= #{handler}
+ t.handler = #{handler},
</if>
<if test="isTransferred !=null and isTransferred != ''">
- , t.is_transferred= #{isTransferred}
+ t.is_transferred = #{isTransferred},
</if>
<if test="companyNameAfterTransfer !=null and companyNameAfterTransfer != ''">
- , t.company_name_after_transfer= #{companyNameAfterTransfer}
+ t.company_name_after_transfer = #{companyNameAfterTransfer},
</if>
- <if test="transferDate !=null and transferDate != ''">
- , t.transfer_date= #{transferDate}
+ <if test="transferDate !=null ">
+ t.transfer_date = #{transferDate},
</if>
<if test="correspondingHouseholdCount !=null and correspondingHouseholdCount != ''">
- , t.corresponding_household_count= #{correspondingHouseholdCount}
+ t.corresponding_household_count = #{correspondingHouseholdCount},
</if>
- <if test="lastPaymentDate !=null and lastPaymentDate != ''">
- , t.last_payment_date= #{lastPaymentDate}
+ <if test="lastPaymentDate !=null ">
+ t.last_payment_date = #{lastPaymentDate},
</if>
<if test="readingType !=null and readingType != ''">
- , t.reading_type= #{readingType}
+ t.reading_type = #{readingType},
</if>
<if test="multiplyingFactor !=null and multiplyingFactor != ''">
- , t.multiplying_factor= #{multiplyingFactor}
+ t.multiplying_factor = #{multiplyingFactor},
</if>
<if test="unitPrice !=null and unitPrice != ''">
- , t.unit_price= #{unitPrice}
+ t.unit_price = #{unitPrice},
</if>
<if test="invoiceAmount !=null and invoiceAmount != ''">
- , t.invoice_amount= #{invoiceAmount}
+ t.invoice_amount = #{invoiceAmount},
</if>
<if test="amountDifference !=null and amountDifference != ''">
- , t.amount_difference= #{amountDifference}
+ t.amount_difference = #{amountDifference},
</if>
<if test="autoDeduction !=null and autoDeduction != ''">
- , t.auto_deduction= #{autoDeduction}
+ t.auto_deduction = #{autoDeduction},
</if>
<if test="remark2 !=null and remark2 != ''">
- , t.remark2= #{remark2}
+ t.remark2 = #{remark2},
</if>
<if test="address !=null and address != ''">
- , t.address= #{address}
+ t.address = #{address},
</if>
- <if test="writeTime !=null and writeTime != ''">
- , t.write_time= #{writeTime}
+ <if test="writeTime !=null ">
+ t.write_time = #{writeTime},
</if>
<if test="writer !=null and writer != ''">
- , t.writer= #{writer}
+ t.writer = #{writer},
</if>
<if test="checkApplyCompanyName !=null and checkApplyCompanyName != ''">
- , t.check_apply_company_name= #{checkApplyCompanyName}
+ t.check_apply_company_name = #{checkApplyCompanyName},
</if>
<if test="checkApplyDeptProject !=null and checkApplyDeptProject != ''">
- , t.check_apply_dept_project= #{checkApplyDeptProject}
+ t.check_apply_dept_project = #{checkApplyDeptProject},
</if>
<if test="waterFeePayer !=null and waterFeePayer != ''">
- , t.water_fee_payer= #{waterFeePayer}
+ t.water_fee_payer = #{waterFeePayer},
</if>
<if test="accountNumber !=null and accountNumber != ''">
- , t.account_number= #{accountNumber}
+ t.account_number = #{accountNumber},
</if>
<if test="meterReadBookNo !=null and meterReadBookNo != ''">
- , t.meter_read_book_no= #{meterReadBookNo}
+ t.meter_read_book_no = #{meterReadBookNo},
</if>
<if test="waterConsumption !=null and waterConsumption != ''">
- , t.water_consumption= #{waterConsumption}
+ t.water_consumption = #{waterConsumption},
</if>
<if test="sewageTreatmentWater !=null and sewageTreatmentWater != ''">
- , t.sewage_treatment_water= #{sewageTreatmentWater}
+ t.sewage_treatment_water = #{sewageTreatmentWater},
</if>
<if test="collectionStandard !=null and collectionStandard != ''">
- , t.collection_standard= #{collectionStandard}
+ t.collection_standard = #{collectionStandard},
</if>
<if test="arrearsUnpaid !=null and arrearsUnpaid != ''">
- , t.arrears_unpaid= #{arrearsUnpaid}
+ t.arrears_unpaid = #{arrearsUnpaid},
</if>
<if test="latePaymentFine !=null and latePaymentFine != ''">
- , t.late_payment_fine= #{latePaymentFine}
+ t.late_payment_fine = #{latePaymentFine},
</if>
<if test="latePaymentSurcharge !=null and latePaymentSurcharge != ''">
- , t.late_payment_surcharge= #{latePaymentSurcharge}
+ t.late_payment_surcharge = #{latePaymentSurcharge},
</if>
<if test="feePaymentStatus !=null and feePaymentStatus != ''">
- , t.fee_payment_status= #{feePaymentStatus}
+ t.fee_payment_status = #{feePaymentStatus},
</if>
<if test="carryOverBalance !=null and carryOverBalance != ''">
- , t.carry_over_balance= #{carryOverBalance}
+ t.carry_over_balance = #{carryOverBalance},
</if>
<if test="totalPayableAmount !=null and totalPayableAmount != ''">
- , t.total_payable_amount= #{totalPayableAmount}
+ t.total_payable_amount = #{totalPayableAmount}
</if>
where 1=1
<if test="waterId !=null and waterId != ''">
@@ -378,49 +407,54 @@
select count(1) count
from meter_water t
where 1 =1
+ <if test="waterId !=null and waterId != ''">
+ and t.water_id= #{waterId}
+ </if>
+ <if test="bId !=null and bId != ''">
+ and t.b_id= #{bId}
+ </if>
+ <if test="meterType !=null and meterType != ''">
+ and t.meter_type= #{meterType}
+ </if>
+ <if test="objType !=null and objType != ''">
+ and t.obj_type= #{objType}
+ </if>
+ <if test="objId !=null and objId != ''">
+ and t.obj_id= #{objId}
+ </if>
+ <if test="preDegrees !=null and preDegrees != ''">
+ and t.pre_degrees= #{preDegrees}
+ </if>
+ <if test="curDegrees !=null and curDegrees != ''">
+ and t.cur_degrees= #{curDegrees}
+ </if>
+ <if test="preReadingTime !=null ">
+ and t.pre_reading_time= #{preReadingTime}
+ </if>
+ <if test="curReadingTime !=null ">
+ and t.cur_reading_time= #{curReadingTime}
+ </if>
+ <if test="communityId !=null and communityId != ''">
+ and t.community_id= #{communityId}
+ </if>
+ <if test="createTime !=null ">
+ and t.create_time= #{createTime}
+ </if>
<if test="statusCd !=null and statusCd != ''">
and t.status_cd= #{statusCd}
</if>
<if test="remark !=null and remark != ''">
and t.remark= #{remark}
</if>
- <if test="objName !=null and objName != ''">
- and t.obj_name= #{objName}
- </if>
<if test="feeId !=null and feeId != ''">
and t.fee_id= #{feeId}
</if>
- <if test="curReadingTime !=null and curReadingTime != ''">
- and t.cur_reading_time= #{curReadingTime}
- </if>
- <if test="waterId !=null and waterId != ''">
- and t.water_id= #{waterId}
- </if>
- <if test="curDegrees !=null and curDegrees != ''">
- and t.cur_degrees= #{curDegrees}
+ <if test="objName !=null and objName != ''">
+ and t.obj_name= #{objName}
</if>
<if test="price !=null and price != ''">
and t.price= #{price}
</if>
- <if test="meterType !=null and meterType != ''">
- and t.meter_type= #{meterType}
- </if>
- <if test="preDegrees !=null and preDegrees != ''">
- and t.pre_degrees= #{preDegrees}
- </if>
- <if test="objId !=null and objId != ''">
- and t.obj_id= #{objId}
- </if>
- <if test="preReadingTime !=null and preReadingTime != ''">
- and t.pre_reading_time= #{preReadingTime}
- </if>
- <if test="communityId !=null and communityId != ''">
- and t.community_id= #{communityId}
- </if>
- <if test="objType !=null and objType != ''">
- and t.obj_type= #{objType}
- </if>
- <!-- 鏂板瓧娈垫暟閲忔煡璇㈡潯浠� -->
<if test="powerSupplyBureau !=null and powerSupplyBureau != ''">
and t.power_supply_bureau= #{powerSupplyBureau}
</if>
@@ -442,13 +476,13 @@
<if test="companyNameAfterTransfer !=null and companyNameAfterTransfer != ''">
and t.company_name_after_transfer= #{companyNameAfterTransfer}
</if>
- <if test="transferDate !=null and transferDate != ''">
+ <if test="transferDate !=null ">
and t.transfer_date= #{transferDate}
</if>
<if test="correspondingHouseholdCount !=null and correspondingHouseholdCount != ''">
and t.corresponding_household_count= #{correspondingHouseholdCount}
</if>
- <if test="lastPaymentDate !=null and lastPaymentDate != ''">
+ <if test="lastPaymentDate !=null ">
and t.last_payment_date= #{lastPaymentDate}
</if>
<if test="readingType !=null and readingType != ''">
@@ -475,7 +509,7 @@
<if test="address !=null and address != ''">
and t.address= #{address}
</if>
- <if test="writeTime !=null and writeTime != ''">
+ <if test="writeTime !=null ">
and t.write_time= #{writeTime}
</if>
<if test="writer !=null and writer != ''">
@@ -528,8 +562,8 @@
<update id="deleteMeterWaterByBatch" parameterType="Map">
update meter_water t,pay_fee pf set t.status_cd = '1'
where
- t.fee_id = pf.fee_id
- and pf.batch_id = #{batchId}
- and pf.community_id = #{communityId}
+ t.fee_id = pf.fee_id
+ and pf.batch_id = #{batchId}
+ and pf.community_id = #{communityId}
</update>
</mapper>
\ No newline at end of file
--
Gitblit v1.8.0