Explorar el Código

计划流程管理新增查询条件

zx hace 3 semanas
padre
commit
3b5cebf7ce

+ 10 - 0
ruoyi-powerdistribution/src/main/java/com/ruoyi/powerdistribution/domain/PdmMaintenanceProcess.java

@@ -113,6 +113,16 @@ public class PdmMaintenanceProcess extends BaseEntity
     private String workPrincipAmt;
     @Excel(name = "设备主人考核金额")
     private String ownerAmt;
+
+    /**
+     * 查询条件-开始时间
+     */
+    private String startDate;
+
+    /**
+     * 查询条件-结束时间
+     */
+    private String endDate;
 //
 //    @Override
     public String toString() {

+ 8 - 1
ruoyi-powerdistribution/src/main/resources/mapper/powerdistribution/PdmMaintenanceProcessMapper.xml

@@ -72,8 +72,15 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
             <if test="isApprove != null  and isApprove != ''"> and is_approve = #{isApprove}</if>
             <if test="maintenanceFilePath != null  and maintenanceFilePath != ''"> and maintenance_file_path = #{maintenanceFilePath}</if>
             <if test="approveFilePath != null  and approveFilePath != ''"> and approve_file_path = #{approveFilePath}</if>
+            <if test="startDate != null and startDate != ''">
+                and date_format(week_start_dt,'%Y%m%d') &gt;= #{startDate}
+            </if>
+            <if test="endDate != null and endDate != ''">
+                and date_format(week_start_dt,'%Y%m%d') &lt;= #{endDate}
+            </if>
+
         </where>
-        )a order by plan_code,plan_code_w,station,line_name
+        )a order by week_start_dt desc,plan_code,plan_code_w,station,line_name
     </select>
 
     <select id="selectPdmMaintenanceProcessById" parameterType="Long" resultMap="PdmMaintenanceProcessResult">