瀏覽代碼

修改开户联想功能

hym 3 年之前
父節點
當前提交
f93ba9e5cf

+ 1 - 1
zoniot-pay/zoniot-pay-core/src/main/java/com/zcxk/rmcp/pay/dao/pay/archives/PayBaseCustomerandmeterrelaMapper.java

@@ -60,7 +60,7 @@ public interface PayBaseCustomerandmeterrelaMapper {
 
     public List<DeviceListInfo> queryNoOpenAccount(@Param("siteId") Integer siteId, @Param("customerId") Integer customerId);
 
-    public List<MeterListInfo> selectAccountInfo(@Param("siteId") Integer siteId, @Param("customerId") Integer customerId, @Param("accountnumber") String accountnumber);
+    public List<MeterListInfo> selectAccountInfo(@Param("tenantId") String tenantId, @Param("accountnumber") String accountnumber);
 
     List<CustomerListInfo> selectAccountWater(@Param("tenantId") String tenantId, @Param("accountnumber") String accountnumber);
 

+ 2 - 7
zoniot-pay/zoniot-pay-core/src/main/resources/mapper/PayBaseCustomerandmeterrelaMapper.xml

@@ -429,18 +429,13 @@
         account.telephone as telephone,
         account.idcardno as idcardno
         from pay_base_account account
-        inner join sc_device device on account.id = device.account_id and device.customer_id  = #{customerId}
+        inner join sc_device device on account.id = device.account_id and device.tenant_id  = #{tenantId}
         <where>
             device.metercode not in(select metercode from pay_base_customerandmeterrela where businessstate = '1')
             <if test="accountnumber != null">
                 and account.accountnumber =#{accountnumber}
             </if>
-            <!-- <if test="siteId != null">
-                 and  account.site_id = #{siteId}
-             </if>-->
-            <if test="customerId != null">
-                and account.customer_id = #{customerId}
-            </if>
+
             order by account.create_date desc
         </where>
     </select>

+ 1 - 1
zoniot-pay/zoniot-pay-web/src/main/java/com/zcxk/rmcp/pay/service/pay/archives/impl/PayBaseCustomerandmeterrelaServiceImpl.java

@@ -160,7 +160,7 @@ public class PayBaseCustomerandmeterrelaServiceImpl implements PayBaseCustomeran
         if(accountList != null && accountList.size() > 0){
             for(int i=0; i<accountList.size(); i++){
                 String numbers = accountList.get(i) != null && accountList.get(i).getAccountnumber() != null ? accountList.get(i).getAccountnumber() : "";
-                codeList = payBaseCustomerandmeterrelaMapper.selectAccountInfo(loginUser.getSiteId(),loginUser.getCustomerId(),numbers);
+                codeList = payBaseCustomerandmeterrelaMapper.selectAccountInfo(loginUser.getTenantId(),numbers);
                 accountList.get(i).setMetercodeList(codeList);
             }
         }