Commit 586591c6 authored by suhuiguang's avatar suhuiguang

Merge branch 'develop_tzs_register' into develop_tzs_test

parents a84d2d6f 4e21f174
...@@ -17,28 +17,6 @@ ...@@ -17,28 +17,6 @@
<select id="queryListByQueryDto" resultType="java.util.Map"> <select id="queryListByQueryDto" resultType="java.util.Map">
SELECT SELECT
r.sequence_nbr AS sequenceNbr, r.sequence_nbr AS sequenceNbr,
-- r.filling_unit_name AS fillingUnitName,
-- r.factory_num AS factoryNum,
-- CASE
-- i.cylinder_variety
-- WHEN 1 THEN
-- '无缝气瓶'
-- WHEN 2 THEN
-- '焊接气瓶'
-- WHEN 3 THEN
-- '缠绕气瓶'
-- WHEN 4 THEN
-- '绝热气瓶'
-- WHEN 5 THEN
-- '内装填料气瓶'
-- ELSE
-- ''
-- END AS cylinderVariety,
-- i.qrCode AS qrCode,
-- i.electronic_label_code AS electronicLabelCode,
-- r.sequence_code AS sequenceCode,
-- i.unit_inner_code AS unitInnerCode,
-- u.unit_name AS propertyUnit,
r.filling_startTime AS fillingStarttime, r.filling_startTime AS fillingStarttime,
r.filling_endTime AS fillingEndtime, r.filling_endTime AS fillingEndtime,
r.filling_user AS fillingUser, r.filling_user AS fillingUser,
...@@ -92,18 +70,6 @@ ...@@ -92,18 +70,6 @@
<if test="appId != null and appId != ''"> <if test="appId != null and appId != ''">
AND r.app_id = #{appId} AND r.app_id = #{appId}
</if> </if>
<!-- <if test="fillingUnitName != null and fillingUnitName != ''">-->
<!-- AND r.filling_unit_name like-->
<!-- CONCAT(CONCAT('%',#{fillingUnitName}),'%')-->
<!-- </if>-->
<!-- <if test="propertyUnit != null and propertyUnit != ''">-->
<!-- AND u.unit_name like-->
<!-- CONCAT(CONCAT('%',#{propertyUnit}),'%')-->
<!-- </if>-->
<!-- <if test="factoryNum != null and factoryNum != ''">-->
<!-- AND r.factory_num like-->
<!-- CONCAT(CONCAT('%',#{factoryNum}),'%')-->
<!-- </if>-->
<if test="fillingStartTime != null "> <if test="fillingStartTime != null ">
and #{fillingStartTime} <![CDATA[ <= ]]> and #{fillingStartTime} <![CDATA[ <= ]]>
r.filling_startTime r.filling_startTime
...@@ -112,24 +78,6 @@ ...@@ -112,24 +78,6 @@
and r.filling_endTime <![CDATA[ <= ]]> and r.filling_endTime <![CDATA[ <= ]]>
#{fillingEndTime} #{fillingEndTime}
</if> </if>
<!-- <if test="cylinderVariety != null and cylinderVariety != ''">-->
<!-- AND i.cylinder_variety = #{cylinderVariety}-->
<!-- </if>-->
<!-- <if test="qrCode != null and qrCode != ''">-->
<!-- AND i.qrCode like CONCAT(CONCAT('%',#{qrCode}),'%')-->
<!-- </if>-->
<!-- <if test="electronicLabelCode != null and electronicLabelCode != ''">-->
<!-- AND i.electronic_label_code like-->
<!-- CONCAT(CONCAT('%',#{electronicLabelCode}),'%')-->
<!-- </if>-->
<!-- <if test="sequenceCode != null and sequenceCode != ''">-->
<!-- AND r.sequence_code like-->
<!-- CONCAT(CONCAT('%',#{sequenceCode}),'%')-->
<!-- </if>-->
<!-- <if test="unitInnerCode != null and unitInnerCode != ''">-->
<!-- AND i.unit_inner_code like-->
<!-- CONCAT(CONCAT('%',#{unitInnerCode}),'%')-->
<!-- </if>-->
<if test="sortParam != null and sortParam != '' and sortRule != null and sortRule != '' "> <if test="sortParam != null and sortParam != '' and sortRule != null and sortRule != '' ">
ORDER BY ${sortParam} ${sortRule} ORDER BY ${sortParam} ${sortRule}
</if> </if>
......
...@@ -146,97 +146,6 @@ ...@@ -146,97 +146,6 @@
joi.RECORD joi.RECORD
</where> </where>
</select> </select>
<!-- <select id="selectExportDataNew" resultType="com.yeejoin.amos.boot.module.elevator.api.dto.ElevatorDtoNew">-->
<!-- SELECT joi.CODE96333 AS rescueCode,-->
<!-- jri.EQU_CODE AS registerCode,-->
<!-- jui.PROVINCE_NAME AS province,-->
<!-- jui.CITY_NAME AS city,-->
<!-- jui.COUNTY_NAME AS district,-->
<!-- concat(jui.PROVINCE, '#', jui.CITY, '#', jui.COUNTY) AS regionCode,-->
<!-- jui.ADDRESS AS address,-->
<!-- jui.USE_INNER_CODE AS innerNum,-->
<!-- jri.BRAND_NAME AS brand,-->
<!-- jfi.FACTORY_NUM AS factoryNum,-->
<!-- (SELECT GROUP_CONCAT(USC_UNIT_NAME)-->
<!-- FROM idx_biz_jg_construction_info-->
<!-- WHERE RECORD = jui.RECORD-->
<!-- and CONSTRUCTION_TYPE = '6030') AS installationUnit,-->
<!-- ifnull ( CAST(jfi.PRODUCE_DATE as VARCHAR ), '' ) AS factoryDate,-->
<!-- ifnull ((SELECT CAST(USC_DATE as VARCHAR )-->
<!-- FROM idx_biz_jg_construction_info-->
<!-- WHERE RECORD = jui.RECORD-->
<!-- and CONSTRUCTION_TYPE = '6031'-->
<!-- ORDER BY USC_DATE DESC LIMIT 1 ), '' ) AS overhaulDate,-->
<!-- ifnull ( CAST(jui.USE_DATE as VARCHAR ), '' ) AS startUseDate,-->
<!-- (SELECT name from tz_equipment_category WHERE code = jri.EQU_LIST) AS categoryName,-->
<!-- (SELECT name from cb_data_dictionary WHERE code = jui.USE_PLACE and type = 'ADDRESS' ) AS useSiteCategory,-->
<!-- jri.EQU_TYPE AS model,-->
<!-- tpe.STOREY AS floors,-->
<!-- tpe.STAND AS stations,-->
<!-- tpe.NUMBER_DOORS AS doors,-->
<!-- tpe.RATED_SPEED_UP AS ratedSpeed,-->
<!-- tpe.RATED_LOAD_CAPACITY AS ratedLoad,-->
<!-- '' AS maxPersonLoad,-->
<!-- tpe.LIFTING_HEIGHT AS raiseHeight,-->
<!-- tpe.CONTROL_MODE AS dragModeName,-->
<!-- case-->
<!-- WHEN jui.EQU_STATE = 0 then '未登记'-->
<!-- WHEN jui.EQU_STATE = 1 then '在用'-->
<!-- WHEN jui.EQU_STATE = 2 then '停用'-->
<!-- WHEN jui.EQU_STATE = 3 then '报废'-->
<!-- WHEN jui.EQU_STATE = 4 then '注销'-->
<!-- ELSE ''-->
<!-- END AS useStatus,-->
<!-- jui.USE_UNIT_NAME AS useUnit,-->
<!-- jfi.PRODUCE_UNIT_NAME AS manufacturerName,-->
<!-- jfi.PRODUCE_LICENSE_NUM AS manufacturingLicense,-->
<!-- '' AS maintainTypeName,-->
<!-- '' AS maintainLeaderPhone,-->
<!-- '' AS hostModel,-->
<!-- '' AS hostNum,-->
<!-- '' AS engineType,-->
<!-- '' AS engineNum,-->
<!-- '' AS panelModel,-->
<!-- '' AS panelNum,-->
<!-- '' AS cascadeModel,-->
<!-- '' AS cascadeLineModel,-->
<!-- '' AS handrailType,-->
<!-- '' AS handrailPanelModel,-->
<!-- '' AS handrailPanelBrand,-->
<!-- '' AS rollerMode,-->
<!-- '' AS tiltAngle,-->
<!-- '' AS horizontalSpan,-->
<!-- '' AS runningNoise,-->
<!-- '' AS runningMode,-->
<!-- '' AS runningVibration,-->
<!-- '' AS power,-->
<!-- ifnull ( jui."LONGITUDE_LATITUDE"::json->> 'latitude', '' ) AS latitude,-->
<!-- ifnull ( jui."LONGITUDE_LATITUDE"::json->> 'longitude', '' ) AS longitude,-->
<!-- (SELECT ME_CYCLE FROM idx_biz_jg_maintenance_record_info WHERE RECORD = jui.RECORD ORDER BY REC_DATE DESC limit-->
<!-- 1) as maintainPeriodName,-->
<!-- (SELECT ME_UNIT_NAME FROM idx_biz_jg_maintenance_record_info WHERE RECORD = jui.RECORD ORDER BY REC_DATE DESC-->
<!-- limit 1) as maintainUnit,-->
<!-- (SELECT ME_MASTER FROM idx_biz_jg_maintenance_record_info WHERE RECORD = jui.RECORD ORDER BY REC_DATE DESC limit-->
<!-- 1) as maintainLeader,-->
<!-- jui.RECORD AS sequenceNbr-->
<!-- FROM idx_biz_jg_register_info jri-->
<!-- LEFT JOIN idx_biz_jg_other_info joi ON jri.RECORD = joi.RECORD-->
<!-- LEFT JOIN idx_biz_jg_use_info jui ON jri.RECORD = jui.RECORD-->
<!-- LEFT JOIN idx_biz_jg_factory_info jfi ON jri.RECORD = jfi.RECORD-->
<!-- LEFT JOIN idx_biz_jg_tech_params_elevator tpe ON tpe.RECORD = jfi.RECORD-->
<!-- WHERE jri.EQU_LIST = '3000'-->
<!-- <if test="ids != null and ids.size() > 0">-->
<!-- and jui.RECORD in-->
<!-- <foreach item="item" collection="ids" separator="," open="(" close=")" index="">#{item}-->
<!-- </foreach>-->
<!-- </if>-->
<!-- </select>-->
<select id="selectByRecord" resultType="java.util.Map"> <select id="selectByRecord" resultType="java.util.Map">
SELECT joi.CODE96333 AS rescueCode, SELECT joi.CODE96333 AS rescueCode,
jri.EQU_CODE AS registerCode, jri.EQU_CODE AS registerCode,
......
...@@ -24,9 +24,6 @@ ...@@ -24,9 +24,6 @@
#{item} #{item}
</foreach> </foreach>
</if> </if>
<!-- <if test="bizType=='yingjian'">-->
<!-- AND b.SEQUENCE_NBR is null-->
<!-- </if>-->
<if test="bizType=='yijian'"> <if test="bizType=='yijian'">
AND b.SEQUENCE_NBR is not null AND b.SEQUENCE_NBR is not null
</if> </if>
...@@ -55,9 +52,6 @@ ...@@ -55,9 +52,6 @@
#{item} #{item}
</foreach> </foreach>
</if> </if>
<!-- <if test="bizType=='yingjian'">-->
<!-- AND b.SEQUENCE_NBR is null-->
<!-- </if>-->
<if test="bizType=='yijian'"> <if test="bizType=='yijian'">
AND b.SEQUENCE_NBR is not null AND b.SEQUENCE_NBR is not null
</if> </if>
......
...@@ -44,9 +44,6 @@ ...@@ -44,9 +44,6 @@
ci.longitude, ci.longitude,
ci.latitude, ci.latitude,
eu.address, eu.address,
-- eu.custom_name,
-- eu.custom_type,
-- eu.contact_phone,
cu.person_mobile_phone, cu.person_mobile_phone,
cu.unit_person cu.unit_person
from from
......
...@@ -45,4 +45,6 @@ public class TZSCommonConstant { ...@@ -45,4 +45,6 @@ public class TZSCommonConstant {
*/ */
public static final String EQU_CATEGORY_CODE_GDYLRQ = "2100"; public static final String EQU_CATEGORY_CODE_GDYLRQ = "2100";
public static final String SX_PROVINCE_CODE = "610000";
} }
...@@ -59,6 +59,7 @@ public class DataRefreshListener { ...@@ -59,6 +59,7 @@ public class DataRefreshListener {
while (true) { while (true) {
try { try {
DataRefreshEvent event = queue.take(); DataRefreshEvent event = queue.take();
log.warn("数据刷新本地消息表,队列积压数量:{}", queue.size());
processEvent(event); processEvent(event);
} catch (Exception e) { } catch (Exception e) {
log.error(e.getMessage(), e); log.error(e.getMessage(), e);
......
...@@ -2789,7 +2789,7 @@ ...@@ -2789,7 +2789,7 @@
WHERE WHERE
tup.expiry_date <![CDATA[<]]> CURRENT_DATE tup.expiry_date <![CDATA[<]]> CURRENT_DATE
AND tup.permission_post IN ('permissionData66151', 'permissionData66152', 'permissionData6552') AND tup.permission_post IN ('permissionData66151', 'permissionData66152', 'permissionData6552')
and ei.s_delete = '0' and ei.is_delete = '0'
</select> </select>
<select id="queryAllCompanyDict" resultType="com.yeejoin.amos.boot.biz.common.dto.KeyValueDto"> <select id="queryAllCompanyDict" resultType="com.yeejoin.amos.boot.biz.common.dto.KeyValueDto">
select select
......
...@@ -365,7 +365,6 @@ ...@@ -365,7 +365,6 @@
(select name from tz_equipment_category where code = ri."EQU_CATEGORY") equCategoryName, (select name from tz_equipment_category where code = ri."EQU_CATEGORY") equCategoryName,
ri."EQU_DEFINE" equDefine, ri."EQU_DEFINE" equDefine,
(select name from tz_equipment_category where code = ri."EQU_DEFINE") equDefineName, (select name from tz_equipment_category where code = ri."EQU_DEFINE") equDefineName,
-- 历史遗留问题 故 as
pp."PIPE_NAME" as productName, pp."PIPE_NAME" as productName,
ri."BRAND_NAME" brandName, ri."BRAND_NAME" brandName,
ri."EQU_TYPE" equType, ri."EQU_TYPE" equType,
......
...@@ -300,7 +300,6 @@ ...@@ -300,7 +300,6 @@
<if test="projectContraptionSeq != null and projectContraptionSeq != ''"> <if test="projectContraptionSeq != null and projectContraptionSeq != ''">
and ui."PROJECT_CONTRAPTION_ID" = #{projectContraptionSeq} and ui."PROJECT_CONTRAPTION_ID" = #{projectContraptionSeq}
</if> </if>
-- 排除 已经做过安装告知的
AND NOT EXISTS ( AND NOT EXISTS (
SELECT 1 SELECT 1
FROM FROM
......
...@@ -213,7 +213,6 @@ ...@@ -213,7 +213,6 @@
<select id="getListPage" resultType="java.util.Map"> <select id="getListPage" resultType="java.util.Map">
SELECT * FROM ( SELECT * FROM (
-- 查询 equListCode != '8000' 的情况
SELECT * SELECT *
FROM ( FROM (
<include refid="page-list-sub-select"/> <include refid="page-list-sub-select"/>
...@@ -291,7 +290,6 @@ ...@@ -291,7 +290,6 @@
</where> </where>
UNION ALL UNION ALL
-- 查询 equListCode == '8000' 的情况
SELECT * SELECT *
FROM ( FROM (
<include refid="page-list-sub-pipline"/> <include refid="page-list-sub-pipline"/>
...@@ -771,8 +769,6 @@ ...@@ -771,8 +769,6 @@
AND (use_unit_credit_code = #{dto.unitCode} or transfer_to_user_ids LIKE concat ('%',#{dto.currentUserId}, '%')) AND (use_unit_credit_code = #{dto.unitCode} or transfer_to_user_ids LIKE concat ('%',#{dto.currentUserId}, '%'))
</if> </if>
</where> </where>
-- GROUP BY
-- re.equip_transfer_id
order by order by
create_date DESC, applyNo DESC create_date DESC, applyNo DESC
</select> </select>
...@@ -859,8 +855,6 @@ ...@@ -859,8 +855,6 @@
concat(tzi.sequence_nbr,'_',SAFETY_MANAGER) as safetyManagerSeq, concat(tzi.sequence_nbr,'_',SAFETY_MANAGER) as safetyManagerSeq,
ibjui."PHONE" as phone, ibjui."PHONE" as phone,
concat(ibjui.ESTATE_UNIT_CREDIT_CODE, '_', ibjui.ESTATE_UNIT_NAME) as estateUnitName, concat(ibjui.ESTATE_UNIT_CREDIT_CODE, '_', ibjui.ESTATE_UNIT_NAME) as estateUnitName,
-- ESTATE_UNIT_NAME as estateUnitName,
-- ESTATE_UNIT_CREDIT_CODE as estateUnitCreditCode,
ibjui.ADDRESS as address, ibjui.ADDRESS as address,
ibjui.PROVINCE as province, ibjui.PROVINCE as province,
ibjui.CITY as city, ibjui.CITY as city,
...@@ -1106,7 +1100,6 @@ ...@@ -1106,7 +1100,6 @@
(select name from tz_equipment_category where code = ri."EQU_CATEGORY") equCategoryName, (select name from tz_equipment_category where code = ri."EQU_CATEGORY") equCategoryName,
ri."EQU_DEFINE" equDefine, ri."EQU_DEFINE" equDefine,
(select name from tz_equipment_category where code = ri."EQU_DEFINE") equDefineName, (select name from tz_equipment_category where code = ri."EQU_DEFINE") equDefineName,
-- 历史遗留问题 故 as
pp."PIPE_NAME" as productName, pp."PIPE_NAME" as productName,
ri."BRAND_NAME" brandName, ri."BRAND_NAME" brandName,
ri."EQU_TYPE" equType, ri."EQU_TYPE" equType,
...@@ -1667,7 +1660,6 @@ ...@@ -1667,7 +1660,6 @@
<foreach collection="projectContraptionSeqList" item="item" open="(" separator="," close=")"> <foreach collection="projectContraptionSeqList" item="item" open="(" separator="," close=")">
#{item} #{item}
</foreach> </foreach>
--AND ui.IS_INTO_MANAGEMENT = true
ORDER BY ui.REC_DATE DESC ORDER BY ui.REC_DATE DESC
) )
</select> </select>
......
...@@ -65,6 +65,11 @@ ...@@ -65,6 +65,11 @@
"name": "补证登记", "name": "补证登记",
"code": "DJ_BZ", "code": "DJ_BZ",
"image": "upload/tzs/common/image/补证登记.png" "image": "upload/tzs/common/image/补证登记.png"
},
{
"name": "超设计使用年限变更",
"code": "DJ_CSJ",
"image": "upload/tzs/common/image/超设计使用年限.png"
} }
], ],
"WBBA": [ "WBBA": [
......
...@@ -132,4 +132,15 @@ public interface BizCommonConstant { ...@@ -132,4 +132,15 @@ public interface BizCommonConstant {
* 西安 * 西安
*/ */
String XA_ORG_CODE = "50*52"; String XA_ORG_CODE = "50*52";
/**
* 开通区域平台字典
*/
String OPEN_REGION_CODE_DICT_KEY = "CITY_REGION_WITH_SPECIAL";
/**
* 检验机构分类
*/
String JYJGFL_DICT_KEY = "JYJGFL";
} }
...@@ -47,6 +47,13 @@ public class JyjcOpeningApplication extends BaseEntity { ...@@ -47,6 +47,13 @@ public class JyjcOpeningApplication extends BaseEntity {
private List<String> detectionRegion; private List<String> detectionRegion;
/** /**
* 排除的区域
*/
@TableField(value = "exclusion_region", typeHandler = FastjsonTypeHandler.class)
private List<String> exclusionRegion;
/**
* 检测区域名称(冗余) * 检测区域名称(冗余)
*/ */
@TableField("detection_region_name") @TableField("detection_region_name")
......
...@@ -18,7 +18,7 @@ public enum OpenBizTypeEnumV2 { ...@@ -18,7 +18,7 @@ public enum OpenBizTypeEnumV2 {
JC("jc", "检测机构", "检测业务"), JC("jc", "检测机构", "检测业务"),
SYDW("jc-sydw", "使用单位", "使用单位电梯检测"), SYDW("jc-sydw", "使用单位", "使用单位电梯检测"),
AGW("jc-agw", "安装改造维修单位", "安改维电梯检测"); AGW("jc-agw", "安装改造维修单位", "安改维电梯检测");
private String code; private final String code;
private final String unitType; private final String unitType;
......
package com.yeejoin.amos.boot.module.jyjc.api.model;
import lombok.Data;
import lombok.EqualsAndHashCode;
import java.util.List;
@EqualsAndHashCode(callSuper = true)
@Data
public class JyjcBizManageModel extends JyjcOpeningApplicationModel {
/**
* 区域停(启)用状态
*/
private String areaStatus;
/**
* 公司code
*/
private String companyCode;
/**
* 机构分类名称
*/
private String agencyClassifyName;
/**
* 新开通区域
*/
private List<String> newDetectionRegion;
/**
* 是否启用登录人区域-是否开通
*/
private Boolean logUserEnable;
}
...@@ -39,7 +39,13 @@ public class JyjcOpeningApplicationModel extends BaseModel { ...@@ -39,7 +39,13 @@ public class JyjcOpeningApplicationModel extends BaseModel {
@TableField(value = "detection_region", typeHandler = FastjsonTypeHandler.class) @TableField(value = "detection_region", typeHandler = FastjsonTypeHandler.class)
private List<String> detectionRegion; private List<String> detectionRegion;
@ApiModelProperty(value = "检测区域名称(冗余)") @ApiModelProperty(value = "排除的区域编码")
private List<String> exclusionRegion;
@ApiModelProperty(value = "排除的区域名称")
private String exclusionRegionName;
@ApiModelProperty(value = "检测区域名称")
private String detectionRegionName; private String detectionRegionName;
@ApiModelProperty(value = "申请单号") @ApiModelProperty(value = "申请单号")
......
...@@ -311,7 +311,6 @@ ...@@ -311,7 +311,6 @@
group by a.inspection_type group by a.inspection_type
</select> </select>
<select id="queryAppByEquListForDP" resultType="com.yeejoin.amos.boot.biz.common.dto.CountDto"> <select id="queryAppByEquListForDP" resultType="com.yeejoin.amos.boot.biz.common.dto.CountDto">
-- 8大类 待检数量
SELECT SELECT
count(1) as longValue, count(1) as longValue,
a.equip_classify as keyStr, a.equip_classify as keyStr,
...@@ -326,7 +325,6 @@ ...@@ -326,7 +325,6 @@
and EXISTS (select 1 from tz_jyjc_inspection_result r where r.result_status='1' and a.application_no = r.application_no) and EXISTS (select 1 from tz_jyjc_inspection_result r where r.result_status='1' and a.application_no = r.application_no)
and date_ge(CAST(a.accept_date as date),#{dto.beginDate}) and date_le(CAST(a.accept_date as date),#{dto.endDate}) and date_ge(CAST(a.accept_date as date),#{dto.beginDate}) and date_le(CAST(a.accept_date as date),#{dto.endDate})
GROUP BY a.equip_classify GROUP BY a.equip_classify
-- 8大类 报检数量统计
union all union all
SELECT SELECT
count(1) as longValue, count(1) as longValue,
...@@ -714,7 +712,6 @@ ...@@ -714,7 +712,6 @@
(select name from tz_equipment_category where code = ri."EQU_CATEGORY") equCategoryName, (select name from tz_equipment_category where code = ri."EQU_CATEGORY") equCategoryName,
ri."EQU_DEFINE" equDefine, ri."EQU_DEFINE" equDefine,
(select name from tz_equipment_category where code = ri."EQU_DEFINE") equDefineName, (select name from tz_equipment_category where code = ri."EQU_DEFINE") equDefineName,
-- 历史遗留问题 故 as
pp."PIPE_NAME" as productName, pp."PIPE_NAME" as productName,
ri."BRAND_NAME" brandName, ri."BRAND_NAME" brandName,
ri."EQU_TYPE" equType, ri."EQU_TYPE" equType,
...@@ -762,7 +759,6 @@ ...@@ -762,7 +759,6 @@
(select name from tz_equipment_category where code = ri."EQU_CATEGORY") equCategoryName, (select name from tz_equipment_category where code = ri."EQU_CATEGORY") equCategoryName,
ri."EQU_DEFINE" equDefine, ri."EQU_DEFINE" equDefine,
(select name from tz_equipment_category where code = ri."EQU_DEFINE") equDefineName, (select name from tz_equipment_category where code = ri."EQU_DEFINE") equDefineName,
-- 历史遗留问题 故 as
pp."PIPE_NAME" as productName, pp."PIPE_NAME" as productName,
ri."BRAND_NAME" brandName, ri."BRAND_NAME" brandName,
ri."EQU_TYPE" equType, ri."EQU_TYPE" equType,
......
...@@ -34,16 +34,13 @@ public class ElasticSearchClientConfig { ...@@ -34,16 +34,13 @@ public class ElasticSearchClientConfig {
try { try {
HttpHost[] httpHosts = Arrays.stream(uris.split(",")).map(HttpHost::create).toArray(HttpHost[]::new); HttpHost[] httpHosts = Arrays.stream(uris.split(",")).map(HttpHost::create).toArray(HttpHost[]::new);
RestClientBuilder builder = RestClient.builder(httpHosts); RestClientBuilder builder = RestClient.builder(httpHosts);
builder.setHttpClientConfigCallback(httpClientBuilder -> { builder.setHttpClientConfigCallback(httpClientBuilder -> httpClientBuilder.setDefaultCredentialsProvider(credentialsProvider));
httpClientBuilder.disableAuthCaching();
return httpClientBuilder.setDefaultCredentialsProvider(credentialsProvider);
});
// 该方法接收一个RequestConfig.Builder对象,对该对象进行修改后然后返回。 // 该方法接收一个RequestConfig.Builder对象,对该对象进行修改后然后返回。
builder.setRequestConfigCallback(requestConfigBuilder -> { builder.setRequestConfigCallback(requestConfigBuilder -> {
// 连接超时(默认为1秒) // 连接超时(默认为1秒)
return requestConfigBuilder.setConnectTimeout(5000 * 1000) return requestConfigBuilder.setConnectTimeout(60 * 1000)
// 套接字超时(默认为30秒)//更改客户端的超时限制默认30秒现在改为100*1000分钟 // 套接字超时(默认为30秒)
.setSocketTimeout(6000 * 1000); .setSocketTimeout(60 * 1000);
}); });
return new RestHighLevelClient(builder); return new RestHighLevelClient(builder);
......
package com.yeejoin.amos.boot.module.jyjc.biz.controller;
import com.alibaba.fastjson.JSONObject;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.yeejoin.amos.boot.biz.common.controller.BaseController;
import com.yeejoin.amos.boot.module.jyjc.api.model.JyjcBizManageModel;
import com.yeejoin.amos.boot.module.jyjc.biz.service.impl.JyjcBizManageServiceImpl;
import com.yeejoin.amos.boot.module.ymt.api.entity.BaseUnitLicence;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.RequiredArgsConstructor;
import org.springframework.web.bind.annotation.*;
import org.typroject.tyboot.component.event.RestEventTrigger;
import org.typroject.tyboot.core.foundation.enumeration.UserType;
import org.typroject.tyboot.core.restful.doc.TycloudOperation;
import org.typroject.tyboot.core.restful.utils.ResponseHelper;
import org.typroject.tyboot.core.restful.utils.ResponseModel;
import java.util.List;
import java.util.Map;
@RestController
@RequestMapping(value = "/jyjcBizManage")
@Api(tags = "检验检测业务管理")
@RequiredArgsConstructor
public class JyjcBizManageController extends BaseController {
private final JyjcBizManageServiceImpl jyjcBizManageService;
@TycloudOperation(ApiLevel = UserType.AGENCY)
@PostMapping(value = "/page")
@ApiOperation(httpMethod = "POST", value = "检验检测机构开通业务列表分页-省市局使用", notes = "检验检测机构开通业务分页-省市局使用")
public ResponseModel<IPage<?>> getManageList(@RequestParam(value = "current") int current,
@RequestParam(value = "size") int size,
@RequestBody JyjcBizManageModel model) {
Page<JyjcBizManageModel> page = new Page<>(current, size);
IPage<?> res = jyjcBizManageService.pageList(page, getSelectedOrgInfo().getCompany(), model);
return ResponseHelper.buildResponse(res);
}
@TycloudOperation(ApiLevel = UserType.AGENCY)
@PutMapping(value = "/{appSeq}/area-enable")
@ApiOperation(httpMethod = "PUT", value = "企业区域启用-市局使用", notes = "企业区域启用-市局使用")
@RestEventTrigger(value = "operateLogRestEventHandler")
public ResponseModel<Boolean> enableBatch(@PathVariable String appSeq) {
return ResponseHelper.buildResponse(jyjcBizManageService.enable(appSeq, getSelectedOrgInfo().getCompany()));
}
@TycloudOperation(ApiLevel = UserType.AGENCY)
@PutMapping(value = "/{appSeq}/area-disable")
@ApiOperation(httpMethod = "PUT", value = "企业区域停用-市局使用", notes = "企业区域停用-市局使用")
@RestEventTrigger(value = "operateLogRestEventHandler")
public ResponseModel<Boolean> disableBatch(@PathVariable String appSeq) {
return ResponseHelper.buildResponse(jyjcBizManageService.disable(appSeq, getSelectedOrgInfo().getCompany()));
}
@TycloudOperation(ApiLevel = UserType.AGENCY)
@PostMapping(value = "/{appSeq}/licence")
@ApiOperation(httpMethod = "POST", value = "资质停起用-省局使用", notes = "资质停起用-省局使用")
@RestEventTrigger(value = "operateLogRestEventHandler")
public ResponseModel<Boolean> licenceEdit(@PathVariable String appSeq,
@RequestBody Map<String, Object> updateDto) {
List<BaseUnitLicence> lis = JSONObject.parseArray(JSONObject.toJSONString(updateDto.get("licences")), BaseUnitLicence.class);
return ResponseHelper.buildResponse(jyjcBizManageService.licenceEdit(appSeq, lis));
}
@TycloudOperation(ApiLevel = UserType.AGENCY)
@GetMapping(value = "/{appSeq}/basic")
@ApiOperation(httpMethod = "GET", value = "开通基本信息", notes = "开通基本信息")
public ResponseModel<JyjcBizManageModel> getBasicInfo(@PathVariable String appSeq) {
return ResponseHelper.buildResponse(jyjcBizManageService.getBasicInfo(appSeq));
}
@TycloudOperation(ApiLevel = UserType.AGENCY)
@GetMapping(value = "/{appSeq}/licence")
@ApiOperation(httpMethod = "GET", value = "资质详情-省局使用", notes = "资质详情-省局使用")
public ResponseModel<Map<String, Object>> licenceDetail(@PathVariable String appSeq) {
return ResponseHelper.buildResponse(jyjcBizManageService.licenceDetail(appSeq));
}
@TycloudOperation(ApiLevel = UserType.AGENCY)
@PutMapping(value = "/{appSeq}/expireDate")
@ApiOperation(httpMethod = "PUT", value = "业务有效期维护-省局使用", notes = "业务有效期维护-省局使用")
@RestEventTrigger(value = "operateLogRestEventHandler")
public ResponseModel<Boolean> expireDateEdit(@PathVariable String appSeq,
@RequestParam String newExpiryDate) {
return ResponseHelper.buildResponse(jyjcBizManageService.expireDateEdit(appSeq, newExpiryDate));
}
@TycloudOperation(ApiLevel = UserType.AGENCY)
@GetMapping(value = "/{appSeq}/detail")
@ApiOperation(httpMethod = "GET", value = "开通详情", notes = "开通详情")
public ResponseModel<Map<String, Object>> getOne(@PathVariable String appSeq) {
return ResponseHelper.buildResponse(jyjcBizManageService.getOne(appSeq));
}
@TycloudOperation(ApiLevel = UserType.AGENCY)
@GetMapping(value = "/region/{appSeq}/detail")
@ApiOperation(httpMethod = "GET", value = "启用停用区域详情-省局使用", notes = "启用停用区域详情-省局使用")
public ResponseModel<Map<String, Object>> regionDetail(@PathVariable String appSeq) {
return ResponseHelper.buildResponse(jyjcBizManageService.regionDetail(appSeq));
}
@TycloudOperation(ApiLevel = UserType.AGENCY)
@PutMapping(value = "/region/{appSeq}/status")
@ApiOperation(httpMethod = "PUT", value = "启用停用区域维护-省局使用", notes = "启用停用区域维护-省局使用")
@RestEventTrigger(value = "operateLogRestEventHandler")
public ResponseModel<Boolean> regionStatusEdit(@PathVariable String appSeq,
@RequestBody Map<String, Object> data) {
return ResponseHelper.buildResponse(jyjcBizManageService.regionStatusEdit(appSeq, data));
}
}
...@@ -24,6 +24,10 @@ public class JyjcInspectionHistoryServiceImpl extends BaseService<JyjcInspection ...@@ -24,6 +24,10 @@ public class JyjcInspectionHistoryServiceImpl extends BaseService<JyjcInspection
return this.getOne(new LambdaQueryWrapper<JyjcInspectionHistory>().eq(JyjcInspectionHistory::getSSeq, sSeq)); return this.getOne(new LambdaQueryWrapper<JyjcInspectionHistory>().eq(JyjcInspectionHistory::getSSeq, sSeq));
} }
public JyjcInspectionHistory getBySSeq(String sSeq) {
return this.getOne(new LambdaQueryWrapper<JyjcInspectionHistory>().eq(JyjcInspectionHistory::getSSeq, sSeq));
}
public void saveBySeq(Long sSeq, JSONObject hisData, String sType) { public void saveBySeq(Long sSeq, JSONObject hisData, String sType) {
JyjcInspectionHistory history = this.getBySSeq(sSeq); JyjcInspectionHistory history = this.getBySSeq(sSeq);
if (history != null) { if (history != null) {
......
...@@ -46,6 +46,7 @@ import com.yeejoin.amos.boot.module.jyjc.biz.event.InspectionDetectionSaveToDbEv ...@@ -46,6 +46,7 @@ import com.yeejoin.amos.boot.module.jyjc.biz.event.InspectionDetectionSaveToDbEv
import com.yeejoin.amos.boot.module.jyjc.biz.event.publisher.BizEmqPublisher; import com.yeejoin.amos.boot.module.jyjc.biz.event.publisher.BizEmqPublisher;
import com.yeejoin.amos.boot.module.jyjc.biz.event.publisher.EventPublisher; import com.yeejoin.amos.boot.module.jyjc.biz.event.publisher.EventPublisher;
import com.yeejoin.amos.boot.module.jyjc.biz.feign.TzsServiceFeignClient; import com.yeejoin.amos.boot.module.jyjc.biz.feign.TzsServiceFeignClient;
import com.yeejoin.amos.boot.module.jyjc.biz.util.CompareUtils;
import com.yeejoin.amos.boot.module.jyjc.biz.util.JsonUtils; import com.yeejoin.amos.boot.module.jyjc.biz.util.JsonUtils;
import com.yeejoin.amos.boot.module.ymt.api.entity.IdxBizJgInspectionDetectionInfo; import com.yeejoin.amos.boot.module.ymt.api.entity.IdxBizJgInspectionDetectionInfo;
import com.yeejoin.amos.boot.module.ymt.api.entity.IdxBizJgProjectContraption; import com.yeejoin.amos.boot.module.ymt.api.entity.IdxBizJgProjectContraption;
...@@ -60,7 +61,6 @@ import org.apache.commons.lang3.StringUtils; ...@@ -60,7 +61,6 @@ import org.apache.commons.lang3.StringUtils;
import org.eclipse.paho.client.mqttv3.MqttException; import org.eclipse.paho.client.mqttv3.MqttException;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value; import org.springframework.beans.factory.annotation.Value;
import org.springframework.context.annotation.Lazy;
import org.springframework.core.io.Resource; import org.springframework.core.io.Resource;
import org.springframework.scheduling.annotation.Async; import org.springframework.scheduling.annotation.Async;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
...@@ -440,7 +440,7 @@ public class JyjcInspectionResultServiceImpl extends BaseService<JyjcInspectionR ...@@ -440,7 +440,7 @@ public class JyjcInspectionResultServiceImpl extends BaseService<JyjcInspectionR
paramObj.forEach((k, v) -> { paramObj.forEach((k, v) -> {
DynamicColumnDto columnDto = new DynamicColumnDto(); DynamicColumnDto columnDto = new DynamicColumnDto();
columnDto.setColumnName(String.format("\"%s\"", StrUtil.toUnderlineCase(k).toUpperCase())); columnDto.setColumnName(String.format("\"%s\"", StrUtil.toUnderlineCase(k).toUpperCase()));
columnDto.setColumnValue(v == null ? null : String.valueOf(v)); columnDto.setColumnValue(v == null ? null : nullIfNullOrEmpty(String.valueOf(v)));
columns.add(columnDto); columns.add(columnDto);
}); });
String tableName = this.getTableName(param.getParamType()); String tableName = this.getTableName(param.getParamType());
...@@ -449,6 +449,16 @@ public class JyjcInspectionResultServiceImpl extends BaseService<JyjcInspectionR ...@@ -449,6 +449,16 @@ public class JyjcInspectionResultServiceImpl extends BaseService<JyjcInspectionR
} }
} }
/**
* 处理将空转null 防止技术参数,数字类型在查询详情时,映射错误
*
* @param str 字符串
* @return null or 非空的字符串
*/
private String nullIfNullOrEmpty(String str) {
return CompareUtils.isNullOrEmpty(str) ? null : str;
}
private String getTableName(String paramType) { private String getTableName(String paramType) {
return String.format("\"%s\"", StrUtil.toUnderlineCase(paramType)); return String.format("\"%s\"", StrUtil.toUnderlineCase(paramType));
} }
......
package com.yeejoin.amos.boot.module.jyjc.biz.util; package com.yeejoin.amos.boot.module.jyjc.biz.util;
public class CompareUtils { public final class CompareUtils {
public static boolean isNullOrEmpty(String str) { public static boolean isNullOrEmpty(String str) {
return str == null || str.trim().isEmpty() || "null".equals(str); return str == null || str.trim().isEmpty() || "null".equalsIgnoreCase(str);
} }
} }
...@@ -82,4 +82,4 @@ inspection.rule.enabled.DQRBI=true ...@@ -82,4 +82,4 @@ inspection.rule.enabled.DQRBI=true
# ??????(0<=datacenter-id<=31) # ??????(0<=datacenter-id<=31)
mybatis-plus.global-config.datacenter-id=1 mybatis-plus.global-config.datacenter-id=1
# ??????(0<=worker-id<=31) # ??????(0<=worker-id<=31)
mybatis-plus.global-config.worker-id=2 mybatis-plus.global-config.worker-id=3
\ No newline at end of file \ No newline at end of file
...@@ -50,7 +50,7 @@ ...@@ -50,7 +50,7 @@
<logger name="com.yeejoin" level="INFO"/> <logger name="com.yeejoin" level="INFO"/>
<!-- 日志输出级别 --> <!-- 日志输出级别 -->
<root level="INFO"> <root level="ERROR">
<!-- <appender-ref ref="FILE" /> --> <!-- <appender-ref ref="FILE" /> -->
<appender-ref ref="STDOUT" /> <appender-ref ref="STDOUT" />
<!-- <appender-ref ref="ELK" />--> <!-- <appender-ref ref="ELK" />-->
......
...@@ -955,8 +955,13 @@ public class ZLDPStatisticsServiceImpl { ...@@ -955,8 +955,13 @@ public class ZLDPStatisticsServiceImpl {
}else { }else {
BoolQueryBuilder meBuilder = QueryBuilders.boolQuery(); BoolQueryBuilder meBuilder = QueryBuilders.boolQuery();
String test = QueryParser.escape(map.getString("EQU_CATEGORY")); String test = QueryParser.escape(map.getString("EQU_CATEGORY"));
meBuilder.must(QueryBuilders.matchPhraseQuery("EQU_CATEGORY", "*" + test + "*")); if (CylinderTypeEnum.CYLINDER.getCode().equals(map.getString("EQU_LIST_CODE"))) {
boolMust.must(meBuilder); meBuilder.must(QueryBuilders.termQuery("EQU_DEFINE_CODE", test));
boolMust.must(meBuilder);
} else {
meBuilder.must(QueryBuilders.termQuery("EQU_CATEGORY_CODE", test));
boolMust.must(meBuilder);
}
} }
} }
if (!ObjectUtils.isEmpty(map.getString("USE_ORG_CODE"))) { if (!ObjectUtils.isEmpty(map.getString("USE_ORG_CODE"))) {
......
...@@ -17,28 +17,6 @@ ...@@ -17,28 +17,6 @@
<select id="queryListByQueryDto" resultType="java.util.Map"> <select id="queryListByQueryDto" resultType="java.util.Map">
SELECT SELECT
r.sequence_nbr AS sequenceNbr, r.sequence_nbr AS sequenceNbr,
-- r.filling_unit_name AS fillingUnitName,
-- r.factory_num AS factoryNum,
-- CASE
-- i.cylinder_variety
-- WHEN 1 THEN
-- '无缝气瓶'
-- WHEN 2 THEN
-- '焊接气瓶'
-- WHEN 3 THEN
-- '缠绕气瓶'
-- WHEN 4 THEN
-- '绝热气瓶'
-- WHEN 5 THEN
-- '内装填料气瓶'
-- ELSE
-- ''
-- END AS cylinderVariety,
-- i.qrCode AS qrCode,
-- i.electronic_label_code AS electronicLabelCode,
-- r.sequence_code AS sequenceCode,
-- i.unit_inner_code AS unitInnerCode,
-- u.unit_name AS propertyUnit,
r.filling_startTime AS fillingStarttime, r.filling_startTime AS fillingStarttime,
r.filling_endTime AS fillingEndtime, r.filling_endTime AS fillingEndtime,
r.filling_user AS fillingUser, r.filling_user AS fillingUser,
...@@ -92,18 +70,6 @@ ...@@ -92,18 +70,6 @@
<if test="appId != null and appId != ''"> <if test="appId != null and appId != ''">
AND r.app_id = #{appId} AND r.app_id = #{appId}
</if> </if>
<!-- <if test="fillingUnitName != null and fillingUnitName != ''">-->
<!-- AND r.filling_unit_name like-->
<!-- CONCAT(CONCAT('%',#{fillingUnitName}),'%')-->
<!-- </if>-->
<!-- <if test="propertyUnit != null and propertyUnit != ''">-->
<!-- AND u.unit_name like-->
<!-- CONCAT(CONCAT('%',#{propertyUnit}),'%')-->
<!-- </if>-->
<!-- <if test="factoryNum != null and factoryNum != ''">-->
<!-- AND r.factory_num like-->
<!-- CONCAT(CONCAT('%',#{factoryNum}),'%')-->
<!-- </if>-->
<if test="fillingStartTime != null "> <if test="fillingStartTime != null ">
and #{fillingStartTime} <![CDATA[ <= ]]> and #{fillingStartTime} <![CDATA[ <= ]]>
r.filling_startTime r.filling_startTime
...@@ -112,24 +78,6 @@ ...@@ -112,24 +78,6 @@
and r.filling_endTime <![CDATA[ <= ]]> and r.filling_endTime <![CDATA[ <= ]]>
#{fillingEndTime} #{fillingEndTime}
</if> </if>
<!-- <if test="cylinderVariety != null and cylinderVariety != ''">-->
<!-- AND i.cylinder_variety = #{cylinderVariety}-->
<!-- </if>-->
<!-- <if test="qrCode != null and qrCode != ''">-->
<!-- AND i.qrCode like CONCAT(CONCAT('%',#{qrCode}),'%')-->
<!-- </if>-->
<!-- <if test="electronicLabelCode != null and electronicLabelCode != ''">-->
<!-- AND i.electronic_label_code like-->
<!-- CONCAT(CONCAT('%',#{electronicLabelCode}),'%')-->
<!-- </if>-->
<!-- <if test="sequenceCode != null and sequenceCode != ''">-->
<!-- AND r.sequence_code like-->
<!-- CONCAT(CONCAT('%',#{sequenceCode}),'%')-->
<!-- </if>-->
<!-- <if test="unitInnerCode != null and unitInnerCode != ''">-->
<!-- AND i.unit_inner_code like-->
<!-- CONCAT(CONCAT('%',#{unitInnerCode}),'%')-->
<!-- </if>-->
<if test="sortParam != null and sortParam != '' and sortRule != null and sortRule != '' "> <if test="sortParam != null and sortParam != '' and sortRule != null and sortRule != '' ">
ORDER BY ${sortParam} ${sortRule} ORDER BY ${sortParam} ${sortRule}
</if> </if>
......
...@@ -24,9 +24,6 @@ ...@@ -24,9 +24,6 @@
#{item} #{item}
</foreach> </foreach>
</if> </if>
<!-- <if test="bizType=='yingjian'">-->
<!-- AND b.SEQUENCE_NBR is null-->
<!-- </if>-->
<if test="bizType=='yijian'"> <if test="bizType=='yijian'">
AND b.SEQUENCE_NBR is not null AND b.SEQUENCE_NBR is not null
</if> </if>
...@@ -55,9 +52,6 @@ ...@@ -55,9 +52,6 @@
#{item} #{item}
</foreach> </foreach>
</if> </if>
<!-- <if test="bizType=='yingjian'">-->
<!-- AND b.SEQUENCE_NBR is null-->
<!-- </if>-->
<if test="bizType=='yijian'"> <if test="bizType=='yijian'">
AND b.SEQUENCE_NBR is not null AND b.SEQUENCE_NBR is not null
</if> </if>
......
...@@ -64,8 +64,6 @@ ...@@ -64,8 +64,6 @@
select * FROM select * FROM
( (
SELECT * FROM ( SELECT * FROM (
-- 风险单位 只显示下发整改和整改上报后的
<include refid="baseSelectForRiskReport"/> <include refid="baseSelectForRiskReport"/>
FROM tzs_risk_report AS rr1 FROM tzs_risk_report AS rr1
WHERE rr1."risk_company_code" = #{dto.riskCompanyCode} AND rr1."current_status" != '草稿' AND WHERE rr1."risk_company_code" = #{dto.riskCompanyCode} AND rr1."current_status" != '草稿' AND
...@@ -77,13 +75,10 @@ ...@@ -77,13 +75,10 @@
) )
UNION UNION
-- 报送单位
<include refid="baseSelectForRiskReport"/> <include refid="baseSelectForRiskReport"/>
FROM tzs_risk_report AS rr2 FROM tzs_risk_report AS rr2
WHERE rr2."report_company_code" = #{dto.reportCompanyCode} AND rr2."current_status" != '草稿' WHERE rr2."report_company_code" = #{dto.reportCompanyCode} AND rr2."current_status" != '草稿'
<!-- 处置单位 -->
<if test='dto.unitType != null and dto.unitType != "" and dto.unitType == "supervision"'> <if test='dto.unitType != null and dto.unitType != "" and dto.unitType == "supervision"'>
UNION UNION
<include refid="baseSelectForRiskReport"/> <include refid="baseSelectForRiskReport"/>
...@@ -91,8 +86,6 @@ ...@@ -91,8 +86,6 @@
WHERE rr3."current_status" != '草稿' AND rr3."all_risk_disposal_unit_org_code" like CONCAT('%', WHERE rr3."current_status" != '草稿' AND rr3."all_risk_disposal_unit_org_code" like CONCAT('%',
#{dto.riskDisposalUnitOrgCode}, '%') #{dto.riskDisposalUnitOrgCode}, '%')
</if> </if>
<!-- 自己的草稿状态 -->
<if test='dto.createUserId != null and dto.createUserId != ""'> <if test='dto.createUserId != null and dto.createUserId != ""'>
UNION UNION
<include refid="baseSelectForRiskReport"/> <include refid="baseSelectForRiskReport"/>
......
...@@ -44,9 +44,6 @@ ...@@ -44,9 +44,6 @@
ci.longitude, ci.longitude,
ci.latitude, ci.latitude,
eu.address, eu.address,
-- eu.custom_name,
-- eu.custom_type,
-- eu.contact_phone,
cu.person_mobile_phone, cu.person_mobile_phone,
cu.unit_person cu.unit_person
from from
......
...@@ -235,7 +235,7 @@ ...@@ -235,7 +235,7 @@
update tz_base_enterprise_info update tz_base_enterprise_info
set SUPERVISE_ORG_NAME = #{superviseOrgName}, set SUPERVISE_ORG_NAME = #{superviseOrgName},
SUPERVISE_ORG_CODE = REPLACE(SUPERVISE_ORG_CODE, #{oldSuperviseOrgCode}, #{preSuperviseOrgCode}), SUPERVISE_ORG_CODE = REPLACE(SUPERVISE_ORG_CODE, #{oldSuperviseOrgCode}, #{preSuperviseOrgCode}),
ORG_CODE = IFNULL(REPLACE(ORG_CODE, #{oldOrgCode}, #{preOrgCode}), #{preOrgCode}), -- 兼容旧数据,如果为空则使用新值 ORG_CODE = IFNULL(REPLACE(ORG_CODE, #{oldOrgCode}, #{preOrgCode}), #{preOrgCode}),
governing_body = #{superviseOrgName} governing_body = #{superviseOrgName}
where sequence_nbr = #{sequenceNbr} where sequence_nbr = #{sequenceNbr}
</update> </update>
...@@ -403,7 +403,6 @@ ...@@ -403,7 +403,6 @@
</update> </update>
<update id="updateRedundantSupervisionOrgCodeStatistics"> <update id="updateRedundantSupervisionOrgCodeStatistics">
--三项制度因为会定时生成统计数据(刚好在层级调整后生成了统计数据,此时再单位层级树再调整会原有,根据该表的唯一约束会提示更新冲突),所以需要特殊处理(如果目标数据存在则不更新,并删除旧的统计数据)
WITH potential_updates AS ( WITH potential_updates AS (
SELECT SELECT
ctid, ctid,
......
...@@ -55,13 +55,6 @@ ...@@ -55,13 +55,6 @@
<if test="dto.subPost != '' and dto.subPost != null"> <if test="dto.subPost != '' and dto.subPost != null">
and sub_post like concat('%',#{dto.subPost},'%') and sub_post like concat('%',#{dto.subPost},'%')
</if> </if>
<!-- <if test="dto.menuTypeUnderPost != null and dto.menuTypeUnderPost.size() > 0">-->
<!-- AND (-->
<!-- <foreach collection="dto.menuTypeUnderPost" separator="or" item="postType">-->
<!-- new_post like concat('%',#{postType},'%')-->
<!-- </foreach>-->
<!-- )-->
<!-- </if>-->
<if test="dto.postName != '' and dto.postName != null"> <if test="dto.postName != '' and dto.postName != null">
and post like concat('%',#{dto.postName},'%') and post like concat('%',#{dto.postName},'%')
</if> </if>
......
...@@ -89,4 +89,9 @@ minio.url.path=http://172.16.10.243:9000/ ...@@ -89,4 +89,9 @@ minio.url.path=http://172.16.10.243:9000/
regulatory_code_prefix=https://nav.sspai.top/tzs?code= regulatory_code_prefix=https://nav.sspai.top/tzs?code=
outSystem.user.password=a1234560 outSystem.user.password=a1234560
amos.system.user.app-key=AMOS_STUDIO amos.system.user.app-key=AMOS_STUDIO
amos.system.user.product=STUDIO_APP_WEB amos.system.user.product=STUDIO_APP_WEB
\ No newline at end of file
# ??????(0<=datacenter-id<=31)
mybatis-plus.global-config.datacenter-id=1
# ??????(0<=worker-id<=31)
mybatis-plus.global-config.worker-id=4
\ No newline at end of file
...@@ -222,7 +222,7 @@ ...@@ -222,7 +222,7 @@
p_input_item ii p_input_item ii
WHERE WHERE
ci.check_id = sss.CheckID ci.check_id = sss.CheckID
AND ci.is_ok = '2' -- 不合格 AND ci.is_ok = '2'
AND ci.input_id = ii.id AND ci.input_id = ii.id
) )
END AS ErrorMsg END AS ErrorMsg
......
...@@ -34,7 +34,6 @@ ...@@ -34,7 +34,6 @@
b.route_id AS route_id, b.route_id AS route_id,
a.point_classify_id AS pointClassifyId, a.point_classify_id AS pointClassifyId,
e.risk_source_id as riskSourceId e.risk_source_id as riskSourceId
-- e.evaluate_id AS evaluateId
FROM FROM
p_check_input AS a p_check_input AS a
LEFT JOIN p_check AS b ON a.check_id = b.id LEFT JOIN p_check AS b ON a.check_id = b.id
......
...@@ -455,7 +455,7 @@ ...@@ -455,7 +455,7 @@
p_point c, p_point c,
spc_risk_source d spc_risk_source d
WHERE WHERE
a.danger_level = #{type} -- (1,2) a.danger_level = #{type}
<if test="departmentId != null and departmentId != -1"> <if test="departmentId != null and departmentId != -1">
and d.belong_department_id = #{departmentId} and d.belong_department_id = #{departmentId}
</if> </if>
......
...@@ -17,28 +17,6 @@ ...@@ -17,28 +17,6 @@
<select id="queryListByQueryDto" resultType="java.util.Map"> <select id="queryListByQueryDto" resultType="java.util.Map">
SELECT SELECT
r.sequence_nbr AS sequenceNbr, r.sequence_nbr AS sequenceNbr,
-- r.filling_unit_name AS fillingUnitName,
-- r.factory_num AS factoryNum,
-- CASE
-- i.cylinder_variety
-- WHEN 1 THEN
-- '无缝气瓶'
-- WHEN 2 THEN
-- '焊接气瓶'
-- WHEN 3 THEN
-- '缠绕气瓶'
-- WHEN 4 THEN
-- '绝热气瓶'
-- WHEN 5 THEN
-- '内装填料气瓶'
-- ELSE
-- ''
-- END AS cylinderVariety,
-- i.qrCode AS qrCode,
-- i.electronic_label_code AS electronicLabelCode,
-- r.sequence_code AS sequenceCode,
-- i.unit_inner_code AS unitInnerCode,
-- u.unit_name AS propertyUnit,
r.filling_startTime AS fillingStarttime, r.filling_startTime AS fillingStarttime,
r.filling_endTime AS fillingEndtime, r.filling_endTime AS fillingEndtime,
r.filling_user AS fillingUser, r.filling_user AS fillingUser,
...@@ -92,18 +70,6 @@ ...@@ -92,18 +70,6 @@
<if test="appId != null and appId != ''"> <if test="appId != null and appId != ''">
AND r.app_id = #{appId} AND r.app_id = #{appId}
</if> </if>
<!-- <if test="fillingUnitName != null and fillingUnitName != ''">-->
<!-- AND r.filling_unit_name like-->
<!-- CONCAT(CONCAT('%',#{fillingUnitName}),'%')-->
<!-- </if>-->
<!-- <if test="propertyUnit != null and propertyUnit != ''">-->
<!-- AND u.unit_name like-->
<!-- CONCAT(CONCAT('%',#{propertyUnit}),'%')-->
<!-- </if>-->
<!-- <if test="factoryNum != null and factoryNum != ''">-->
<!-- AND r.factory_num like-->
<!-- CONCAT(CONCAT('%',#{factoryNum}),'%')-->
<!-- </if>-->
<if test="fillingStartTime != null "> <if test="fillingStartTime != null ">
and #{fillingStartTime} <![CDATA[ <= ]]> and #{fillingStartTime} <![CDATA[ <= ]]>
r.filling_startTime r.filling_startTime
...@@ -112,24 +78,6 @@ ...@@ -112,24 +78,6 @@
and r.filling_endTime <![CDATA[ <= ]]> and r.filling_endTime <![CDATA[ <= ]]>
#{fillingEndTime} #{fillingEndTime}
</if> </if>
<!-- <if test="cylinderVariety != null and cylinderVariety != ''">-->
<!-- AND i.cylinder_variety = #{cylinderVariety}-->
<!-- </if>-->
<!-- <if test="qrCode != null and qrCode != ''">-->
<!-- AND i.qrCode like CONCAT(CONCAT('%',#{qrCode}),'%')-->
<!-- </if>-->
<!-- <if test="electronicLabelCode != null and electronicLabelCode != ''">-->
<!-- AND i.electronic_label_code like-->
<!-- CONCAT(CONCAT('%',#{electronicLabelCode}),'%')-->
<!-- </if>-->
<!-- <if test="sequenceCode != null and sequenceCode != ''">-->
<!-- AND r.sequence_code like-->
<!-- CONCAT(CONCAT('%',#{sequenceCode}),'%')-->
<!-- </if>-->
<!-- <if test="unitInnerCode != null and unitInnerCode != ''">-->
<!-- AND i.unit_inner_code like-->
<!-- CONCAT(CONCAT('%',#{unitInnerCode}),'%')-->
<!-- </if>-->
<if test="sortParam != null and sortParam != '' and sortRule != null and sortRule != '' "> <if test="sortParam != null and sortParam != '' and sortRule != null and sortRule != '' ">
ORDER BY ${sortParam} ${sortRule} ORDER BY ${sortParam} ${sortRule}
</if> </if>
......
...@@ -451,8 +451,6 @@ ...@@ -451,8 +451,6 @@
ESTATE_UNIT_NAME, ESTATE_UNIT_NAME,
FACTORY_USE_SITE_STREET, FACTORY_USE_SITE_STREET,
LONGITUDE_LATITUDE, LONGITUDE_LATITUDE,
-- ifnull(LONGITUDE_LATITUDE :: json->> 'latitude', null) AS latitude,
-- ifnull(LONGITUDE_LATITUDE :: json->> 'longitude', null) AS longitude,
PHONE, PHONE,
PROVINCE, PROVINCE,
PROVINCE_NAME, PROVINCE_NAME,
......
...@@ -24,9 +24,6 @@ ...@@ -24,9 +24,6 @@
#{item} #{item}
</foreach> </foreach>
</if> </if>
<!-- <if test="bizType=='yingjian'">-->
<!-- AND b.SEQUENCE_NBR is null-->
<!-- </if>-->
<if test="bizType=='yijian'"> <if test="bizType=='yijian'">
AND b.SEQUENCE_NBR is not null AND b.SEQUENCE_NBR is not null
</if> </if>
...@@ -55,9 +52,6 @@ ...@@ -55,9 +52,6 @@
#{item} #{item}
</foreach> </foreach>
</if> </if>
<!-- <if test="bizType=='yingjian'">-->
<!-- AND b.SEQUENCE_NBR is null-->
<!-- </if>-->
<if test="bizType=='yijian'"> <if test="bizType=='yijian'">
AND b.SEQUENCE_NBR is not null AND b.SEQUENCE_NBR is not null
</if> </if>
......
...@@ -44,9 +44,6 @@ ...@@ -44,9 +44,6 @@
ci.longitude, ci.longitude,
ci.latitude, ci.latitude,
eu.address, eu.address,
-- eu.custom_name,
-- eu.custom_type,
-- eu.contact_phone,
cu.person_mobile_phone, cu.person_mobile_phone,
cu.unit_person cu.unit_person
from from
......
...@@ -113,11 +113,6 @@ ...@@ -113,11 +113,6 @@
ON t1.unit_code = use_code ON t1.unit_code = use_code
</if> </if>
<where> <where>
<!-- <if-->
<!-- test="tzBaseEnterpriseInfoDto.unitType!=null and tzBaseEnterpriseInfoDto.unitType!='' and tzBaseEnterpriseInfoDto.unitType!='使用单位' ">-->
<!-- -->
<!-- AND unit_type LIKE CONCAT('%',#{tzBaseEnterpriseInfoDto.unitType},'%')-->
<!-- </if>-->
<if test="unitTypeList != null and !unitTypeList.isEmpty()"> <if test="unitTypeList != null and !unitTypeList.isEmpty()">
AND ( AND (
<foreach collection="unitTypeList" item="item" separator=" OR "> <foreach collection="unitTypeList" item="item" separator=" OR ">
...@@ -312,6 +307,7 @@ ...@@ -312,6 +307,7 @@
</if> </if>
<if test="city != null and city != ''"> <if test="city != null and city != ''">
and tjoa.detection_region like concat('%',#{city},'%') and tjoa.detection_region like concat('%',#{city},'%')
and (tjoa.exclusion_region IS NULL or not (tjoa.exclusion_region like concat('%',#{city},'%')))
</if> </if>
group by info.sequence_nbr group by info.sequence_nbr
</select> </select>
......
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