Commit 811c6c78 authored by suhuiguang's avatar suhuiguang

feat(tcm): 监管删除启停用企业

1.企业列表显示停用的企业
parent a8682de0
...@@ -34,7 +34,6 @@ ...@@ -34,7 +34,6 @@
cu.data_sources = '陕西省内企业' cu.data_sources = '陕西省内企业'
AND cu.unit_type LIKE '%充装单位%' AND cu.unit_type LIKE '%充装单位%'
and cu.org_code like concat('%', #{regionCode}, '%') and cu.org_code like concat('%', #{regionCode}, '%')
AND cu.is_delete = 0
GROUP BY strKey GROUP BY strKey
</select> </select>
...@@ -47,7 +46,6 @@ ...@@ -47,7 +46,6 @@
<where> <where>
cu.data_sources = '陕西省内企业' cu.data_sources = '陕西省内企业'
AND cu.unit_type LIKE '%充装单位%' AND cu.unit_type LIKE '%充装单位%'
and cu.is_delete = false
<if test="regionCode != null and regionCode != ''"> <if test="regionCode != null and regionCode != ''">
and cu.org_code like concat(#{regionCode}, '%') and cu.org_code like concat(#{regionCode}, '%')
</if> </if>
...@@ -65,7 +63,6 @@ ...@@ -65,7 +63,6 @@
LEFT JOIN tz_base_enterprise_info cu on ci.app_id = cu.app_id LEFT JOIN tz_base_enterprise_info cu on ci.app_id = cu.app_id
<where> <where>
cu.data_sources = '陕西省内企业' cu.data_sources = '陕西省内企业'
and cu.is_delete = false
AND cu.unit_type LIKE '%充装单位%' AND cu.unit_type LIKE '%充装单位%'
<if test="regionCode != null and regionCode != ''"> <if test="regionCode != null and regionCode != ''">
and cu.org_code like concat( #{regionCode}, '%') and cu.org_code like concat( #{regionCode}, '%')
...@@ -88,7 +85,6 @@ ...@@ -88,7 +85,6 @@
RIGHT JOIN tz_cylinder_info t1 ON t1.app_id = i.app_id RIGHT JOIN tz_cylinder_info t1 ON t1.app_id = i.app_id
WHERE WHERE
i.data_sources = '陕西省内企业' i.data_sources = '陕西省内企业'
and i.is_delete = false
AND i.unit_type LIKE'%充装单位%' AND i.unit_type LIKE'%充装单位%'
AND i.industry_supervisor like concat(#{orgCode}, '%') AND i.industry_supervisor like concat(#{orgCode}, '%')
GROUP BY GROUP BY
...@@ -107,7 +103,6 @@ ...@@ -107,7 +103,6 @@
RIGHT JOIN tz_cylinder_info t1 ON t1.app_id = i.app_id RIGHT JOIN tz_cylinder_info t1 ON t1.app_id = i.app_id
WHERE WHERE
i.data_sources = '陕西省内企业' i.data_sources = '陕西省内企业'
and i.is_delete = false
AND i.unit_type LIKE'%充装单位%' AND i.unit_type LIKE'%充装单位%'
AND i.industry_supervisor like concat(#{orgCode}, '%') AND i.industry_supervisor like concat(#{orgCode}, '%')
GROUP BY GROUP BY
...@@ -134,7 +129,6 @@ ...@@ -134,7 +129,6 @@
WHERE WHERE
i.data_sources = '陕西省内企业' i.data_sources = '陕西省内企业'
AND i.unit_type LIKE'%充装单位%' AND i.unit_type LIKE'%充装单位%'
and i.is_delete = false
<if test="orgCodes != null and orgCodes.size > 0"> <if test="orgCodes != null and orgCodes.size > 0">
AND AND
<foreach collection="orgCodes" open="(" item="orgCode" close=")" separator=" or "> <foreach collection="orgCodes" open="(" item="orgCode" close=")" separator=" or ">
...@@ -156,7 +150,6 @@ ...@@ -156,7 +150,6 @@
RIGHT JOIN tzs_user_info ui ON ui.unit_code = u.use_code RIGHT JOIN tzs_user_info ui ON ui.unit_code = u.use_code
WHERE WHERE
u.data_sources = '陕西省内企业' u.data_sources = '陕西省内企业'
and u.is_delete = false
AND u.unit_type LIKE'%充装单位%' AND u.unit_type LIKE'%充装单位%'
AND ui.post like '%"6552"%' AND ui.post like '%"6552"%'
<if test="orgCodes != null and orgCodes.size > 0"> <if test="orgCodes != null and orgCodes.size > 0">
......
...@@ -625,7 +625,6 @@ ...@@ -625,7 +625,6 @@
AND f.filling_endtime >= concat(#{startTime}, ' 00:00:00') AND f.filling_endtime >= concat(#{startTime}, ' 00:00:00')
AND i.org_code like concat(#{orgCode}, '%') AND i.org_code like concat(#{orgCode}, '%')
AND i.unit_type like '%充装单位%' AND i.unit_type like '%充装单位%'
and i.is_delete = false
GROUP BY GROUP BY
filling_time filling_time
ORDER BY ORDER BY
...@@ -643,7 +642,6 @@ ...@@ -643,7 +642,6 @@
i.app_id = f.app_id i.app_id = f.app_id
AND f.statistics_sync_date >= #{startTime} AND f.statistics_sync_date >= #{startTime}
AND i.org_code like concat(#{orgCode}, '%') AND i.org_code like concat(#{orgCode}, '%')
and i.is_delete = false
GROUP BY GROUP BY
filling_time filling_time
ORDER BY ORDER BY
......
...@@ -19,7 +19,6 @@ ...@@ -19,7 +19,6 @@
tz_cylinder_tags t, tz_cylinder_tags t,
tz_base_enterprise_info e tz_base_enterprise_info e
where t.app_id = e.app_id where t.app_id = e.app_id
and e.is_delete = false
<if test="orgCode != null and orgCode != ''"> <if test="orgCode != null and orgCode != ''">
and e.org_code like concat(#{orgCode}, '%') and e.org_code like concat(#{orgCode}, '%')
</if> </if>
......
...@@ -67,7 +67,6 @@ ...@@ -67,7 +67,6 @@
FROM tz_base_enterprise_info tcu FROM tz_base_enterprise_info tcu
WHERE tcu.org_code like concat( #{orgCode}, '%') WHERE tcu.org_code like concat( #{orgCode}, '%')
AND tcu.data_sources = '陕西省内企业' AND tcu.data_sources = '陕西省内企业'
and tcu.is_delete = false
AND tcu.unit_type LIKE'%充装单位%' AND tcu.unit_type LIKE'%充装单位%'
</select> </select>
<select id="queryCylinderUnitOfPermissionExpire" resultType="com.yeejoin.amos.boot.module.cylinder.flc.api.dto.CylinderUnitDto"> <select id="queryCylinderUnitOfPermissionExpire" resultType="com.yeejoin.amos.boot.module.cylinder.flc.api.dto.CylinderUnitDto">
......
...@@ -121,7 +121,6 @@ ...@@ -121,7 +121,6 @@
or industry_supervisor is null or industry_supervisor is null
</if>) </if>)
</if> </if>
AND is_delete = 0
</where> </where>
order by rec_date desc order by rec_date desc
</select> </select>
......
...@@ -204,7 +204,7 @@ ...@@ -204,7 +204,7 @@
</select> </select>
<select id="selectByUseUnit" resultType="com.yeejoin.amos.boot.module.tcm.api.entity.TzBaseEnterpriseInfo"> <select id="selectByUseUnit" resultType="com.yeejoin.amos.boot.module.tcm.api.entity.TzBaseEnterpriseInfo">
select * from tz_base_enterprise_info where use_unit = #{useUnit} and is_delete = '0' select * from tz_base_enterprise_info where use_unit = #{useUnit}
</select> </select>
<select id="listNoQrCode" resultType="com.yeejoin.amos.boot.module.tcm.api.entity.TzBaseEnterpriseInfo"> <select id="listNoQrCode" resultType="com.yeejoin.amos.boot.module.tcm.api.entity.TzBaseEnterpriseInfo">
select select
...@@ -214,7 +214,6 @@ ...@@ -214,7 +214,6 @@
where where
(qr_code is null or LENGTH(qr_code) = 0) (qr_code is null or LENGTH(qr_code) = 0)
and use_code <![CDATA[<>]]> '' and use_code <![CDATA[<>]]> ''
and is_delete = '0'
limit 1000 limit 1000
</select> </select>
<select id="getEquipType" resultType="java.util.Map"> <select id="getEquipType" resultType="java.util.Map">
...@@ -306,7 +305,7 @@ ...@@ -306,7 +305,7 @@
<select id="selectCompanyBySupervisionOrgCode" resultType="java.lang.String"> <select id="selectCompanyBySupervisionOrgCode" resultType="java.lang.String">
select sequence_nbr select sequence_nbr
from tz_base_enterprise_info from tz_base_enterprise_info
where supervise_org_code LIKE CONCAT(#{oldOrgCode}, '%') and is_delete = '0' where supervise_org_code LIKE CONCAT(#{oldOrgCode}, '%')
</select> </select>
<update id="updateRedundantSupervisionOrgCodeUnit"> <update id="updateRedundantSupervisionOrgCodeUnit">
......
...@@ -212,7 +212,6 @@ ...@@ -212,7 +212,6 @@
WHERE tui.is_delete = 'f' WHERE tui.is_delete = 'f'
AND tui.amos_user_id is NOT null AND tui.amos_user_id is NOT null
AND tzei.unit_type IS NOT NULL AND tzei.unit_type IS NOT NULL
and tzei.is_delete = false
GROUP BY tui.amos_user_id GROUP BY tui.amos_user_id
</select> </select>
......
...@@ -32,7 +32,6 @@ ...@@ -32,7 +32,6 @@
tz_base_enterprise_info cu tz_base_enterprise_info cu
where where
cu.data_sources = '陕西省内企业' cu.data_sources = '陕西省内企业'
and cu.is_delete = false
AND cu.unit_type LIKE '%充装单位%' AND cu.unit_type LIKE '%充装单位%'
and cu.org_code like concat('%', #{regionCode}, '%') and cu.org_code like concat('%', #{regionCode}, '%')
GROUP BY strKey GROUP BY strKey
...@@ -86,7 +85,6 @@ ...@@ -86,7 +85,6 @@
RIGHT JOIN tz_cylinder_info t1 ON t1.app_id = i.app_id RIGHT JOIN tz_cylinder_info t1 ON t1.app_id = i.app_id
WHERE WHERE
i.data_sources = '陕西省内企业' i.data_sources = '陕西省内企业'
and i.is_delete = false
AND i.unit_type LIKE'%充装单位%' AND i.unit_type LIKE'%充装单位%'
AND i.industry_supervisor like concat(#{orgCode}, '%') AND i.industry_supervisor like concat(#{orgCode}, '%')
GROUP BY GROUP BY
...@@ -105,7 +103,6 @@ ...@@ -105,7 +103,6 @@
RIGHT JOIN tz_cylinder_info t1 ON t1.app_id = i.app_id RIGHT JOIN tz_cylinder_info t1 ON t1.app_id = i.app_id
WHERE WHERE
i.data_sources = '陕西省内企业' i.data_sources = '陕西省内企业'
and i.is_delete = false
AND i.unit_type LIKE'%充装单位%' AND i.unit_type LIKE'%充装单位%'
AND i.industry_supervisor like concat(#{orgCode}, '%') AND i.industry_supervisor like concat(#{orgCode}, '%')
GROUP BY GROUP BY
...@@ -131,7 +128,6 @@ ...@@ -131,7 +128,6 @@
tz_base_enterprise_info i tz_base_enterprise_info i
WHERE WHERE
i.data_sources = '陕西省内企业' i.data_sources = '陕西省内企业'
and i.is_delete = false
AND i.unit_type LIKE'%充装单位%' AND i.unit_type LIKE'%充装单位%'
<if test="orgCodes != null and orgCodes.size > 0"> <if test="orgCodes != null and orgCodes.size > 0">
AND AND
...@@ -157,7 +153,6 @@ ...@@ -157,7 +153,6 @@
AND u.unit_type LIKE'%充装单位%' AND u.unit_type LIKE'%充装单位%'
AND ui.post like '%6552%' AND ui.post like '%6552%'
and ui.is_delete = false and ui.is_delete = false
and u.is_delete = false
<if test="orgCodes != null and orgCodes.size > 0"> <if test="orgCodes != null and orgCodes.size > 0">
AND AND
<foreach collection="orgCodes" open="(" item="orgCode" close=")" separator=" or "> <foreach collection="orgCodes" open="(" item="orgCode" close=")" separator=" or ">
......
...@@ -247,7 +247,7 @@ ...@@ -247,7 +247,7 @@
</select> </select>
<select id="selectByUseUnit" resultType="com.yeejoin.amos.boot.module.ymt.api.entity.TzBaseEnterpriseInfo"> <select id="selectByUseUnit" resultType="com.yeejoin.amos.boot.module.ymt.api.entity.TzBaseEnterpriseInfo">
select * from tz_base_enterprise_info where use_unit = #{useUnit} AND is_delete = '0' select * from tz_base_enterprise_info where use_unit = #{useUnit}
</select> </select>
<select id="getInspectionUnitList" resultType="com.yeejoin.amos.boot.module.ymt.api.dto.TzBaseEnterpriseInfoDto"> <select id="getInspectionUnitList" resultType="com.yeejoin.amos.boot.module.ymt.api.dto.TzBaseEnterpriseInfoDto">
SELECT SELECT
...@@ -261,7 +261,6 @@ ...@@ -261,7 +261,6 @@
tz_base_enterprise_info info tz_base_enterprise_info info
inner JOIN tz_jyjc_opening_application tjoa ON info.use_code = tjoa.unit_code inner JOIN tz_jyjc_opening_application tjoa ON info.use_code = tjoa.unit_code
AND tjoa.status = '已完成' AND tjoa.status = '已完成'
AND info.is_delete = '0'
<if test="openBizType != null and openBizType !=''"> <if test="openBizType != null and openBizType !=''">
and tjoa.open_biz_type = #{openBizType} and tjoa.open_biz_type = #{openBizType}
</if> </if>
...@@ -275,8 +274,6 @@ ...@@ -275,8 +274,6 @@
concat(info.use_unit_code,'_',info.use_unit) as useCodeAndName concat(info.use_unit_code,'_',info.use_unit) as useCodeAndName
FROM FROM
tz_base_enterprise_info info tz_base_enterprise_info info
where
is_delete = '0'
</sql> </sql>
<select id="getInspectionUnitListByCode" resultType="com.yeejoin.amos.boot.module.ymt.api.dto.TzBaseEnterpriseInfoDto"> <select id="getInspectionUnitListByCode" resultType="com.yeejoin.amos.boot.module.ymt.api.dto.TzBaseEnterpriseInfoDto">
<include refid="unit-list-info" /> <include refid="unit-list-info" />
...@@ -366,8 +363,7 @@ ...@@ -366,8 +363,7 @@
a.supervise_org_code as label a.supervise_org_code as label
FROM FROM
"tz_base_enterprise_info" a "tz_base_enterprise_info" a
where a.is_delete = '0' group by a.unit_type,a.supervise_org_code
group by a.unit_type,a.supervise_org_code
</select> </select>
<select id="countByOperatingStatusAndOrgCode" resultType="java.lang.Long"> <select id="countByOperatingStatusAndOrgCode" resultType="java.lang.Long">
SELECT SELECT
...@@ -376,7 +372,6 @@ ...@@ -376,7 +372,6 @@
"tz_base_enterprise_info" "tz_base_enterprise_info"
where where
1=1 1=1
and is_delete = '0'
and ((supervise_org_code != '50' and supervise_org_code LIKE CONCAT (#{orgCode}, '%')) or (supervise_org_code = '50' and office_region LIKE CONCAT ('%', #{cityCode}, '%'))) and ((supervise_org_code != '50' and supervise_org_code LIKE CONCAT (#{orgCode}, '%')) or (supervise_org_code = '50' and office_region LIKE CONCAT ('%', #{cityCode}, '%')))
and and
<foreach collection="operatingStatus" item="status" separator="or" open="(" close=")"> <foreach collection="operatingStatus" item="status" separator="or" open="(" close=")">
...@@ -398,7 +393,6 @@ ...@@ -398,7 +393,6 @@
FROM tz_base_unit_licence tbul FROM tz_base_unit_licence tbul
JOIN tz_base_enterprise_info tbei ON tbul.unit_Code = tbei.use_unit_code JOIN tz_base_enterprise_info tbei ON tbul.unit_Code = tbei.use_unit_code
WHERE 1 = 1 WHERE 1 = 1
and tbei.is_delete = '0'
<if test="operator != null and operator !='' "> <if test="operator != null and operator !='' ">
AND tbul.expiry_date ${operator} CURRENT_DATE AND tbul.expiry_date ${operator} CURRENT_DATE
</if> </if>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment