消防安全管理添加扫码查看检查记录更新
parent
9169d4c15e
commit
c2068c6ebd
|
@ -89,7 +89,6 @@ public interface FireRecordMapper {
|
|||
|
||||
List<PageData> datalistPageV2(Page page);
|
||||
|
||||
List<PageData> datalistPageV3(Page page);
|
||||
List<PageData> datalistPage(Page page);
|
||||
|
||||
List<PageData> getCheckingByCid(String fireCheckId);
|
||||
|
|
|
@ -80,7 +80,6 @@ public interface FireRecordService {
|
|||
List<PageData> getCheckListByApp(Page page);
|
||||
List<PageData> getCheckListByAppV2(Page page);
|
||||
|
||||
List<PageData> getCheckListByAppV3(Page page);
|
||||
List<PageData> getCheckRecordByPid(PageData pd);
|
||||
|
||||
/**
|
||||
|
|
|
@ -723,11 +723,6 @@ public class FireRecordServiceImpl implements FireRecordService {
|
|||
return data;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<PageData> getCheckListByAppV3(Page page) {
|
||||
List<PageData> data = fireRecordMapper.datalistPageV3(page);
|
||||
return data;
|
||||
}
|
||||
@Override
|
||||
public List<PageData> getCheckRecordByPid(PageData pd) {
|
||||
return fireRecordMapper.getCheckRecordByPid(pd);
|
||||
|
|
|
@ -34,7 +34,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||
|
||||
<!--表名 -->
|
||||
<sql id="tableName">
|
||||
SYS_MENU
|
||||
sys_menu2
|
||||
</sql>
|
||||
|
||||
<!-- 字段 -->
|
||||
|
|
|
@ -1031,58 +1031,5 @@
|
|||
frp.EQUIPMENT_POINT_ID = #{EQUIPMENT_POINT_ID}
|
||||
AND frp.ISDELETE = '0'
|
||||
</select>
|
||||
<select id="datalistPageV3" resultType="com.zcloud.entity.PageData" parameterType="com.zcloud.entity.Page">
|
||||
SELECT
|
||||
cl.FIRE_CHECK_STANDARD_NAME,
|
||||
fr.FIRE_CHECK_ID,
|
||||
cl.FIRE_CHECK_TYPE AS FIRE_CHECK_TYPE_ID,
|
||||
d.`NAME` AS DEPARTMENT_NAME,
|
||||
su.`NAME` AS USER_NAME,
|
||||
count(
|
||||
IF
|
||||
( fr.FINISHED = 0, NULL, fr.FINISHED )) COUNT,
|
||||
IF
|
||||
( temp.FINISHED > 0, temp.FINISHED, 0 ) checkCount,
|
||||
cl.STATE,
|
||||
sys_dictionaries.`NAME` AS PERIODNAME
|
||||
FROM
|
||||
bus_fire_record AS fr
|
||||
LEFT JOIN bus_fire_record_point AS cp ON fr.FIRE_CHECK_ID = cp.FIRE_CHECK_ID
|
||||
LEFT JOIN bus_fire_checklist AS cl ON cp.FIRE_CHECK_ID = cl.FIRE_CHECK_ID
|
||||
LEFT JOIN oa_department AS d ON cl.DEPARTMENT_ID = d.DEPARTMENT_ID
|
||||
LEFT JOIN sys_user AS su ON cl.USER_ID = su.USER_ID
|
||||
LEFT JOIN sys_dictionaries ON cl.FIRE_CHECK_TYPE = sys_dictionaries.BIANMA
|
||||
LEFT JOIN ( SELECT count(FINISHED) FINISHED ,FIRE_CHECK_ID FROM bus_fire_record WHERE
|
||||
CONCAT(date_format(current_date(),'%Y-%m-%d'),' 00:00:00') BETWEEN PERIODSTART AND PERIODEND and isdelete = 0 and FINISHED = '1' GROUP BY
|
||||
FIRE_CHECK_ID ) temp ON
|
||||
fr.FIRE_CHECK_ID = temp.FIRE_CHECK_ID
|
||||
LEFT JOIN ( SELECT * FROM bus_fire_record WHERE CONCAT(date_format(current_date()-1,'%Y-%m-%d'),' 00:00:00')
|
||||
BETWEEN PERIODSTART AND
|
||||
PERIODEND GROUP BY FIRE_CHECK_ID ) st ON fr.FIRE_CHECK_ID = st.FIRE_CHECK_ID
|
||||
WHERE
|
||||
fr.ISDELETE = 0
|
||||
AND cl.ISDELETE = 0
|
||||
<if test="pd.roleLevel != null and pd.roleLevel != ''"><!-- 权限显示 -->
|
||||
<choose>
|
||||
<!--公司领导-->
|
||||
<when test='pd.roleLevel == "0"'>
|
||||
<if test="pd.CORPINFO_ID!=null and pd.CORPINFO_ID != ''">
|
||||
AND cp.CORPINFO_ID = #{pd.CORPINFO_ID,jdbcType=VARCHAR}
|
||||
</if>
|
||||
</when>
|
||||
<when test='pd.roleLevel == "1"'>
|
||||
and cp.DEPARTMENT_ID in (${pd.supDeparIds})
|
||||
</when>
|
||||
<when test='pd.roleLevel == "2"'>
|
||||
<if test="pd.FIRE_POINT_ID != null and pd.FIRE_POINT_ID != ''">
|
||||
AND cp.FIRE_POINT_ID = #{pd.FIRE_POINT_ID}
|
||||
</if>
|
||||
</when>
|
||||
</choose>
|
||||
</if>
|
||||
GROUP BY
|
||||
FIRE_CHECK_ID
|
||||
order by fr. CREATTIME
|
||||
</select>
|
||||
|
||||
</mapper>
|
||||
|
|
|
@ -34,7 +34,7 @@
|
|||
|
||||
<!--表名 -->
|
||||
<sql id="tableName">
|
||||
SYS_MENU
|
||||
sys_menu2
|
||||
</sql>
|
||||
|
||||
<!-- 字段 -->
|
||||
|
|
Loading…
Reference in New Issue