wuxw
2023-12-28 560b21b2b373ef818d54dea866bc6b62f2508490
优化代码
4个文件已修改
75 ■■■■■ 已修改文件
java110-bean/src/main/java/com/java110/dto/workPool/WorkPoolDto.java 20 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
java110-bean/src/main/java/com/java110/dto/workTask/WorkTaskDto.java 3 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
java110-db/src/main/resources/mapper/oa/WorkPoolV1ServiceDaoImplMapper.xml 36 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
java110-db/src/main/resources/mapper/oa/WorkTaskV1ServiceDaoImplMapper.xml 16 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
java110-bean/src/main/java/com/java110/dto/workPool/WorkPoolDto.java
@@ -65,6 +65,10 @@
    private String remark ;
    private String staffNameLike;
    private String workNameLike;
    public String getWorkCycle() {
        return workCycle;
@@ -274,4 +278,20 @@
    public void setRemark(String remark) {
        this.remark = remark;
    }
    public String getStaffNameLike() {
        return staffNameLike;
    }
    public void setStaffNameLike(String staffNameLike) {
        this.staffNameLike = staffNameLike;
    }
    public String getWorkNameLike() {
        return workNameLike;
    }
    public void setWorkNameLike(String workNameLike) {
        this.workNameLike = workNameLike;
    }
}
java110-bean/src/main/java/com/java110/dto/workTask/WorkTaskDto.java
@@ -1,6 +1,7 @@
package com.java110.dto.workTask;
import com.java110.dto.PageDto;
import com.java110.dto.workPool.WorkPoolDto;
import java.io.Serializable;
import java.util.Date;
@@ -13,7 +14,7 @@
 * @Version 1.0
 * add by wuxw 2019/4/24
 **/
public class WorkTaskDto extends PageDto implements Serializable {
public class WorkTaskDto extends WorkPoolDto implements Serializable {
    public static final String STATE_WAIT = "W";// 待处理
    public static final String STATE_COMPLETE = "C";// 处理完成
java110-db/src/main/resources/mapper/oa/WorkPoolV1ServiceDaoImplMapper.xml
@@ -27,6 +27,12 @@
        left join work_type wt on t.wt_id = wt.wt_id
        left join t_dict td on t.state = td.status_cd and td.table_name = 'work_pool' and td.table_columns = 'state'
        where 1 =1
        <if test="createUserNameLike !=null and createUserNameLike != ''">
            and t.create_user_name like concat('%', #{createUserNameLike},'%')
        </if>
        <if test="workNameLike !=null and workNameLike != ''">
            and t.work_name like concat('%', #{workNameLike},'%')
        </if>
        <if test="workCycle !=null and workCycle != ''">
            and t.work_cycle= #{workCycle}
        </if>
@@ -131,6 +137,12 @@
        select count(1) count
        from work_pool t
        where 1 =1
        <if test="createUserNameLike !=null and createUserNameLike != ''">
            and t.create_user_name like concat('%', #{createUserNameLike},'%')
        </if>
        <if test="workNameLike !=null and workNameLike != ''">
            and t.work_name like concat('%', #{workNameLike},'%')
        </if>
        <if test="workCycle !=null and workCycle != ''">
            and t.work_cycle= #{workCycle}
        </if>
@@ -188,6 +200,12 @@
        left join work_task wtk on t.work_id = wtk.work_id and wtk.status_cd = '0'
        left join t_dict td on wtk.state = td.status_cd and td.table_name = 'work_pool' and td.table_columns = 'state'
        where 1 =1
        <if test="createUserNameLike !=null and createUserNameLike != ''">
            and t.create_user_name like concat('%', #{createUserNameLike},'%')
        </if>
        <if test="workNameLike !=null and workNameLike != ''">
            and t.work_name like concat('%', #{workNameLike},'%')
        </if>
        <if test="workCycle !=null and workCycle != ''">
            and t.work_cycle= #{workCycle}
        </if>
@@ -241,6 +259,12 @@
        left join work_task wtk on t.work_id = wtk.work_id and wtk.status_cd = '0'
        left join t_dict td on wtk.state = td.status_cd and td.table_name = 'work_pool' and td.table_columns = 'state'
        where 1 =1
        <if test="createUserNameLike !=null and createUserNameLike != ''">
            and t.create_user_name like concat('%', #{createUserNameLike},'%')
        </if>
        <if test="workNameLike !=null and workNameLike != ''">
            and t.work_name like concat('%', #{workNameLike},'%')
        </if>
        <if test="workCycle !=null and workCycle != ''">
            and t.work_cycle= #{workCycle}
        </if>
@@ -292,6 +316,12 @@
        left join work_copy wc on t.work_id = wc.work_id and wc.status_cd = '0'
        left join t_dict td on wc.state = td.status_cd and td.table_name = 'work_pool' and td.table_columns = 'state'
        where 1 =1
        <if test="createUserNameLike !=null and createUserNameLike != ''">
            and t.create_user_name like concat('%', #{createUserNameLike},'%')
        </if>
        <if test="workNameLike !=null and workNameLike != ''">
            and t.work_name like concat('%', #{workNameLike},'%')
        </if>
        <if test="workCycle !=null and workCycle != ''">
            and t.work_cycle= #{workCycle}
        </if>
@@ -345,6 +375,12 @@
        left join work_copy wc on t.work_id = wc.work_id and wc.status_cd = '0'
        left join t_dict td on wc.state = td.status_cd and td.table_name = 'work_pool' and td.table_columns = 'state'
        where 1 =1
        <if test="createUserNameLike !=null and createUserNameLike != ''">
            and t.create_user_name like concat('%', #{createUserNameLike},'%')
        </if>
        <if test="workNameLike !=null and workNameLike != ''">
            and t.work_name like concat('%', #{workNameLike},'%')
        </if>
        <if test="workCycle !=null and workCycle != ''">
            and t.work_cycle= #{workCycle}
        </if>
java110-db/src/main/resources/mapper/oa/WorkTaskV1ServiceDaoImplMapper.xml
@@ -34,6 +34,9 @@
        <if test="createUserNameLike !=null and createUserNameLike != ''">
            and wp.create_user_name like concat('%', #{createUserNameLike},'%')
        </if>
        <if test="workNameLike !=null and workNameLike != ''">
            and wp.work_name like concat('%', #{workNameLike},'%')
        </if>
        <if test="staffName !=null and staffName != ''">
            and t.staff_name= #{staffName}
        </if>
@@ -129,10 +132,21 @@
    <select id="queryWorkTasksCount" parameterType="Map" resultType="Map">
        select count(1) count
        from work_task t
        where 1 =1
        left join t_dict td on t.state = td.status_cd and td.table_name = 'work_pool' and td.table_columns = 'state'
        left join work_pool wp on t.work_id = wp.work_id and wp.status_cd = '0'
        left join work_type wt on wp.wt_id = wt.wt_id
        where 1=1
        and wp.status_cd = '0'
        <if test="createUserNameLike !=null and createUserNameLike != ''">
            and wp.create_user_name like concat('%', #{createUserNameLike},'%')
        </if>
        <if test="workNameLike !=null and workNameLike != ''">
            and wp.work_name like concat('%', #{workNameLike},'%')
        </if>
        <if test="staffName !=null and staffName != ''">
            and t.staff_name= #{staffName}
        </if>
        <if test="staffNameLike !=null and staffNameLike != ''">
            and t.staff_name like concat('%', #{staffNameLike},'%')
        </if>