瀏覽代碼

【CHG】修改查询条件

zhaomn 2 年之前
父節點
當前提交
91a8807ada

+ 4 - 4
railway-business/src/main/java/com/railway/business/bi/domain/vo/BpdjxjhQuery.java

@@ -21,11 +21,11 @@ public class BpdjxjhQuery implements Serializable {
 
   @ApiModelProperty(value = "线路信息")
   @Length(min = 1, max = 255, message = "【线路信息】长度必须介于 {min} 和 {max} 之间")
-  private String linName;
+  private String lineName;
 
-  @ApiModelProperty(value = "所")
-  @Length(min = 1, max = 64, message = "【所别】长度必须介于 {min} 和 {max} 之间")
-  private String substation;
+  @ApiModelProperty(value = "所亭名称")
+  @Length(min = 1, max = 255, message = "【所亭名称】长度必须介于 {min} 和 {max} 之间")
+  private String substationName;
 
   @ApiModelProperty(value = "计划月")
   @Length(min = 1, max = 16, message = "【计划月】长度必须介于 {min} 和 {max} 之间")

+ 12 - 0
railway-business/src/main/resources/mapper/bi/ShowBdycMapper.xml

@@ -230,6 +230,18 @@
         and sjgq=(select dict_label from sys_dict_data where dict_type='dlyc_sygq' and
         dict_value=#{ssgq})
       </if>
+      <if test="lineName!=null and lineName!=''">
+        and line_name like concat('%', #{lineName}, '%')
+      </if>
+      <if test="zrbm!=null and zrbm!=''">
+        and zrbm like concat('%', #{zrbm}, '%')
+      </if>
+      <if test="rectifyResult!=null and rectifyResult!=''">
+        and rectify_result like concat('%', #{rectifyResult}, '%')
+      </if>
+      <if test="fileId!=null ">
+        and file_id=#{fileId}
+      </if>
     </where>
   </select>
 

+ 3 - 15
railway-business/src/main/resources/mapper/bi/ShowBpdjxjhMapper.xml

@@ -150,27 +150,15 @@
     FROM show_bpdjxjh
     <where>
       del_flag='0'
-      <if test="linName!=null and linName!=''">
-        and lin_name=#{linName}
-      </if>
-      <if test="substation!=null and substation!=''">
-        and substation=#{substation}
+      <if test="lineName!=null and lineName!=''">
+        and lin_name like concat('%', #{lineName}, '%')
       </if>
       <if test="substationName!=null and substationName!=''">
-        and substation_name=#{substationName}
+        and substation_name like concat('%', #{substationName}, '%')
       </if>
       <if test="jhMonth!=null and jhMonth!=''">
         and jh_month=#{jhMonth}
       </if>
-      <if test="jhDay!=null and jhDay!=''">
-        and jh_day=#{jhDay}
-      </if>
-      <if test="completionState!=null and completionState!=''">
-        and completion_state=#{completionState}
-      </if>
-      <if test="completionDate!=null and completionDate!=''">
-        and completion_date=#{completionDate}
-      </if>
       <if test="fileId!=null ">
         and file_id=#{fileId}
       </if>

+ 9 - 0
railway-business/src/main/resources/mapper/bi/ShowDlycMapper.xml

@@ -222,6 +222,15 @@
         and ssgq=(select dict_label from sys_dict_data where dict_type='dlyc_sygq' and
         dict_value=#{ssgq})
       </if>
+      <if test="lineName!=null and lineName!=''">
+        and line_name like concat('%', #{lineName}, '%')
+      </if>
+      <if test="rectifyResult!=null and rectifyResult!=''">
+        and rectify_result like concat('%', #{rectifyResult}, '%')
+      </if>
+      <if test="fileId!=null ">
+        and file_id=#{fileId}
+      </if>
     </where>
   </select>
 

+ 1 - 46
railway-business/src/main/resources/mapper/bi/ShowGsdMapper.xml

@@ -239,57 +239,12 @@
     FROM show_gsd
     <where>
       del_flag='0'
-      <if test="deptName!=null and deptName!=''">
-        and dept_name=#{deptName}
-      </if>
-      <if test="lineId!=null and lineId!=''">
-        and line_id=#{lineId}
-      </if>
-      <if test="lineName!=null and lineName!=''">
-        and line_name=#{lineName}
-      </if>
-      <if test="jkxl!=null and jkxl!=''">
-        and jkxl=#{jkxl}
-      </if>
-      <if test="dlxl!=null and dlxl!=''">
-        and dlxl=#{dlxl}
-      </if>
-      <if test="glkg!=null and glkg!=''">
-        and glkg=#{glkg}
-      </if>
-      <if test="dlq!=null and dlq!=''">
-        and dlq=#{dlq}
-      </if>
-      <if test="dljt!=null and dljt!=''">
-        and dljt=#{dljt}
-      </if>
-      <if test="dlj!=null and dlj!=''">
-        and dlj=#{dlj}
-      </if>
-      <if test="jxx!=null and jxx!=''">
-        and jxx=#{jxx}
-      </if>
       <if test="wxfs!=null and wxfs!=''">
-        and wxfs=#{wxfs}
-      </if>
-      <if test="lastTestYear!=null and lastTestYear!=''">
-        and last_test_year=#{lastTestYear}
+        and wxfs like concat('%', #{wxfs}, '%')
       </if>
       <if test="planMonth!=null and planMonth!=''">
         and plan_month=#{planMonth}
       </if>
-      <if test="overdueReminder!=null and overdueReminder!=''">
-        and overdue_reminder=#{overdueReminder}
-      </if>
-      <if test="completionDate!=null and completionDate!=''">
-        and completion_date=#{completionDate}
-      </if>
-      <if test="planChangeDesc!=null and planChangeDesc!=''">
-        and plan_change_desc=#{planChangeDesc}
-      </if>
-      <if test="overdueReason!=null and overdueReason!=''">
-        and overdue_reason=#{overdueReason}
-      </if>
       <if test="fileId!=null ">
         and file_id=#{fileId}
       </if>

+ 1 - 34
railway-business/src/main/resources/mapper/bi/ShowGsyMapper.xml

@@ -204,45 +204,12 @@
     FROM show_gsy
     <where>
       del_flag='0'
-      <if test="deptName!=null and deptName!=''">
-        and dept_name=#{deptName}
-      </if>
-      <if test="lineName!=null and lineName!=''">
-        and line_name=#{lineName}
-      </if>
-      <if test="substationName!=null and substationName!=''">
-        and substation_name=#{substationName}
-      </if>
-      <if test="bhlx!=null and bhlx!=''">
-        and bhlx=#{bhlx}
-      </if>
-      <if test="lastTestYear!=null and lastTestYear!=''">
-        and last_test_year=#{lastTestYear}
-      </if>
       <if test="testPlan1!=null and testPlan1!=''">
-        and test_plan1=#{testPlan1}
-      </if>
-      <if test="testPlan2!=null and testPlan2!=''">
-        and test_plan2=#{testPlan2}
-      </if>
-      <if test="overdueReminder!=null and overdueReminder!=''">
-        and overdue_reminder=#{overdueReminder}
+        and LPAD(MONTH(test_plan1), 2, 0) like concat('%', #{testPlan1})
       </if>
       <if test="completionDate1!=null and completionDate1!=''">
         and completion_date1=#{completionDate1}
       </if>
-      <if test="completionDate2!=null and completionDate2!=''">
-        and completion_date2=#{completionDate2}
-      </if>
-      <if test="planChange1!=null and planChange1!=''">
-        and plan_change1=#{planChange1}
-      </if>
-      <if test="planChange2!=null and planChange2!=''">
-        and plan_change2=#{planChange2}
-      </if>
-      <if test="overdueReason!=null and overdueReason!=''">
-        and overdue_reason=#{overdueReason}
-      </if>
       <if test="fileId!=null ">
         and file_id=#{fileId}
       </if>

+ 1 - 97
railway-business/src/main/resources/mapper/bi/ShowSbxjMapper.xml

@@ -385,104 +385,8 @@
     FROM show_sbxj
     <where>
       del_flag='0'
-      <if test="deptName!=null and deptName!=''">
-        and dept_name=#{deptName}
-      </if>
       <if test="teamName!=null and teamName!=''">
-        and team_name=#{teamName}
-      </if>
-      <if test="xjdy!=null and xjdy!=''">
-        and xjdy=#{xjdy}
-      </if>
-      <if test="xb!=null and xb!=''">
-        and xb=#{xb}
-      </if>
-      <if test="pds!=null and pds!=''">
-        and pds=#{pds}
-      </if>
-      <if test="bds!=null and bds!=''">
-        and bds=#{bds}
-      </if>
-      <if test="sdxl!=null and sdxl!=''">
-        and sdxl=#{sdxl}
-      </if>
-      <if test="qybds!=null and qybds!=''">
-        and qybds=#{qybds}
-      </if>
-      <if test="atfqs!=null and atfqs!=''">
-        and atfqs=#{atfqs}
-      </if>
-      <if test="plan1!=null and plan1!=''">
-        and plan1=#{plan1}
-      </if>
-      <if test="actual1!=null and actual1!=''">
-        and actual1=#{actual1}
-      </if>
-      <if test="plan2!=null and plan2!=''">
-        and plan2=#{plan2}
-      </if>
-      <if test="actual2!=null and actual2!=''">
-        and actual2=#{actual2}
-      </if>
-      <if test="plan3!=null and plan3!=''">
-        and plan3=#{plan3}
-      </if>
-      <if test="actual3!=null and actual3!=''">
-        and actual3=#{actual3}
-      </if>
-      <if test="plan4!=null and plan4!=''">
-        and plan4=#{plan4}
-      </if>
-      <if test="actual4!=null and actual4!=''">
-        and actual4=#{actual4}
-      </if>
-      <if test="plan5!=null and plan5!=''">
-        and plan5=#{plan5}
-      </if>
-      <if test="actual5!=null and actual5!=''">
-        and actual5=#{actual5}
-      </if>
-      <if test="plan6!=null and plan6!=''">
-        and plan6=#{plan6}
-      </if>
-      <if test="actual6!=null and actual6!=''">
-        and actual6=#{actual6}
-      </if>
-      <if test="plan7!=null and plan7!=''">
-        and plan7=#{plan7}
-      </if>
-      <if test="actual7!=null and actual7!=''">
-        and actual7=#{actual7}
-      </if>
-      <if test="plan8!=null and plan8!=''">
-        and plan8=#{plan8}
-      </if>
-      <if test="actual8!=null and actual8!=''">
-        and actual8=#{actual8}
-      </if>
-      <if test="plan9!=null and plan9!=''">
-        and plan9=#{plan9}
-      </if>
-      <if test="actual9!=null and actual9!=''">
-        and actual9=#{actual9}
-      </if>
-      <if test="plan10!=null and plan10!=''">
-        and plan10=#{plan10}
-      </if>
-      <if test="actual10!=null and actual10!=''">
-        and actual10=#{actual10}
-      </if>
-      <if test="plan11!=null and plan11!=''">
-        and plan11=#{plan11}
-      </if>
-      <if test="actual11!=null and actual11!=''">
-        and actual11=#{actual11}
-      </if>
-      <if test="plan12!=null and plan12!=''">
-        and plan12=#{plan12}
-      </if>
-      <if test="actual12!=null and actual12!=''">
-        and actual12=#{actual12}
+        and team_name like concat('%', #{teamName}, '%')
       </if>
       <if test="fileId!=null ">
         and file_id=#{fileId}

+ 12 - 11
railway-business/src/main/resources/mapper/bi/ShowTestPlanDtMapper.xml

@@ -151,26 +151,27 @@
     <where>
       del_flag='0'
       <if test="lineName!=null and lineName!=''">
-        and line_name=#{lineName}
+        and line_name like concat('%', #{lineName}, '%')
       </if>
       <if test="substationName!=null and substationName!=''">
-        and substation_name=#{substationName}
+        and substation_name like concat('%', #{substationName}, '%')
       </if>
       <if test="sbmc!=null and sbmc!=''">
-        and sbmc=#{sbmc}
+        and sbmc like concat('%', #{sbmc}, '%')
       </if>
-      <if test="yxbh!=null and yxbh!=''">
-        and yxbh=#{yxbh}
+      <if test="testPlanDateStart!=null">
+        and test_plan_date <![CDATA[ >= ]]> #{testPlanDateStart}
       </if>
-      <if test="testCycle!=null and testCycle!=''">
-        and test_cycle=#{testCycle}
+      <if test="testPlanDateEnd!=null">
+        and test_plan_date <![CDATA[ <= ]]> #{testPlanDateEnd}
       </if>
-      <if test="testPlanDate!=null and testPlanDate!=''">
-        and test_plan_date=#{testPlanDate}
+      <if test="completionDateStart!=null">
+        and completion_date <![CDATA[ >= ]]> #{completionDateStart}
       </if>
-      <if test="completionDate!=null and completionDate!=''">
-        and completion_date=#{completionDate}
+      <if test="completionDateEnd!=null">
+        and completion_date <![CDATA[ <= ]]> #{completionDateEnd}
       </if>
+
       <if test="fileId!=null ">
         and file_id=#{fileId}
       </if>

+ 11 - 8
railway-business/src/main/resources/mapper/bi/ShowTestPlanKgMapper.xml

@@ -133,19 +133,22 @@
     <where>
       del_flag='0'
       <if test="lineName!=null and lineName!=''">
-        and line_name=#{lineName}
+        and line_name like concat('%', #{lineName}, '%')
       </if>
       <if test="substationName!=null and substationName!=''">
-        and substation_name=#{substationName}
+        and substation_name like concat('%', #{substationName}, '%')
       </if>
-      <if test="kgbh!=null and kgbh!=''">
-        and kgbh=#{kgbh}
+      <if test="testPlanDateStart!=null">
+        and test_plan_date <![CDATA[ >= ]]> #{testPlanDateStart}
       </if>
-      <if test="testPlanDate!=null and testPlanDate!=''">
-        and test_plan_date=#{testPlanDate}
+      <if test="testPlanDateEnd!=null">
+        and test_plan_date <![CDATA[ <= ]]> #{testPlanDateEnd}
       </if>
-      <if test="completionDate!=null and completionDate!=''">
-        and completion_date=#{completionDate}
+      <if test="completionDateStart!=null">
+        and completion_date <![CDATA[ >= ]]> #{completionDateStart}
+      </if>
+      <if test="completionDateEnd!=null">
+        and completion_date <![CDATA[ <= ]]> #{completionDateEnd}
       </if>
       <if test="fileId!=null ">
         and file_id=#{fileId}

+ 1 - 40
railway-business/src/main/resources/mapper/bi/ShowYdtsMapper.xml

@@ -222,51 +222,12 @@
     FROM show_ydts
     <where>
       del_flag='0'
-      <if test="branchName!=null and branchName!=''">
-        and branch_name=#{branchName}
-      </if>
-      <if test="deptName!=null and deptName!=''">
-        and dept_name=#{deptName}
-      </if>
-      <if test="lineSddj!=null and lineSddj!=''">
-        and line_sddj=#{lineSddj}
-      </if>
       <if test="lineName!=null and lineName!=''">
-        and line_name=#{lineName}
-      </if>
-      <if test="stationName!=null and stationName!=''">
-        and station_name=#{stationName}
-      </if>
-      <if test="lineXz!=null and lineXz!=''">
-        and line_xz=#{lineXz}
-      </if>
-      <if test="substationName!=null and substationName!=''">
-        and substation_name=#{substationName}
-      </if>
-      <if test="switchHigh!=null and switchHigh!=''">
-        and switch_high=#{switchHigh}
-      </if>
-      <if test="switchLow!=null and switchLow!=''">
-        and switch_low=#{switchLow}
-      </if>
-      <if test="lastYear!=null and lastYear!=''">
-        and last_year=#{lastYear}
+        and line_name like concat('%', #{lineName}, '%')
       </if>
       <if test="planMonth!=null and planMonth!=''">
         and plan_month=#{planMonth}
       </if>
-      <if test="overdueReminder!=null and overdueReminder!=''">
-        and overdue_reminder=#{overdueReminder}
-      </if>
-      <if test="completionDate!=null and completionDate!=''">
-        and completion_date=#{completionDate}
-      </if>
-      <if test="jhtzjy!=null and jhtzjy!=''">
-        and jhtzjy=#{jhtzjy}
-      </if>
-      <if test="overdueReason!=null and overdueReason!=''">
-        and overdue_reason=#{overdueReason}
-      </if>
       <if test="fileId!=null ">
         and file_id=#{fileId}
       </if>