|
|
@ -29,6 +29,7 @@
|
|
|
|
from equ_plan ep
|
|
|
|
from equ_plan ep
|
|
|
|
left join equ_plan_equ epe on ep.plan_code = epe.plan_code
|
|
|
|
left join equ_plan_equ epe on ep.plan_code = epe.plan_code
|
|
|
|
where ep.del_flag = '0' and epe.del_flag = '0' and ep.plan_status = '0'
|
|
|
|
where ep.del_flag = '0' and epe.del_flag = '0' and ep.plan_status = '0'
|
|
|
|
|
|
|
|
and epe.equipment_code in ( select be.equipment_code from base_equipment be where be.del_flag = '0' )
|
|
|
|
and ep.plan_type = #{planType}
|
|
|
|
and ep.plan_type = #{planType}
|
|
|
|
and CONVERT(varchar(10),GETDATE(), 120) >= CONVERT(varchar(10),ep.plan_loop_start, 120)
|
|
|
|
and CONVERT(varchar(10),GETDATE(), 120) >= CONVERT(varchar(10),ep.plan_loop_start, 120)
|
|
|
|
<if test='planType=="inspection" or planType=="maintenance" '>
|
|
|
|
<if test='planType=="inspection" or planType=="maintenance" '>
|
|
|
|