Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
amos-boot-biz
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
项目统一框架
amos-boot-biz
Commits
907d7e55
Commit
907d7e55
authored
Jan 15, 2025
by
韩桐桐
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat(jg):管道导入
parent
d64d540f
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
374 additions
and
55 deletions
+374
-55
DictParamsConverter.java
...mos/boot/module/jg/api/converter/DictParamsConverter.java
+0
-4
InspectConclusionConverter.java
...os/boot/module/jg/api/dto/InspectConclusionConverter.java
+59
-0
InspectTypeConverter.java
...oin/amos/boot/module/jg/api/dto/InspectTypeConverter.java
+52
-0
PipingExcelDto.java
...m/yeejoin/amos/boot/module/jg/api/dto/PipingExcelDto.java
+201
-0
DataDockController.java
...mos/boot/module/jg/biz/controller/DataDockController.java
+33
-26
DataDockServiceImpl.java
.../boot/module/jg/biz/service/impl/DataDockServiceImpl.java
+0
-0
IdxBizJgRegisterInfoServiceImpl.java
.../jg/biz/service/impl/IdxBizJgRegisterInfoServiceImpl.java
+29
-25
No files found.
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-api/src/main/java/com/yeejoin/amos/boot/module/jg/api/converter/DictParamsConverter.java
View file @
907d7e55
...
...
@@ -34,10 +34,6 @@ public class DictParamsConverter implements Converter<String> {
dictMap
.
put
(
"过热器出口集箱"
,
"6006"
);
dictMap
.
put
(
"启动分离器"
,
"6007"
);
dictMap
.
put
(
"长输管道"
,
"5994"
);
dictMap
.
put
(
"磁粉"
,
"5988"
);
dictMap
.
put
(
"射线"
,
"5986"
);
dictMap
.
put
(
"超声"
,
"5987"
);
dictMap
.
put
(
"渗透"
,
"5989"
);
dictMap
.
put
(
"A1"
,
"6094"
);
dictMap
.
put
(
"A2"
,
"6095"
);
dictMap
.
put
(
"A7"
,
"6100"
);
...
...
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-api/src/main/java/com/yeejoin/amos/boot/module/jg/api/dto/InspectConclusionConverter.java
0 → 100644
View file @
907d7e55
package
com
.
yeejoin
.
amos
.
boot
.
module
.
jg
.
api
.
dto
;
import
com.alibaba.excel.converters.Converter
;
import
com.alibaba.excel.enums.CellDataTypeEnum
;
import
com.alibaba.excel.metadata.CellData
;
import
com.alibaba.excel.metadata.GlobalConfiguration
;
import
com.alibaba.excel.metadata.property.ExcelContentProperty
;
import
java.util.HashMap
;
import
java.util.Map
;
public
class
InspectConclusionConverter
implements
Converter
<
String
>
{
private
static
final
Map
<
String
,
String
>
dictMap
=
new
HashMap
<>();
static
{
// 填充映射关系
dictMap
.
put
(
"合格"
,
"6040"
);
dictMap
.
put
(
"不合格"
,
"6041"
);
dictMap
.
put
(
"复检合格"
,
"6042"
);
dictMap
.
put
(
"复检不合格"
,
"6043"
);
dictMap
.
put
(
"整改后合格"
,
"6045"
);
dictMap
.
put
(
"符合"
,
"6046"
);
dictMap
.
put
(
"不符合"
,
"6047"
);
dictMap
.
put
(
"符合要求"
,
"6048"
);
dictMap
.
put
(
"基本符合要求"
,
"6049"
);
dictMap
.
put
(
"不符合要求"
,
"6050"
);
dictMap
.
put
(
"允许使用"
,
"6051"
);
dictMap
.
put
(
"降压使用"
,
"6052"
);
dictMap
.
put
(
"进行合于使用评价"
,
"6053"
);
dictMap
.
put
(
"其他"
,
"6044"
);
}
@Override
public
Class
<?>
supportJavaTypeKey
()
{
// 实体类中对象属性类型
return
String
.
class
;
}
@Override
public
CellDataTypeEnum
supportExcelTypeKey
()
{
return
CellDataTypeEnum
.
STRING
;
}
@Override
public
String
convertToJavaData
(
CellData
cellData
,
ExcelContentProperty
excelContentProperty
,
GlobalConfiguration
globalConfiguration
)
{
// 从Cell中读取数据
String
cellValue
=
cellData
.
getStringValue
();
// 判断Excel中的值,将其转换为预期的数值
return
dictMap
.
getOrDefault
(
cellValue
,
null
);
}
@Override
public
CellData
convertToExcelData
(
String
o
,
ExcelContentProperty
excelContentProperty
,
GlobalConfiguration
globalConfiguration
)
throws
Exception
{
return
new
CellData
(
""
);
}
}
\ No newline at end of file
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-api/src/main/java/com/yeejoin/amos/boot/module/jg/api/dto/InspectTypeConverter.java
0 → 100644
View file @
907d7e55
package
com
.
yeejoin
.
amos
.
boot
.
module
.
jg
.
api
.
dto
;
import
com.alibaba.excel.converters.Converter
;
import
com.alibaba.excel.enums.CellDataTypeEnum
;
import
com.alibaba.excel.metadata.CellData
;
import
com.alibaba.excel.metadata.GlobalConfiguration
;
import
com.alibaba.excel.metadata.property.ExcelContentProperty
;
import
java.util.HashMap
;
import
java.util.Map
;
public
class
InspectTypeConverter
implements
Converter
<
String
>
{
private
static
final
Map
<
String
,
String
>
dictMap
=
new
HashMap
<>();
static
{
// 填充映射关系
dictMap
.
put
(
"定期检验"
,
"DQJY"
);
dictMap
.
put
(
"首次检验"
,
"SCJY"
);
dictMap
.
put
(
"安装监督检验"
,
"AZJDJY"
);
dictMap
.
put
(
"改造监督检验"
,
"GZJDJY"
);
dictMap
.
put
(
"维修监督检验"
,
"WXJDJY"
);
dictMap
.
put
(
"制造监督检验"
,
"ZZJDJY"
);
}
@Override
public
Class
<?>
supportJavaTypeKey
()
{
// 实体类中对象属性类型
return
String
.
class
;
}
@Override
public
CellDataTypeEnum
supportExcelTypeKey
()
{
return
CellDataTypeEnum
.
STRING
;
}
@Override
public
String
convertToJavaData
(
CellData
cellData
,
ExcelContentProperty
excelContentProperty
,
GlobalConfiguration
globalConfiguration
)
{
// 从Cell中读取数据
String
cellValue
=
cellData
.
getStringValue
();
// 判断Excel中的值,将其转换为预期的数值
return
dictMap
.
getOrDefault
(
cellValue
,
null
);
}
@Override
public
CellData
convertToExcelData
(
String
o
,
ExcelContentProperty
excelContentProperty
,
GlobalConfiguration
globalConfiguration
)
throws
Exception
{
return
new
CellData
(
""
);
}
}
\ No newline at end of file
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-api/src/main/java/com/yeejoin/amos/boot/module/jg/api/dto/PipingExcelDto.java
0 → 100644
View file @
907d7e55
package
com
.
yeejoin
.
amos
.
boot
.
module
.
jg
.
api
.
dto
;
import
com.alibaba.excel.annotation.ExcelIgnore
;
import
com.alibaba.excel.annotation.ExcelProperty
;
import
com.yeejoin.amos.boot.biz.common.dto.BaseDto
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
import
lombok.EqualsAndHashCode
;
@Data
@EqualsAndHashCode
(
callSuper
=
true
)
@ApiModel
(
value
=
"管道-设备信息"
,
description
=
"管道-设备信息"
)
public
class
PipingExcelDto
extends
BaseDto
{
@ExcelIgnore
private
static
final
long
serialVersionUID
=
1L
;
//----------------------------------------------------------------------基本信息
@ApiModelProperty
(
value
=
"设备种类"
)
@ExcelIgnore
private
String
equList
;
@ApiModelProperty
(
value
=
"设备类别"
)
@ExcelIgnore
private
String
equCategory
;
@ApiModelProperty
(
value
=
"设备品种"
)
@ExcelIgnore
private
String
equDefine
;
@ApiModelProperty
(
value
=
"单位内编号"
)
@ExcelProperty
(
value
=
"单位内编号"
)
private
String
useInnerCode
;
@ApiModelProperty
(
value
=
"产品名称"
)
@ExcelProperty
(
value
=
"产品名称"
)
private
String
productName
;
@ApiModelProperty
(
value
=
"管道名称(登记单元)"
)
@ExcelProperty
(
value
=
"管道名称(登记单元)"
)
private
String
pipeName
;
@ApiModelProperty
(
value
=
"设备型号"
)
@ExcelProperty
(
value
=
"设备型号"
)
private
String
equType
;
@ApiModelProperty
(
value
=
"设备总价值(万元)"
)
@ExcelProperty
(
value
=
"设备总价值(万元)"
)
private
String
equPrice
;
@ApiModelProperty
(
value
=
"有无设备代码"
)
@ExcelProperty
(
value
=
"有无设备代码"
)
private
String
equCodeType
;
@ApiModelProperty
(
value
=
"设备代码"
)
@ExcelProperty
(
value
=
"设备代码"
)
private
String
equCode
;
@ApiModelProperty
(
value
=
"工程(装置)名称"
)
@ExcelProperty
(
value
=
"工程(装置)名称"
)
private
String
projectContraption
;
@ApiModelProperty
(
value
=
"工程(装置)编号"
)
@ExcelProperty
(
value
=
"工程(装置)编号"
)
private
String
projectContraptionNo
;
@ApiModelProperty
(
value
=
"使用登记证编号"
)
@ExcelProperty
(
value
=
"使用登记证编号"
)
private
String
useOrgCode
;
//-----------------------------------------------------------------------使用信息
@ApiModelProperty
(
value
=
"使用单位统一社会信用代码"
)
@ExcelProperty
(
value
=
"使用单位统一社会信用代码"
)
private
String
useUnitCode
;
@ApiModelProperty
(
value
=
"使用单位名称"
)
@ExcelProperty
(
value
=
"使用单位名称"
)
private
String
useUnit
;
//-----------------------------------------------------------------------安装信息
@ApiModelProperty
(
value
=
"安装单位统一社会信用代码"
)
@ExcelProperty
(
value
=
"安装单位统一社会信用代码"
)
private
String
installUnitCode
;
@ApiModelProperty
(
value
=
"安装单位名称"
)
@ExcelProperty
(
value
=
"安装单位名称"
)
private
String
installUnitName
;
//-----------------------------------------------------------------------检验检测信息
@ApiModelProperty
(
value
=
"检验检测机构统一社会信用代码"
)
@ExcelProperty
(
value
=
"检验检测机构统一社会信用代码"
)
private
String
inspectUnitCode
;
@ApiModelProperty
(
value
=
"检验检测机构名称"
)
@ExcelProperty
(
value
=
"检验检测机构名称"
)
private
String
inspectUnitName
;
@ApiModelProperty
(
value
=
"检验结论"
)
@ExcelProperty
(
value
=
"检验结论"
)
private
String
inspectConclusion
;
@ApiModelProperty
(
value
=
"检验类型"
)
@ExcelProperty
(
value
=
"检验类型"
)
private
String
inspectType
;
@ApiModelProperty
(
value
=
"检验日期"
)
@ExcelProperty
(
value
=
"检验日期"
)
private
String
inspectDate
;
@ApiModelProperty
(
value
=
"检验人员名称"
)
@ExcelProperty
(
value
=
"检验人员名称"
)
private
String
inspectPersonName
;
@ApiModelProperty
(
value
=
"下次检验日期"
)
@ExcelProperty
(
value
=
"下次检验日期"
)
private
String
nextInspectDate
;
@ApiModelProperty
(
value
=
"检验报告编号"
)
@ExcelProperty
(
value
=
"检验报告编号"
)
private
String
inspectReportCode
;
//-----------------------------------------------------------------------设计信息
@ApiModelProperty
(
value
=
"设计单位统一社会信用代码"
)
@ExcelProperty
(
value
=
"设计单位统一社会信用代码"
)
private
String
designUnitCreditCode
;
@ApiModelProperty
(
value
=
"设计单位名称"
)
@ExcelProperty
(
value
=
"设计单位名称"
)
private
String
designUnitName
;
//--------------------------------------------------------------------压力管道----技术参数
@ExcelProperty
(
value
=
"管道类别"
)
@ApiModelProperty
(
value
=
"管道类别"
)
private
String
pipelineClass
;
@ExcelProperty
(
value
=
"公称壁厚(mm)"
)
@ApiModelProperty
(
value
=
"公称壁厚(mm)"
)
private
String
wallThickness
;
@ExcelProperty
(
value
=
"公称直径(mm)"
)
@ApiModelProperty
(
value
=
"公称直径(mm)"
)
private
String
nominalDiameter
;
@ExcelProperty
(
value
=
"管道长度(m)"
)
@ApiModelProperty
(
value
=
"管道长度(m)"
)
private
String
pipeLength
;
@ExcelProperty
(
value
=
"设计-压力(MPa)"
)
@ApiModelProperty
(
value
=
"设计-压力(MPa)"
)
private
String
pressure
;
@ExcelProperty
(
value
=
"设计-介质"
)
@ApiModelProperty
(
value
=
"设计-介质"
)
private
String
medium
;
@ExcelProperty
(
value
=
"起/始位置 (经纬度)(格式:经度-纬度)"
)
@ApiModelProperty
(
value
=
"起/始位置 (经纬度)(格式:经度-纬度)"
)
private
String
startePosition
;
@ExcelProperty
(
value
=
"设计-温度(℃)"
)
@ApiModelProperty
(
value
=
"设计-温度(℃)"
)
private
String
temperature
;
@ExcelProperty
(
value
=
"管道编号"
)
@ApiModelProperty
(
value
=
"管道编号"
)
private
String
pipelineNumber
;
@ExcelProperty
(
value
=
"管道级别"
)
@ApiModelProperty
(
value
=
"管道级别"
)
private
String
deviceLevel
;
@ExcelProperty
(
value
=
"工作条件-压力(MPa)"
)
@ApiModelProperty
(
value
=
"工作条件-压力(MPa)"
)
private
String
workPressure
;
@ExcelProperty
(
value
=
"工作条件-温度(℃)"
)
@ApiModelProperty
(
value
=
"工作条件-温度(℃)"
)
private
String
workTemperature
;
@ExcelProperty
(
value
=
"工作条件-介质"
)
@ApiModelProperty
(
value
=
"工作条件-介质"
)
private
String
workMedium
;
@ExcelProperty
(
value
=
"备注"
)
@ApiModelProperty
(
value
=
"备注"
)
private
String
remarks
;
}
\ No newline at end of file
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-biz/src/main/java/com/yeejoin/amos/boot/module/jg/biz/controller/DataDockController.java
View file @
907d7e55
...
...
@@ -7,6 +7,7 @@ import org.apache.commons.io.FilenameUtils;
import
org.springframework.validation.annotation.Validated
;
import
org.springframework.web.bind.annotation.*
;
import
org.springframework.web.multipart.MultipartFile
;
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
;
...
...
@@ -58,32 +59,38 @@ public class DataDockController {
return
ResponseHelper
.
buildResponse
(
dataDockService
.
dataCheckAndImportEquipmentData
(
remark
,
file
));
}
// @TycloudOperation(ApiLevel = UserType.AGENCY)
// @PostMapping(value = "/delete")
// @ApiOperation(httpMethod = "POST", value = "八大类历史设备导入shanchu", notes = "八大类历史设备导入shachu")
// public Object importData() {
// dataDockService.delete();
// return ResponseHelper.buildResponse("ok");
// }
/**
* 工业管道批量检查
**/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@PostMapping
(
value
=
"/checkGYGDData"
)
@ApiOperation
(
httpMethod
=
"POST"
,
value
=
"工业管道批量检查"
,
notes
=
"工业管道批量检查"
)
@RestEventTrigger
(
value
=
"operateLogRestEventHandler"
)
public
ResponseModel
<?>
checkGYGDData
(
@RequestPart
(
"file"
)
MultipartFile
multipartFile
)
throws
Exception
{
return
ResponseHelper
.
buildResponse
(
dataDockService
.
checkGDData
(
multipartFile
,
true
));
}
/**
* 工业 、公用、长输管道批量保存
**/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@PostMapping
(
value
=
"/savePipingData"
)
@ApiOperation
(
httpMethod
=
"POST"
,
value
=
"工业管道批量保存"
,
notes
=
"工业管道批量保存"
)
@RestEventTrigger
(
value
=
"operateLogRestEventHandler"
)
public
ResponseModel
<?>
savePipingData
(
@RequestBody
Map
<
String
,
Object
>
paramMap
)
{
return
ResponseHelper
.
buildResponse
(
dataDockService
.
savePipingData
(
paramMap
));
}
/**
* 公用、长输道批量检查
**/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@PostMapping
(
value
=
"/checkGYCSGDData"
)
@ApiOperation
(
httpMethod
=
"POST"
,
value
=
"公用、长输管道批量检查"
,
notes
=
"公用、长输管道批量检查"
)
@RestEventTrigger
(
value
=
"operateLogRestEventHandler"
)
public
ResponseModel
<?>
checkGYCSGDData
(
@RequestPart
(
"file"
)
MultipartFile
multipartFile
)
throws
Exception
{
return
ResponseHelper
.
buildResponse
(
dataDockService
.
checkGDData
(
multipartFile
,
false
));
}
// @TycloudOperation(ApiLevel = UserType.AGENCY)
// @GetMapping(value = "/yanChang/ORG_BRANCH_CODE")
// @ApiOperation(httpMethod = "get", value = "延炼-延长-刷入属地监管部门", notes = "延炼-延长-刷入属地监管部门")
// public Object writeOrgBranchCode2YanChang(@RequestParam String remark) {
// if (ValidationUtil.isEmpty(remark)) {
// throw new BadRequest("remark必填!");
// }
// return ResponseHelper.buildResponse("更新成功,共" + dataDockService.writeOrgBranchCode2YanChang(remark) + "条数据");
// }
//
// @TycloudOperation(ApiLevel = UserType.AGENCY)
// @GetMapping(value = "/yanChang/USE_PLACE")
// @ApiOperation(httpMethod = "get", value = "延炼-延长-刷入所属区域", notes = "延炼-延长-刷入所属区域")
// public Object writeUsePlace2YanChang(@RequestParam String remark) {
// if (ValidationUtil.isEmpty(remark)) {
// throw new BadRequest("remark必填!");
// }
// return ResponseHelper.buildResponse("更新成功,共" + dataDockService.writeUsePlace2YanChang(remark) + "条数据");
// }
}
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-biz/src/main/java/com/yeejoin/amos/boot/module/jg/biz/service/impl/DataDockServiceImpl.java
View file @
907d7e55
This diff is collapsed.
Click to expand it.
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-biz/src/main/java/com/yeejoin/amos/boot/module/jg/biz/service/impl/IdxBizJgRegisterInfoServiceImpl.java
View file @
907d7e55
...
...
@@ -138,7 +138,6 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
public
static
final
String
DATA_SOURCE_NAME
=
"DATA_SOURCE_NAME"
;
public
static
final
String
USE_PLACE_CODE
=
"USE_PLACE_CODE"
;
public
static
final
String
EQU_CATEGORY_CODE
=
"EQU_CATEGORY_CODE"
;
public
static
final
String
EQU_LIST_CODE
=
"EQU_LIST_CODE"
;
public
static
final
String
PROJECT_CONTRAPTION
=
"PROJECT_CONTRAPTION"
;
// 工程装置名称
/**
* 业务类型 0:单个新增 1:批量导入
...
...
@@ -394,9 +393,9 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
}
LinkedHashMap
equipmentInfoForm
=
(
LinkedHashMap
)
checkAndCast
(
paramMap
.
get
(
EQUIP_INFO_FORM_ID
));
String
dataSource
=
(
String
)
equipmentInfoForm
.
get
(
DATA_SOURCE
);
String
equ
ListCode
=
(
String
)
equipmentInfoForm
.
get
(
EQU_LIST
);
String
equ
Category
=
(
String
)
equipmentInfoForm
.
get
(
EQU_CATEGORY
);
//管道添加设备
if
(
PipelineEnum
.
PRESSURE_PIPELINE
.
getCode
().
equals
(
equListCode
))
{
if
(
PipelineEnum
.
INDUSTRIAL_PIPELINE
.
getCode
().
equals
(
equCategory
))
{
return
this
.
pipelineEquipCreateOrUpdate
(
paramMap
);
}
if
(
dataSource
.
contains
(
"black"
)){
...
...
@@ -1143,15 +1142,21 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
if
(
"his"
.
equals
(
dataSource
)
||
"black"
.
equals
(
dataSource
))
{
// 历史数据导入设备类别限制 bug-21172
if
(!
ObjectUtils
.
isEmpty
(
type
)
&&
"PL_DR"
.
equals
(
type
))
{
return
this
.
baseMapper
.
queryAllEquCategoriesUnderTheEquList
(
equList
).
stream
()
.
filter
(
x
->
"2300"
.
equals
(
x
.
getDictDataKey
()))
.
collect
(
Collectors
.
toList
());
}
// 历史数据新增设备类别限制 bug-21139
if
(!
ObjectUtils
.
isEmpty
(
equList
)
&&
"8000"
.
equals
(
equList
))
{
return
this
.
baseMapper
.
queryAllEquCategoriesUnderTheEquList
(
equList
).
stream
()
.
filter
(
x
->
"8300"
.
equals
(
x
.
getDictDataKey
()))
.
collect
(
Collectors
.
toList
());
if
(
EquipmentClassifityEnum
.
YLRQ
.
getCode
().
equals
(
equList
))
{
return
this
.
baseMapper
.
queryAllEquCategoriesUnderTheEquList
(
equList
).
stream
()
.
filter
(
x
->
"2300"
.
equals
(
x
.
getDictDataKey
()))
.
collect
(
Collectors
.
toList
());
}
if
(
EquipmentClassifityEnum
.
YLGD
.
getCode
().
equals
(
equList
)
&&
"his"
.
equals
(
dataSource
))
{
return
this
.
baseMapper
.
queryAllEquCategoriesUnderTheEquList
(
equList
).
stream
()
.
filter
(
x
->
"8300"
.
equals
(
x
.
getDictDataKey
()))
.
collect
(
Collectors
.
toList
());
}
if
(
EquipmentClassifityEnum
.
YLGD
.
getCode
().
equals
(
equList
)
&&
"black"
.
equals
(
dataSource
))
{
return
this
.
baseMapper
.
queryAllEquCategoriesUnderTheEquList
(
equList
).
stream
()
.
filter
(
x
->
!
"8300"
.
equals
(
x
.
getDictDataKey
()))
.
collect
(
Collectors
.
toList
());
}
}
return
this
.
baseMapper
.
queryAllEquCategoriesUnderTheEquList
(
equList
);
}
...
...
@@ -2474,19 +2479,13 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
boolMust
.
must
(
scBuilder
);
}
// 设备种类编码
if
(!
ObjectUtils
.
isEmpty
(
map
.
getString
(
EQU_LIST_CODE
)))
{
if
(!
ObjectUtils
.
isEmpty
(
map
.
getString
(
"EQU_LIST_CODE"
)))
{
BoolQueryBuilder
elcBuilder
=
QueryBuilders
.
boolQuery
();
String
test
=
QueryParser
.
escape
(
map
.
getString
(
EQU_LIST_CODE
));
elcBuilder
.
must
(
QueryBuilders
.
matchPhraseQuery
(
EQU_LIST_CODE
,
test
));
String
test
=
QueryParser
.
escape
(
map
.
getString
(
"EQU_LIST_CODE"
));
elcBuilder
.
must
(
QueryBuilders
.
matchPhraseQuery
(
"EQU_LIST_CODE"
,
test
));
boolMust
.
must
(
elcBuilder
);
}
else
{
BoolQueryBuilder
pBuilder
=
QueryBuilders
.
boolQuery
();
String
test
=
QueryParser
.
escape
(
"8000"
);
//不查管道,管道新菜单查询
pBuilder
.
mustNot
(
QueryBuilders
.
termQuery
(
EQU_LIST_CODE
,
test
));
boolMust
.
must
(
pBuilder
);
}
// 设备品种编码
// 设备类别编码
if
(!
ObjectUtils
.
isEmpty
(
map
.
getString
(
"EQU_DEFINE_CODE"
)))
{
BoolQueryBuilder
elcBuilder
=
QueryBuilders
.
boolQuery
();
String
test
=
QueryParser
.
escape
(
map
.
getString
(
"EQU_DEFINE_CODE"
));
...
...
@@ -2507,6 +2506,11 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
String
test
=
QueryParser
.
escape
(
map
.
getString
(
EQU_CATEGORY_CODE
));
pBuilder
.
must
(
QueryBuilders
.
termQuery
(
EQU_CATEGORY_CODE
,
test
));
boolMust
.
must
(
pBuilder
);
}
else
{
BoolQueryBuilder
pBuilder
=
QueryBuilders
.
boolQuery
();
String
test
=
QueryParser
.
escape
(
"8300"
);
// 不查管道,管道新菜单查询
pBuilder
.
mustNot
(
QueryBuilders
.
termQuery
(
EQU_CATEGORY_CODE
,
test
));
boolMust
.
must
(
pBuilder
);
}
// 是否车用气瓶
if
(!
ObjectUtils
.
isEmpty
(
map
.
getString
(
WHETHER_VEHICLE_CYLINDER
)))
{
...
...
@@ -3823,7 +3827,7 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
otherInfo
.
setRecDate
(
new
Date
());
otherInfo
.
setCylinderStampAttachment
(
cylinderStampAttachment
);
if
(
"his"
.
equals
(
equipInfoDto
.
getDataSource
()))
{
otherInfo
.
setSupervisoryCode
(
this
.
getSupervisoryCode
(
equipInfoDto
.
getPossession
(),
registerInfo
));
otherInfo
.
setSupervisoryCode
(
this
.
getSupervisoryCode
(
equipInfoDto
.
getPossession
(),
registerInfo
.
getEquCategory
()
));
}
otherInfo
.
setClaimStatus
(
"已认领"
);
otherInfoList
.
add
(
otherInfo
);
...
...
@@ -4337,13 +4341,13 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
/**
* 生成监管码
*/
p
rivate
String
getSupervisoryCode
(
String
possession
,
IdxBizJgRegisterInfo
registerInfo
)
{
p
ublic
String
getSupervisoryCode
(
String
possession
,
String
equCategory
)
{
Map
<
String
,
Object
>
map
=
new
HashMap
<>();
boolean
isXiXian
=
XI_XIAN
.
getCode
().
equals
(
possession
);
String
cityOrCountyCode
=
isXiXian
?
XIAN_YANG
.
getCode
()
:
possession
;
map
.
put
(
"cityCode"
,
cityOrCountyCode
);
map
.
put
(
"isXiXian"
,
isXiXian
?
1
:
0
);
map
.
put
(
"equCategory"
,
registerInfo
.
getEquCategory
()
);
map
.
put
(
"equCategory"
,
equCategory
);
map
.
put
(
"countyCode"
,
cityOrCountyCode
);
return
Optional
.
ofNullable
(
tzsServiceFeignClient
.
createCode
(
map
).
getResult
())
.
filter
(
res
->
!
res
.
isEmpty
())
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment