Merge remote-tracking branch 'origin/pet' into pet
commit
ddc05cfb96
|
@ -346,6 +346,7 @@
|
|||
FROM bus_fire_checklist AS cl
|
||||
LEFT JOIN bus_fire_device_prepared AS fpc ON cl.FIRE_CHECK_ID = fpc.FIRE_CHECK_ID
|
||||
LEFT JOIN bus_fire_point_prepared fpp on cl.FIRE_CHECK_ID = fpp.FIRE_CHECK_ID
|
||||
LEFT JOIN bus_fire_point fp ON fp.FIRE_POINT_ID = fpp.FIRE_POINT_ID
|
||||
LEFT JOIN sys_user AS su ON cl.USER_ID = su.USER_ID
|
||||
LEFT JOIN oa_department AS od ON cl.DEPARTMENT_ID = od.DEPARTMENT_ID
|
||||
LEFT JOIN sys_dictionaries ON cl.FIRE_CHECK_TYPE = sys_dictionaries.BIANMA
|
||||
|
@ -355,6 +356,7 @@
|
|||
AND fpp.FIRE_POINT_ID = #{pd.pointId}
|
||||
</if>
|
||||
and fpp.ISDELETE = 0
|
||||
and fp.ISDELETE = 0
|
||||
AND fpc.ISDELETE = 0
|
||||
<if test="pd.roleLevel != null and pd.roleLevel != ''"><!-- 权限显示 -->
|
||||
<choose>
|
||||
|
|
|
@ -712,6 +712,7 @@
|
|||
and frc.FIRE_RECORD_ID = #{FIRE_RECORD_ID}
|
||||
AND frp.ISDELETE = 0
|
||||
AND fpp.ISDELETE = 0
|
||||
AND t.FIRE_POINT_ID IS NOT NULL
|
||||
order by t.FIRE_POINT_NAME
|
||||
</select>
|
||||
<select id="getRecordDeviceByEid" resultType="com.zcloud.entity.PageData">
|
||||
|
|
|
@ -316,7 +316,7 @@
|
|||
LEFT JOIN ( select count(c.KEYPROJECTCHECK_ID) co, c.OUTSOURCED_ID from `qa-gwj-prevention`.BUS_KEYPROJECTCHECK c where c.ISDELETE = '0' group by c.OUTSOURCED_ID ) cc on cc.OUTSOURCED_ID = f.OUTSOURCED_ID
|
||||
left join ( SELECT t.OUTSOURCED_ID, COUNT( t.HIDDEN_ID ) HIDDEN_COUNT, t.SOURCE SOURCE, t.CREATOR CREATOR
|
||||
FROM
|
||||
( SELECT IFNULL( k.OUTSOURCED_ID, h.FOREIGN_ID ) OUTSOURCED_ID, h.* FROM `qa-gwj-prevention`.bus_keyproject_hidden h LEFT JOIN `qa-gwj-prevention`.bus_keyprojectcheck k ON h.FOREIGN_ID = k.KEYPROJECTCHECK_ID and h.ISDELETE = '0') t GROUP BY t.OUTSOURCED_ID ) h on h.OUTSOURCED_ID = f.OUTSOURCED_ID
|
||||
( SELECT IFNULL( k.OUTSOURCED_ID, h.FOREIGN_ID ) OUTSOURCED_ID, h.* FROM `qa-gwj-prevention`.bus_keyproject_hidden h LEFT JOIN `qa-gwj-prevention`.bus_keyprojectcheck k ON h.FOREIGN_ID = k.KEYPROJECTCHECK_ID and h.ISDELETE = '0') t GROUP BY t.OUTSOURCED_ID,t.CREATOR ) h on h.OUTSOURCED_ID = f.OUTSOURCED_ID
|
||||
where f.ISDELETE = '0'
|
||||
<if test="pd.CORPINFO_ID != null and pd.CORPINFO_ID != ''"><!-- 关键词检索 -->
|
||||
and
|
||||
|
@ -376,9 +376,10 @@
|
|||
or f.JURISDICTION_UNIT LIKE CONCAT(CONCAT('%', #{pd.DeptId}),'%')
|
||||
or f.PUNISH_THE_PERSON LIKE CONCAT(CONCAT('%', #{pd.UserId}),'%')
|
||||
or f.CREATOR = #{pd.UserId}
|
||||
or (h.CREATOR = #{pd.UserId} and h.SOURCE = '1')
|
||||
or (h.CREATOR LIKE CONCAT('%', #{pd.UserId}, '%') and h.SOURCE = '1')
|
||||
)
|
||||
</if>
|
||||
GROUP BY f.OUTSOURCED_ID
|
||||
ORDER BY
|
||||
cc.co DESC,
|
||||
f.OPERATTIME DESC
|
||||
|
@ -514,7 +515,7 @@
|
|||
AND f.SOURCE IN ( '4', '5', '1' )
|
||||
AND ifnull(bo.OUTSOURCED_ID,boai.OUTSOURCED_ID) IS NOT NULL
|
||||
and f.ISPUNISH is null
|
||||
) PUN GROUP BY PUN.OUTSOURCED_ID ) cfsl on cfsl.OUTSOURCED_ID = f.OUTSOURCED_ID
|
||||
) PUN GROUP BY PUN.OUTSOURCED_ID,PUN.CREATOR ) cfsl on cfsl.OUTSOURCED_ID = f.OUTSOURCED_ID
|
||||
where f.ISDELETE = '0'
|
||||
<if test="pd.KEYWORDS != null and pd.KEYWORDS != ''"><!-- 关键词检索 -->
|
||||
and
|
||||
|
@ -529,8 +530,9 @@
|
|||
pcij.NAME LIKE CONCAT(CONCAT('%', #{pd.KEYWORDS}),'%')
|
||||
)
|
||||
</if>
|
||||
and (f.PUNISH_THE_PERSON LIKE CONCAT( CONCAT( '%', #{pd.PUNISHUser} ), '%' ) or (cfsl.SOURCE='1' and cfsl.CREATOR = #{pd.PUNISHUser}))
|
||||
and (f.PUNISH_THE_PERSON LIKE CONCAT( CONCAT( '%', #{pd.PUNISHUser} ), '%' ) or (cfsl.SOURCE='1' and cfsl.CREATOR LIKE CONCAT('%',#{pd.PUNISHUser},'%') ))
|
||||
AND f.STATE = '1'
|
||||
GROUP BY cfsl.OUTSOURCED_ID
|
||||
ORDER BY
|
||||
cfsl.co DESC,
|
||||
f.OPERATTIME DESC
|
||||
|
|
Loading…
Reference in New Issue