Преглед на файлове

修改统计接口,增加查询条件

Administrator преди 2 години
родител
ревизия
2ef1e26467

+ 10 - 1
ruoyi-system/src/main/java/com/ruoyi/system/service/impl/projectV2/common/ZsyzCommonServiceImpL.java

@@ -220,7 +220,16 @@ public class ZsyzCommonServiceImpL implements IZsyzCommonService {
         map.put("tc", tc);
         map.put("sk", sk);
         //todo 问题项目  只有要素部门意见不通过和承接地不承接的是问题项目
-        List<ZsyzShyj> zsyzShyjs = zsyzShyjService.selectZsyzShyjListByWt(new ZsyzShyj());
+        ZsyzShyj zsyzShyj = new ZsyzShyj();
+        String xmxsmc = zsyzSbbzb.getXmxsmc();
+        if(StringUtils.isNotEmpty(xmxsmc)){
+            zsyzShyj.setXmmc(xmxsmc);
+        }
+        Map<String, Object> params = zsyzSbbzb.getParams();
+        if (params != null && params.size() > 0){
+            zsyzShyj.setParams(params);
+        }
+        List<ZsyzShyj> zsyzShyjs = zsyzShyjService.selectZsyzShyjListByWt(zsyzShyj);
         int wt = 0;
         if (zsyzShyjs != null) {
             wt = zsyzShyjs.size();

+ 10 - 10
ruoyi-system/src/main/resources/mapper/system/projectV2/ZsyzShyjMapper.xml

@@ -72,7 +72,7 @@
     </select>
 
 
-<!--    <select id="selectZsyzShyjListByWt" resultMap="ZsyzShyjResult">
+    <select id="selectZsyzShyjListByWt" resultMap="ZsyzShyjResult">
         SELECT
         ANY_VALUE ( s.id ) as id,
         ANY_VALUE ( s.xm_id ) as xm_id ,
@@ -89,20 +89,20 @@
         <where>
             s.shjg = '2'
             <if test="xmmc != null  and xmmc != ''">and s.xmmc like concat( #{xmmc}, '%') </if>
-            <if test="params.beginTime != null and params.beginTime != ''">&lt;!&ndash; 开始时间检索 &ndash;&gt;
+            <if test="params.beginTime != null and params.beginTime != ''"><!-- 开始时间检索 -->
                 AND date_format(s.create_time,'%Y%m%d') &gt;= date_format(#{params.beginTime},'%Y%m%d')
             </if>
-            <if test="params.endTime != null and params.endTime != ''">&lt;!&ndash; 结束时间检索 &ndash;&gt;
+            <if test="params.endTime != null and params.endTime != ''"><!-- 结束时间检索 -->
                 AND date_format(s.create_time,'%Y%m%d') &lt;= date_format(#{params.endTime},'%Y%m%d')
             </if>
         </where>
-        &lt;!&ndash; 数据范围过滤 &ndash;&gt;
+        <!-- 数据范围过滤 -->
         ${params.dataScope}
         GROUP BY
         s.xm_id
-    </select>-->
+    </select>
 
-    <select id="selectZsyzShyjListByWt" resultMap="ZsyzShyjResult">
+<!--    <select id="selectZsyzShyjListByWt" resultMap="ZsyzShyjResult">
         SELECT
         id,
         xm_id ,
@@ -119,18 +119,18 @@
         <where>
             shjg = '2'
             <if test="xmmc != null  and xmmc != ''">and xmmc like concat( #{xmmc}, '%') </if>
-            <if test="params.beginTime != null and params.beginTime != ''"><!-- 开始时间检索 -->
+            <if test="params.beginTime != null and params.beginTime != ''">&lt;!&ndash; 开始时间检索 &ndash;&gt;
                 AND date_format(s.create_time,'%Y%m%d') &gt;= date_format(#{params.beginTime},'%Y%m%d')
             </if>
-            <if test="params.endTime != null and params.endTime != ''"><!-- 结束时间检索 -->
+            <if test="params.endTime != null and params.endTime != ''">&lt;!&ndash; 结束时间检索 &ndash;&gt;
                 AND date_format(s.create_time,'%Y%m%d') &lt;= date_format(#{params.endTime},'%Y%m%d')
             </if>
         </where>
-        <!-- 数据范围过滤 -->
+        &lt;!&ndash; 数据范围过滤 &ndash;&gt;
         ${params.dataScope}
         GROUP BY
         xm_id
-    </select>
+    </select>-->
 
     <insert id="insertZsyzShyj" parameterType="ZsyzShyj" useGeneratedKeys="true" keyProperty="id">
         insert into zsyz_shyj