From f14c50cb0036d3ddd655ce4e34732ba396a836c4 Mon Sep 17 00:00:00 2001
From: java110 <928255095@qq.com>
Date: 星期二, 30 五月 2023 12:42:03 +0800
Subject: [PATCH] optimize 统计

---
 java110-db/src/main/resources/mapper/common/ChargeRuleFeeV1ServiceDaoImplMapper.xml |    6 +++++-
 1 files changed, 5 insertions(+), 1 deletions(-)

diff --git a/java110-db/src/main/resources/mapper/common/ChargeRuleFeeV1ServiceDaoImplMapper.xml b/java110-db/src/main/resources/mapper/common/ChargeRuleFeeV1ServiceDaoImplMapper.xml
index abe8a54..d665b6b 100644
--- a/java110-db/src/main/resources/mapper/common/ChargeRuleFeeV1ServiceDaoImplMapper.xml
+++ b/java110-db/src/main/resources/mapper/common/ChargeRuleFeeV1ServiceDaoImplMapper.xml
@@ -43,10 +43,14 @@
         <if test="minEnergyPrice !=null and minEnergyPrice != ''">
             and t.min_energy_price= #{minEnergyPrice}
         </if>
+        <if test="energy !=null and energy != ''">
+            and t.min_energy_price &lt;= #{energy}
+            and t.max_energy_price &gt; #{energy}
+        </if>
         <if test="communityId !=null and communityId != ''">
             and t.community_id= #{communityId}
         </if>
-        order by t.create_time desc
+        order by t.duration_price
         <if test="page != -1 and page != null ">
             limit #{page}, #{row}
         </if>

--
Gitblit v1.8.0