Explorar o código

客户信息用水余额默认为0

wangli %!s(int64=4) %!d(string=hai) anos
pai
achega
8de4cc8625

+ 2 - 2
smart-city-platform/src/main/resources/application-prd.properties

@@ -53,13 +53,13 @@ spring.redis.jedis.pool.min-idle=2
 
 
 #============== kafka ===================
 #============== kafka ===================
 # 指定kafka 代理地址,可以多个
 # 指定kafka 代理地址,可以多个
-spring.kafka.bootstrap-servers=47.112.15.78:9092
+spring.kafka.bootstrap-servers=47.112.217.10:9092
 
 
 # 指定消费者group id
 # 指定消费者group id
 spring.kafka.consumer.group-id = water_api_jf_valveStatus_received
 spring.kafka.consumer.group-id = water_api_jf_valveStatus_received
 spring.kafka.consumer.auto-offset-reset=latest
 spring.kafka.consumer.auto-offset-reset=latest
 spring.kafka.consumer.enable-auto-commit=true
 spring.kafka.consumer.enable-auto-commit=true
-#spring.kafka.consumer.auto-commit-interval=100
+spring.kafka.consumer.auto-commit-interval=100
 
 
 # 指定消息key和消息体的编解码方式
 # 指定消息key和消息体的编解码方式
 spring.kafka.consumer.key-deserializer=org.apache.kafka.common.serialization.StringDeserializer
 spring.kafka.consumer.key-deserializer=org.apache.kafka.common.serialization.StringDeserializer

+ 2 - 2
smart-city-platform/src/main/resources/mapper/pay/PayBaseAccountMapper.xml

@@ -266,7 +266,7 @@
         IFNULL(paw.sum_payamount,0) sumPayamount,
         IFNULL(paw.sum_payamount,0) sumPayamount,
         pba.state as state,
         pba.state as state,
         (select label from pay_sys_dict where value = pba.state and type='客户状态' and site_id = #{siteId} and customer_id = #{customerId}) stateName,
         (select label from pay_sys_dict where value = pba.state and type='客户状态' and site_id = #{siteId} and customer_id = #{customerId}) stateName,
-        rech.balance as remaining,
+        IFNULL(rech.balance,0) as remaining,
         <!-- dt.remaining ,-->
         <!-- dt.remaining ,-->
         (select label from pay_sys_dict where value = pba.idtype and type='证件类型' and site_id = #{siteId} and customer_id = #{customerId}) idTypeName,
         (select label from pay_sys_dict where value = pba.idtype and type='证件类型' and site_id = #{siteId} and customer_id = #{customerId}) idTypeName,
         pba.accountnumber,
         pba.accountnumber,
@@ -560,7 +560,7 @@
         where b.reading > 0 and b.customer_id=#{customerId} and b.site_id=#{siteId}
         where b.reading > 0 and b.customer_id=#{customerId} and b.site_id=#{siteId}
         GROUP BY b.watermeter_id)
         GROUP BY b.watermeter_id)
         AS c WHERE a.watermeter_id=c.watermeter_id AND a.read_date = c.read_date)  rd on rd.watermeter_id = scd.id
         AS c WHERE a.watermeter_id=c.watermeter_id AND a.read_date = c.read_date)  rd on rd.watermeter_id = scd.id
-        where  scd.customer_id = #{customerId}
+        where  scd.customer_id = #{customerId}  and scd.account_id is not null
         <if test="queryInfo != null and queryInfo != ''">
         <if test="queryInfo != null and queryInfo != ''">
             and (
             and (
             scd.metercode like concat('%',#{queryInfo,jdbcType=VARCHAR} ,'%')
             scd.metercode like concat('%',#{queryInfo,jdbcType=VARCHAR} ,'%')

+ 4 - 4
smart-city-platform/src/main/resources/mapper/pay/payFeeMapper.xml

@@ -110,10 +110,10 @@
             c.opendate,
             c.opendate,
             c.metercode,
             c.metercode,
             c.watermeter_id as "watermeterId",
             c.watermeter_id as "watermeterId",
-            (select label from pay_sys_dict where type='住房类型' and `value`=c.housetype and site_id=#{siteId}
+            (select label from pay_sys_dict where type='住房类型' and `value`=c.housetype and customer_id=#{customerId} and site_id=#{siteId}
             and customer_id=#{customerId}) as "housetype",
             and customer_id=#{customerId}) as "housetype",
-            (select label from pay_sys_dict where type='结算方式' and `value`=c.calculateway and  site_id=#{siteId}
-            and customer_id=#{customerId}) as "calculateway",
+            (select label from pay_sys_dict where type='结算方式' and `value`=c.calculateway and customer_id=#{customerId} and  site_id=#{siteId}
+            ) as "calculateway",
 
 
             p.id as "waterPropertyId",
             p.id as "waterPropertyId",
             p.name as "waterPropertyName",
             p.name as "waterPropertyName",
@@ -124,7 +124,7 @@
         left join pay_base_waterproperty p on c.waterProperty_id=p.id
         left join pay_base_waterproperty p on c.waterProperty_id=p.id
         inner join sc_device device on c.watermeter_id=device.id  and device.customer_id =#{customerId}
         inner join sc_device device on c.watermeter_id=device.id  and device.customer_id =#{customerId}
         <where>
         <where>
-            c.businessstate=1 and c.site_id=#{siteId}
+            c.businessstate=1 and c.customer_id=#{customerId} and c.site_id=#{siteId}
             <if test="id != null and id != ''">
             <if test="id != null and id != ''">
                and  c.id= #{id}
                and  c.id= #{id}
             </if>
             </if>