|
@@ -8,6 +8,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
8
|
8
|
<result property="formId" column="form_id" />
|
9
|
9
|
<result property="projectId" column="project_id" />
|
10
|
10
|
<result property="userId" column="user_id" />
|
|
11
|
+ <result property="deptId" column="dept_id" />
|
11
|
12
|
<result property="workType" column="work_type" />
|
12
|
13
|
<result property="workItem" column="work_item" />
|
13
|
14
|
<result property="workContent" column="work_content" />
|
|
@@ -28,7 +29,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
28
|
29
|
</resultMap>
|
29
|
30
|
|
30
|
31
|
<sql id="selectCmcDeclareVo">
|
31
|
|
- select d.form_id, d.project_id, p.project_number, p.project_name, d.user_id, u.nick_name, d.work_type, d.work_item, d.work_content, d.work_load, d.price, d.coefficient, d.check_status, d.audit_status, d.submit_time, d.confirm_status from cmc_declare as d
|
|
32
|
+ select d.form_id, d.project_id, p.project_number, p.project_name, d.user_id, u.dept_id, u.nick_name, d.work_type, d.work_item, d.work_content, d.work_load, d.price, d.coefficient, d.check_status, d.audit_status, d.submit_time, d.confirm_status from cmc_declare as d
|
32
|
33
|
left join sys_user as u on u.user_id = d.user_id
|
33
|
34
|
left join cmc_project as p on p.project_id = d.project_id
|
34
|
35
|
</sql>
|
|
@@ -44,6 +45,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
44
|
45
|
<where>
|
45
|
46
|
<if test="projectId != null and projectId != ''"> and d.project_id = #{projectId}</if>
|
46
|
47
|
<if test="userId != null"> and d.user_id = #{userId}</if>
|
|
48
|
+ <if test="deptId != null"> and u.dept_id = #{deptId}</if>
|
47
|
49
|
<if test="workType != null and workType != ''"> and d.work_type = #{workType}</if>
|
48
|
50
|
<if test="workItem != null and workItem != ''"> and d.work_item = #{workItem}</if>
|
49
|
51
|
<if test="workContent != null and workContent != ''"> and d.work_content = #{workContent}</if>
|
|
@@ -52,7 +54,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
52
|
54
|
<if test="coefficient != null and coefficient != ''"> and d.coefficient = #{coefficient}</if>
|
53
|
55
|
<if test="checkStatus != null and checkStatus != ''"> and d.check_status = #{checkStatus}</if>
|
54
|
56
|
<if test="auditStatus != null and auditStatus != ''"> and d.audit_status = #{auditStatus}</if>
|
55
|
|
- <if test="submitTime != null "> and d.submit_time = #{submitTime}</if>
|
|
57
|
+ <if test="submitTime != null "> and date_format(d.submit_time, '%y%m') = date_format(#{submitTime}, '%y%m')</if>
|
56
|
58
|
<if test="confirmStatus != null and confirmStatus != ''"> and d.confirm_status = #{confirmStatus}</if>
|
57
|
59
|
</where>
|
58
|
60
|
order by d.submit_time desc
|