Преглед изворни кода

投资效益系统-查询添加是否删除条件

LHB пре 4 месеци
родитељ
комит
18566c201a

+ 2 - 2
src/main/java/org/springblade/modules/investment/mapper/IbaProjectMapper.xml

@@ -133,7 +133,7 @@
                     IFNULL(( b.toll_inflow + b.other_inflow ), 0 ) inflow
                 FROM
                     iba_project a
-                        LEFT JOIN iba_project_fund b ON a.id = b.project_id
+                        LEFT JOIN iba_project_fund b ON a.id = b.project_id and b.is_deleted = 0
                 <where>
                     <if test="year != null and year != ''">
                         b.year = #{year}
@@ -160,7 +160,7 @@
             b.*
         FROM
             iba_project a
-                LEFT JOIN iba_project_volume b ON a.id = b.project_id
+                LEFT JOIN iba_project_volume b ON a.id = b.project_id and b.is_deleted = 0
         <where>
             <choose>
                 <when test="type == 1">

+ 1 - 1
src/main/java/org/springblade/modules/investment/mapper/IbaProjectVolumeMapper.xml

@@ -36,7 +36,7 @@
     </update>
     <select id="selectGroupYearList"
             resultMap="groupYear">
-        select `year`,`month` from iba_project_volume where project_id = #{id}
+        select `year`,`month` from iba_project_volume where project_id = #{id} and is_deleted = 0
         group by year, month
         order by year, month
     </select>