Commit c27198ce authored by 刘林's avatar 刘林

fix(jg):A200,B012,B016需求修改

parent da78372f
#DB properties:
spring.datasource.url=jdbc:vastbase://36.46.137.116:5432/tzs_amos_tzs_biz_init?currentSchema=amos_tzs_biz&allowMultiQueries=true
spring.datasource.url=jdbc:vastbase://172.16.10.243:5432/tzs_amos_tzs_biz_init?currentSchema=amos_tzs_biz&allowMultiQueries=true
spring.datasource.username=admin
spring.datasource.password=Yeejoin@2023
eureka.client.service-url.defaultZone=http://172.16.10.210:10001/eureka/
eureka.client.service-url.defaultZone=http://172.16.10.243:10001/eureka/
eureka.instance.prefer-ip-address=true
management.endpoint.health.show-details=always
management.endpoints.web.exposure.include=*
eureka.instance.health-check-url=http://172.16.3.17:${server.port}${server.servlet.context-path}/actuator/health
eureka.instance.health-check-url=http://172.16.3.70:${server.port}${server.servlet.context-path}/actuator/health
eureka.instance.metadata-map.management.context-path=${server.servlet.context-path}/actuator
eureka.instance.status-page-url=http://172.16.3.17:${server.port}${server.servlet.context-path}/actuator/info
eureka.instance.metadata-map.management.api-docs=http://172.16.3.17:${server.port}${server.servlet.context-path}/doc.html
eureka.instance.ip-address=172.16.3.17
eureka.instance.status-page-url=http://172.16.3.70:${server.port}${server.servlet.context-path}/actuator/info
eureka.instance.metadata-map.management.api-docs=http://172.16.3.70:${server.port}${server.servlet.context-path}/doc.html
eureka.instance.ip-address=172.16.3.70
## ES properties:
elasticsearch.username=elastic
elasticsearch.password=a123456
spring.elasticsearch.rest.uris=http://172.16.10.210:9200
spring.elasticsearch.rest.uris=http://172.16.10.243:9200
## unit(h)
alertcall.es.synchrony.time=48
#redis properties:
spring.redis.mode=singleton
spring.redis.database=1
spring.redis.host=172.16.10.210
spring.redis.port=16379
spring.redis.host=172.16.10.243
spring.redis.port=6379
spring.redis.password=yeejoin@2020
spring.redis.lettuce.pool.max-active=200
spring.redis.lettuce.pool.max-wait=-1
......@@ -70,20 +70,20 @@ tzs.wechat.tempId.supervise=P5XGbszS2Pc6kynvGjzPpZ--ikAwDZo6O7WdJ2EUxtE
tzs.wechat.test.userId=3413513
##new properties
org.filter.group.seq=1564150103147573249
fileserver.domain=http://172.16.10.210:19000/
fileserver.domain=http://172.16.10.243:19000/
log.level=INFO
duty.seats.role.ids=1585956200472674305,1585956257590706177
## ???? properties:
rule.definition.load=false
##rule.definition.model-package=com.yeejoin.amos.boot.module.jcs.api.dto
rule.definition.default-agency=tzs
rule.definition.local-ip=172.16.10.210
rule.definition.local-ip=172.16.10.243
#\u6C14\u74F6\u5145\u88C5\u4FE1\u606F\u5B9A\u65F6\u540C\u6B65\u81F3es
tzs.cylinder.fill.cron=0 0 12 * * ?
#\u6C14\u74F6\u57FA\u672C\u4FE1\u606F\u5B9A\u65F6\u540C\u6B65\u81F3es
tzs.cylinder.info.cron=0 0 1 * * ?
# ??????????
minio.url.path=http://172.16.10.210:9000/
minio.url.path=http://172.16.10.243:9000/
## ɼǰ׺
regulatory_code_prefix=https://nav.sspai.top/tzs?code=
outSystem.user.password=a1234560
......
......@@ -18,11 +18,23 @@ public class ChargingMediumConverter implements Converter<String> {
EXCEL_TO_JAVA_MAP.put("液化石油气", "LIQUEFIED_PETROLEUM_GAS");
EXCEL_TO_JAVA_MAP.put("压缩天然气", "COMPRESSED_NATURAL_GAS");
EXCEL_TO_JAVA_MAP.put("氢气", "HYDROGEN");
EXCEL_TO_JAVA_MAP.put("空气", "AIR");
EXCEL_TO_JAVA_MAP.put("氧气", "OXYGEN");
EXCEL_TO_JAVA_MAP.put("丙烷", "PROPANE");
EXCEL_TO_JAVA_MAP.put("丁烷", "BUTANCE");
EXCEL_TO_JAVA_MAP.put("液化二氧化碳", "LIQUEFIED_CARBON_DIOXIDE");
EXCEL_TO_JAVA_MAP.put("液氧", "LIQUID_OXYGEN");
JAVA_TO_EXCEL_MAP.put("LIQUEFIED_NATURAL_GAS", "液化天然气");
JAVA_TO_EXCEL_MAP.put("LIQUEFIED_PETROLEUM_GAS", "液化石油气");
JAVA_TO_EXCEL_MAP.put("COMPRESSED_NATURAL_GAS", "压缩天然气");
JAVA_TO_EXCEL_MAP.put("HYDROGEN", "氢气");
JAVA_TO_EXCEL_MAP.put("AIR", "空气");
JAVA_TO_EXCEL_MAP.put("OXYGEN", "氧气");
JAVA_TO_EXCEL_MAP.put("PROPANE", "丙烷");
JAVA_TO_EXCEL_MAP.put("BUTANCE", "丁烷");
JAVA_TO_EXCEL_MAP.put("LIQUEFIED_CARBON_DIOXIDE", "液化二氧化碳");
JAVA_TO_EXCEL_MAP.put("LIQUID_OXYGEN", "液氧");
}
@Override
......
......@@ -144,122 +144,127 @@ public class EquipInfoCylinderExcelDto extends BaseDto {
@NotBlank(message = "检测机构名称不能为空")
private String inspectOrgName;
@ApiModelProperty(value = "检测机构代码")
@ExcelProperty(value = "检测机构代码", index = 24)
@NotBlank(message = "检测机构代码不能为空")
private String inspectOrgCode;
@ApiModelProperty(value = "检测人员名称")
@ExcelProperty(value = "检测人员名称", index = 24)
@ExcelProperty(value = "检测人员名称", index = 25)
@NotBlank(message = "检测人员名称不能为空")
private String inspectStaff;
@ApiModelProperty(value = "检测日期")
@ExcelProperty(value = "检测日期", index = 25)
@ExcelProperty(value = "检测日期", index = 26)
@NotBlank(message = "检测日期不能为空")
@DateTimeFormat("yyyy-MM-dd")
private String inspectDate;
//技术参数
@ExcelProperty(value = "额定质量(kg)", index = 26)
@ExcelProperty(value = "额定质量(kg)", index = 27)
@ApiModelProperty(value = "额定质量(kg)")
private String ratedQuality;
@ExcelProperty(value = "使用环境温度(℃)", index = 27)
@ExcelProperty(value = "使用环境温度(℃)", index = 28)
@ApiModelProperty(value = "使用环境温度(℃)")
private String ambientTemperature;
@ExcelProperty(value = "单瓶容积(m3)", index = 28)
@ExcelProperty(value = "单瓶容积(m3)", index = 29)
@ApiModelProperty(value = "单瓶容积(m3)")
@NotBlank(message = "单瓶容积(m3)不能为空")
private String singleBottleVolume;
@ExcelProperty(value = "型号", index = 29)
@ExcelProperty(value = "型号", index = 30)
@ApiModelProperty(value = "型号")
private String modelNumber;
@ExcelProperty(value = "充装介质", index = 30, converter = ChargingMediumConverter.class)
@ExcelProperty(value = "充装介质", index = 31, converter = ChargingMediumConverter.class)
@ApiModelProperty(value = "充装介质")
@NotBlank(message = "充装介质不能为空")
private String chargingMedium;
@ExcelProperty(value = "规格", index = 31)
@ExcelProperty(value = "规格", index = 32)
@ApiModelProperty(value = "规格")
private String specification;
@ExcelProperty(value = "外径", index = 32)
@ExcelProperty(value = "外径", index = 33)
@ApiModelProperty(value = "外径")
private String outsideDiameter;
@ExcelProperty(value = "壁厚", index = 33)
@ExcelProperty(value = "壁厚", index = 34)
@ApiModelProperty(value = "壁厚")
private String wallThickness;
@ExcelProperty(value = "长度", index = 34)
@ExcelProperty(value = "长度", index = 35)
@ApiModelProperty(value = "长度")
private String length;
@ExcelProperty(value = "公称工作压力(MPa)", index = 35)
@ExcelProperty(value = "公称工作压力(MPa)", index = 36)
@ApiModelProperty(value = "公称工作压力(MPa)")
@NotBlank(message = "公称工作压力(MPa)不能为空")
private String nominalWorkingPressure;
@ExcelProperty(value = "材料(管路)", index = 36)
@ExcelProperty(value = "材料(管路)", index = 37)
@ApiModelProperty(value = "材料(管路)")
private String piping;
@ExcelProperty(value = "无损检测方法(气瓶)", index = 37, converter = NondestructConverter.class)
@ExcelProperty(value = "无损检测方法(气瓶)", index = 38, converter = NondestructConverter.class)
@ApiModelProperty(value = "无损检测方法(气瓶)")
private String qpLossless;//5988
@ExcelProperty(value = "材料(瓶体)", index = 38)
@ExcelProperty(value = "材料(瓶体)", index = 39)
@ApiModelProperty(value = "材料(瓶体)")
private String bottleBody;
@ExcelProperty(value = "材料(端塞)", index = 39)
@ExcelProperty(value = "材料(端塞)", index = 40)
@ApiModelProperty(value = "材料(端塞)")
private String endPlug;
@ExcelProperty(value = "无损检测比例(管路)(%)", index = 40)
@ExcelProperty(value = "无损检测比例(管路)(%)", index = 41)
@ApiModelProperty(value = "无损检测比例(管路)(%)")
private String glRatio;
@ExcelProperty(value = "无损检测比例(气瓶)(%)", index = 41)
@ExcelProperty(value = "无损检测比例(气瓶)(%)", index = 42)
@ApiModelProperty(value = "无损检测比例(气瓶)(%)")
private String qpRatio;
@ExcelProperty(value = "无损检测方法(管路)", index = 42, converter = NondestructConverter.class)
@ExcelProperty(value = "无损检测方法(管路)", index = 43, converter = NondestructConverter.class)
@ApiModelProperty(value = "无损检测方法(管路)")
private String glLossless;
@ExcelProperty(value = "耐压实验压力(气瓶)(Mpa)", index = 43)
@ExcelProperty(value = "耐压实验压力(气瓶)(Mpa)", index = 44)
@ApiModelProperty(value = "耐压实验压力(气瓶)(Mpa)")
private String qpPressure;
@ExcelProperty(value = "耐压实验压力(管路)(Mpa)", index = 44)
@ExcelProperty(value = "耐压实验压力(管路)(Mpa)", index = 45)
@ApiModelProperty(value = "耐压实验压力(管路)(Mpa)")
private String glPressure;
@ExcelProperty(value = "气密性试验压力(气瓶)(Mpa)", index = 45)
@ExcelProperty(value = "气密性试验压力(气瓶)(Mpa)", index = 46)
@ApiModelProperty(value = "气密性试验压力(气瓶)(Mpa)")
private String qpAirTightness;
@ExcelProperty(value = "气体置换后压力(MPa)", index = 46)
@ExcelProperty(value = "气体置换后压力(MPa)", index = 47)
@ApiModelProperty(value = "气体置换后压力(MPa)")
private String displacementPressure;
@ExcelProperty(value = "热处理方式", index = 47)
@ExcelProperty(value = "热处理方式", index = 48)
@ApiModelProperty(value = "热处理方式")
private String heatTreatmentMethod;
@ExcelProperty(value = "气密性实验压力(管路)(MPa)", index = 48)
@ExcelProperty(value = "气密性实验压力(管路)(MPa)", index = 49)
@ApiModelProperty(value = "气密性实验压力(管路)(MPa)")
private String glAirTightness;
@ExcelProperty(value = "气瓶安装位置", index = 49)
@ExcelProperty(value = "气瓶安装位置", index = 50)
@ApiModelProperty(value = "气瓶安装位置")
private String installationPosition;
@ExcelProperty(value = "瓶体内含氧量(%)", index = 50)
@ExcelProperty(value = "瓶体内含氧量(%)", index = 51)
@ApiModelProperty(value = "瓶体内含氧量(%)")
private String oxygen;
@ExcelProperty(value = "热处理温度(℃)", index = 51)
@ExcelProperty(value = "热处理温度(℃)", index = 52)
@ApiModelProperty(value = "热处理温度(℃)")
private String qpHeatTreatmentTemperature;
}
......@@ -2,8 +2,12 @@
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.yeejoin.amos.boot.module.jg.api.mapper.CommonMapper">
<select id="getUnitListByType" resultType="java.util.Map">
SELECT use_unit_code useCode,
use_unit useUnit
SELECT use_unit_code AS useCode,
CASE
WHEN unit_type = '个人主体'
THEN CONCAT(use_unit, '_', SUBSTRING(use_unit_code, LENGTH(use_unit_code) - 3, 4))
ELSE use_unit
END AS useUnit
FROM tz_base_enterprise_info
WHERE is_delete = '0'
<if test="type != null and type != 'all'">
......
......@@ -132,6 +132,8 @@ public class PressureVesselListener extends AnalysisEventListener<EquipInfoCylin
checkNotBlank(data.getProduceDate(), "制造日期不能为空");
checkDateFormatCorrect(data.getProduceDate(), "制造日期格式不正确");
checkNotBlank(data.getInspectOrgName(), "检测机构名称不能为空");
checkNotBlank(data.getInspectOrgCode(), "检测机构代码不能为空");
checkInspectOrg(data.getInspectOrgCode());
checkNotBlank(data.getInspectStaff(), "检测人员名称不能为空");
checkNotBlank(data.getInspectDate(), "检测日期不能为空");
checkDateFormatCorrect(data.getInspectDate(), "检测日期格式不正确");
......@@ -168,6 +170,13 @@ public class PressureVesselListener extends AnalysisEventListener<EquipInfoCylin
}
}
private void checkInspectOrg(String inspectOrgCode){
List<Map<String, Object>> InspectOrgList = commonService.getUnitListByType("inspection", "");
if (findUseCode(InspectOrgList, inspectOrgCode) == null) {
result.append("未查询到该检验机构");
}
}
// 检查字段是否为空,如果为空则追加错误信息到result
private void checkNotBlank(String value, String errorMessage) {
if (StringUtils.isBlank(value)) {
......@@ -250,7 +259,7 @@ public class PressureVesselListener extends AnalysisEventListener<EquipInfoCylin
IdxBizJgInspectionDetectionInfo inspectionDetectionInfo = new IdxBizJgInspectionDetectionInfo();
BeanUtils.copyProperties(data, inspectionDetectionInfo);
List<Map<String, Object>> InspectOrgList = commonService.getUnitListByType("inspection", "");
inspectionDetectionInfo.setInspectOrgCode(findUseCode(InspectOrgList, data.getInspectOrgName()));
inspectionDetectionInfo.setInspectOrgCode( data.getInspectOrgCode());
inspectionDetectionInfo.setRecord(record);
inspectionDetectionInfo.setRecDate(date);
inspectionDetectionInfo.setInspectType("ZZJDJY");
......@@ -348,9 +357,9 @@ public class PressureVesselListener extends AnalysisEventListener<EquipInfoCylin
return result.toString();
}
public String findUseCode(List<Map<String, Object>> unitList, String inspectOrgName) {
public String findUseCode(List<Map<String, Object>> unitList, String inspectOrgCode) {
Optional<Map<String, Object>> optional = unitList.stream()
.filter(map -> map.containsKey("useUnit") && map.get("useUnit").equals(inspectOrgName))
.filter(map -> map.get("useCode").equals(inspectOrgCode))
.findFirst();
return optional.map(map -> (String) map.get("useCode")).orElse(null);
}
......
......@@ -79,7 +79,7 @@ public class PlatformUserTopicMessage extends EmqxListener {
private void processDataResult(JSONObject dataResultObject) {
try {
String companyType = "行政审批局";
String companyType = "监管机构";
String companyTypeValue = dataResultObject.getString("companyType");
if (StringUtils.isNotEmpty(companyTypeValue) && companyTypeValue.contains(companyType)) {
commonService.creatApproveTree();
......
......@@ -1712,7 +1712,7 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
List<Map<String, Object>> inspectionAndTestingInstitutions = commonMapper.getUnitListByType(INSPECTION_AND_TESTING_INSTITUTIONS);
Optional<Map<String, Object>> optional = inspectionAndTestingInstitutions.stream().filter(x -> x.get("useCode").equals(inspectionDetectionInfo.getInspectOrgCode())).findFirst();
Map<String, Object> mapOrDefault = optional.orElse(Collections.emptyMap());
inspectionDetectionInfo.setInspectOrgName((String) mapOrDefault.getOrDefault("useUnit", inspectionDetectionInfo.getInspectOrgCode()));
inspectionDetectionInfo.setInspectOrgName((String) mapOrDefault.getOrDefault("useUnit", inspectionDetectionInfo.getInspectOrgName()));
inspectionDetectionInfo.setRecord(record);
inspectionDetectionInfo.setRecDate(date);
inspectionDetectionInfo.setSequenceNbr(OPERATESAVE.equals(operateType) ? null : String.valueOf(equipmentInfoForm.get("INSPECTIONDETECTIONINFO_SEQ")));
......
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