786ff9db
王富生
app养护计划明细提交
|
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
|
<select id="appMaintainPlanDetailListByRoad" resultType="com.zteits.urbanops.module.garden.controller.app.maintainplan.vo.AppMaintainPlanDetailRespVO">
SELECT
c.batch_no,
c.plan_no,
a.plan_name,
a.plan_type_id,
a.rate,
a.cycle_id,
c.plan_num,
c.finish_percent,
c.finish_state,
c.begin_time,
c.end_time,
c.sort_num
FROM
garden_maintain_plan a,
garden_maintain_plan_role b,
garden_maintain_plan_detail c
WHERE
a.batch_no = b.batch_no
and a.batch_no=b.batch_no
AND a.dept_id =b.dept_id
AND a.deleted=0
AND a.company_id = #{companyId}
AND a.road_id = #{roadId}
|
786ff9db
王富生
app养护计划明细提交
|
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
|
<if test="roleIds != null and roleIds.size() > 0">
AND b.role_id IN
<foreach collection="roleIds" item="roleId" open="(" separator="," close=")">
#{roleId}
</foreach>
</if>
<if test="busiLineList != null and busiLineList.size() > 0">
AND a.busi_line IN
<foreach collection="busiLineList" item="busiLine" open="(" separator="," close=")">
#{busiLine}
</foreach>
</if>
<!--状态 1:未完成;2:已完成;3:已失效-->
<if test="finishState == 3">
<![CDATA[and c.end_time < #{localDate}]]>
</if>
<if test="finishState == 2">
and c.finish_state = #{finishState}
</if>
<if test="finishState == 1">
and c.finish_state = #{finishState}
<![CDATA[and c.end_time >= #{localDate}]]>
</if>
</select>
|