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
84aa64e4
Commit
84aa64e4
authored
Jul 15, 2024
by
王果
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
21125 监管业务已纳管设备列表无法查询到一码通修改数据后的设备
parent
b20cc188
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
77 additions
and
59 deletions
+77
-59
IdxBizJqEquipmentRegisterController.java
...g/biz/controller/IdxBizJqEquipmentRegisterController.java
+13
-13
IdxBizJgRegisterInfoServiceImpl.java
.../jg/biz/service/impl/IdxBizJgRegisterInfoServiceImpl.java
+64
-46
No files found.
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-biz/src/main/java/com/yeejoin/amos/boot/module/jg/biz/controller/IdxBizJqEquipmentRegisterController.java
View file @
84aa64e4
...
@@ -110,19 +110,19 @@ public class IdxBizJqEquipmentRegisterController extends BaseController {
...
@@ -110,19 +110,19 @@ public class IdxBizJqEquipmentRegisterController extends BaseController {
JSONObject
jsonObject
=
new
JSONObject
(
map
);
JSONObject
jsonObject
=
new
JSONObject
(
map
);
return
ResponseHelper
.
buildResponse
(
idxBizJgRegisterInfoService
.
queryForEquipmentRegisterPage
(
jsonObject
));
return
ResponseHelper
.
buildResponse
(
idxBizJgRegisterInfoService
.
queryForEquipmentRegisterPage
(
jsonObject
));
}
}
/**
//
/**
* 查询设备注册列表
//
* 查询设备注册列表
*
//
*
* @param map
//
* @param map
* @return
//
* @return
*/
//
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
//
@TycloudOperation(ApiLevel = UserType.AGENCY)
@GetMapping
(
value
=
"/pageHistory"
)
//
@GetMapping(value = "/pageHistory")
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"设备注册信息分页查询"
,
notes
=
"设备注册信息分页查询"
)
//
@ApiOperation(httpMethod = "GET", value = "设备注册信息分页查询", notes = "设备注册信息分页查询")
public
ResponseModel
<
Page
<
JSONObject
>>
queryForPageHistory
(
@RequestParam
Map
<
String
,
Object
>
map
)
{
//
public ResponseModel<Page<JSONObject>> queryForPageHistory(@RequestParam Map<String, Object> map) {
JSONObject
jsonObject
=
new
JSONObject
(
map
);
//
JSONObject jsonObject = new JSONObject(map);
return
ResponseHelper
.
buildResponse
(
idxBizJgRegisterInfoService
.
queryForEquipmentRegisterPageHistory
(
jsonObject
));
//
return ResponseHelper.buildResponse(idxBizJgRegisterInfoService.queryForEquipmentRegisterPageHistory(jsonObject));
}
//
}
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@GetMapping
(
value
=
"/category/list"
)
@GetMapping
(
value
=
"/category/list"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"查询不同单位类型可新增的设备种类列表"
,
notes
=
"查询不同单位类型可新增的设备种类列表"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"查询不同单位类型可新增的设备种类列表"
,
notes
=
"查询不同单位类型可新增的设备种类列表"
)
...
...
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 @
84aa64e4
...
@@ -28,7 +28,6 @@ import com.yeejoin.amos.boot.module.jg.api.dto.EquipmentInfoDto;
...
@@ -28,7 +28,6 @@ import com.yeejoin.amos.boot.module.jg.api.dto.EquipmentInfoDto;
import
com.yeejoin.amos.boot.module.jg.api.entity.JgCertificateChangeRecord
;
import
com.yeejoin.amos.boot.module.jg.api.entity.JgCertificateChangeRecord
;
import
com.yeejoin.amos.boot.module.jg.api.entity.JgCertificateChangeRecordEq
;
import
com.yeejoin.amos.boot.module.jg.api.entity.JgCertificateChangeRecordEq
;
import
com.yeejoin.amos.boot.module.jg.api.entity.JgUseRegistrationManage
;
import
com.yeejoin.amos.boot.module.jg.api.entity.JgUseRegistrationManage
;
import
com.yeejoin.amos.boot.module.jg.api.entity.JgVehicleInformation
;
import
com.yeejoin.amos.boot.module.jg.api.enums.*
;
import
com.yeejoin.amos.boot.module.jg.api.enums.*
;
import
com.yeejoin.amos.boot.module.jg.api.mapper.CommonMapper
;
import
com.yeejoin.amos.boot.module.jg.api.mapper.CommonMapper
;
import
com.yeejoin.amos.boot.module.jg.api.mapper.JgUseRegistrationMapper
;
import
com.yeejoin.amos.boot.module.jg.api.mapper.JgUseRegistrationMapper
;
...
@@ -43,7 +42,10 @@ import com.yeejoin.amos.boot.module.ymt.api.entity.*;
...
@@ -43,7 +42,10 @@ import com.yeejoin.amos.boot.module.ymt.api.entity.*;
import
com.yeejoin.amos.boot.module.ymt.api.enums.ApplicationFormTypeEnum
;
import
com.yeejoin.amos.boot.module.ymt.api.enums.ApplicationFormTypeEnum
;
import
com.yeejoin.amos.boot.module.ymt.api.enums.EquimentEnum
;
import
com.yeejoin.amos.boot.module.ymt.api.enums.EquimentEnum
;
import
com.yeejoin.amos.boot.module.ymt.api.enums.EquipmentClassifityEnum
;
import
com.yeejoin.amos.boot.module.ymt.api.enums.EquipmentClassifityEnum
;
import
com.yeejoin.amos.boot.module.ymt.api.mapper.*
;
import
com.yeejoin.amos.boot.module.ymt.api.mapper.CategoryOtherInfoMapper
;
import
com.yeejoin.amos.boot.module.ymt.api.mapper.IdxBizJgRegisterInfoMapper
;
import
com.yeejoin.amos.boot.module.ymt.api.mapper.RegistrationInfoMapper
;
import
com.yeejoin.amos.boot.module.ymt.api.mapper.SuperviseInfoMapper
;
import
com.yeejoin.amos.component.feign.utils.FeignUtil
;
import
com.yeejoin.amos.component.feign.utils.FeignUtil
;
import
com.yeejoin.amos.feign.privilege.Privilege
;
import
com.yeejoin.amos.feign.privilege.Privilege
;
import
com.yeejoin.amos.feign.privilege.model.CompanyModel
;
import
com.yeejoin.amos.feign.privilege.model.CompanyModel
;
...
@@ -76,6 +78,7 @@ import org.typroject.tyboot.core.rdbms.service.BaseService;
...
@@ -76,6 +78,7 @@ import org.typroject.tyboot.core.rdbms.service.BaseService;
import
org.typroject.tyboot.core.restful.exception.instance.BadRequest
;
import
org.typroject.tyboot.core.restful.exception.instance.BadRequest
;
import
org.typroject.tyboot.core.restful.utils.ResponseHelper
;
import
org.typroject.tyboot.core.restful.utils.ResponseHelper
;
import
org.typroject.tyboot.core.restful.utils.ResponseModel
;
import
org.typroject.tyboot.core.restful.utils.ResponseModel
;
import
java.io.IOException
;
import
java.io.IOException
;
import
java.lang.reflect.Field
;
import
java.lang.reflect.Field
;
import
java.sql.Timestamp
;
import
java.sql.Timestamp
;
...
@@ -86,6 +89,7 @@ import java.time.ZoneId;
...
@@ -86,6 +89,7 @@ import java.time.ZoneId;
import
java.time.format.DateTimeFormatter
;
import
java.time.format.DateTimeFormatter
;
import
java.util.*
;
import
java.util.*
;
import
java.util.stream.Collectors
;
import
java.util.stream.Collectors
;
import
static
com
.
alibaba
.
fastjson
.
JSON
.
toJSONString
;
import
static
com
.
alibaba
.
fastjson
.
JSON
.
toJSONString
;
import
static
com
.
yeejoin
.
amos
.
boot
.
module
.
jg
.
api
.
enums
.
CylinderTypeEnum
.
SPECIAL_CYLINDER
;
import
static
com
.
yeejoin
.
amos
.
boot
.
module
.
jg
.
api
.
enums
.
CylinderTypeEnum
.
SPECIAL_CYLINDER
;
import
static
com
.
yeejoin
.
amos
.
boot
.
module
.
jg
.
api
.
enums
.
VehicleApanageEnum
.
XIAN_YANG
;
import
static
com
.
yeejoin
.
amos
.
boot
.
module
.
jg
.
api
.
enums
.
VehicleApanageEnum
.
XIAN_YANG
;
...
@@ -539,9 +543,9 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
...
@@ -539,9 +543,9 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
}
}
@Override
@Override
public
List
<
DictionarieValueModel
>
equCategoryListByCompanyType
(
ReginParams
selectedOrgInfo
,
String
equList
,
String
businessScenarios
,
String
dataSource
)
{
public
List
<
DictionarieValueModel
>
equCategoryListByCompanyType
(
ReginParams
selectedOrgInfo
,
String
equList
,
String
businessScenarios
,
String
dataSource
)
{
// 历史设备录入 直接取所有的设备种类(equList)下的所有设备类别
// 历史设备录入 直接取所有的设备种类(equList)下的所有设备类别
if
(
"his"
.
equals
(
dataSource
)){
if
(
"his"
.
equals
(
dataSource
))
{
return
this
.
baseMapper
.
queryAllEquCategoriesUnderTheEquList
(
equList
);
return
this
.
baseMapper
.
queryAllEquCategoriesUnderTheEquList
(
equList
);
}
}
...
@@ -552,7 +556,7 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
...
@@ -552,7 +556,7 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
}
}
String
dictCode
=
String
.
format
(
"%s_%s"
,
dictCodePrefix
,
equipAddDictCodeSuffix
);
String
dictCode
=
String
.
format
(
"%s_%s"
,
dictCodePrefix
,
equipAddDictCodeSuffix
);
List
<
DictionarieValueModel
>
result
=
FeignUtil
.
remoteCall
(()
->
Systemctl
.
dictionarieClient
.
dictValues
(
dictCode
));
List
<
DictionarieValueModel
>
result
=
FeignUtil
.
remoteCall
(()
->
Systemctl
.
dictionarieClient
.
dictValues
(
dictCode
));
if
(
CompanyTypeEnum
.
CONSTRUCTION
.
getName
().
equals
(
companyType
)
||
ValidationUtil
.
isEmpty
(
businessScenarios
)){
if
(
CompanyTypeEnum
.
CONSTRUCTION
.
getName
().
equals
(
companyType
)
||
ValidationUtil
.
isEmpty
(
businessScenarios
))
{
return
result
;
return
result
;
}
}
// 初始化collect列表
// 初始化collect列表
...
@@ -1262,7 +1266,6 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
...
@@ -1262,7 +1266,6 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
return
new
Page
<>();
return
new
Page
<>();
}
}
Integer
pageNumber
=
ObjectUtils
.
isEmpty
(
map
.
getInteger
(
"number"
))
?
1
:
map
.
getInteger
(
"number"
);
Integer
pageNumber
=
ObjectUtils
.
isEmpty
(
map
.
getInteger
(
"number"
))
?
1
:
map
.
getInteger
(
"number"
);
Integer
size
=
ObjectUtils
.
isEmpty
(
map
.
getInteger
(
"size"
))
?
20
:
map
.
getInteger
(
"size"
);
Integer
size
=
ObjectUtils
.
isEmpty
(
map
.
getInteger
(
"size"
))
?
20
:
map
.
getInteger
(
"size"
);
Page
<
JSONObject
>
result
=
new
Page
<>(
pageNumber
,
size
);
Page
<
JSONObject
>
result
=
new
Page
<>(
pageNumber
,
size
);
...
@@ -1315,8 +1318,18 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
...
@@ -1315,8 +1318,18 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
// DATA_SOURCE 为“jg”开头的数据(从监管新加或复制的设备)
// DATA_SOURCE 为“jg”开头的数据(从监管新加或复制的设备)
// 20240314 提出的监管业务不要让企业用户选到之前一码通认领或补录的设备,让从监管业务中去新增
// 20240314 提出的监管业务不要让企业用户选到之前一码通认领或补录的设备,让从监管业务中去新增
BoolQueryBuilder
dBuilder
=
QueryBuilders
.
boolQuery
();
BoolQueryBuilder
dBuilder
=
QueryBuilders
.
boolQuery
();
if
(
map
.
containsKey
(
"DATA_SOURCE"
)
&&
!
ObjectUtils
.
isEmpty
(
map
.
get
(
"DATA_SOURCE"
)))
{
if
(
"jg_his"
.
equals
(
map
.
get
(
"DATA_SOURCE"
)))
{
//只查历史,前缀jg_his
dBuilder
.
must
(
QueryBuilders
.
prefixQuery
(
"DATA_SOURCE"
,
"jg_his"
));
}
else
if
(!
"jg_his"
.
equals
(
map
.
getString
(
"DATA_SOURCE"
)))
{
//只查新增,前缀为jg且前缀不为jg_his
dBuilder
.
must
(
QueryBuilders
.
prefixQuery
(
"DATA_SOURCE"
,
"jg"
));
dBuilder
.
mustNot
(
QueryBuilders
.
prefixQuery
(
"DATA_SOURCE"
,
"jg_his"
));
}
}
else
{
//查所有,前缀jg
dBuilder
.
must
(
QueryBuilders
.
prefixQuery
(
"DATA_SOURCE"
,
"jg"
));
dBuilder
.
must
(
QueryBuilders
.
prefixQuery
(
"DATA_SOURCE"
,
"jg"
));
// dBuilder.mustNot(QueryBuilders.prefixQuery("DATA_SOURCE","jg_his"));
}
boolMust
.
must
(
dBuilder
);
boolMust
.
must
(
dBuilder
);
String
queryType
=
map
.
getString
(
"QUERY_TYPE"
);
String
queryType
=
map
.
getString
(
"QUERY_TYPE"
);
...
@@ -1339,14 +1352,14 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
...
@@ -1339,14 +1352,14 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
syBuilder
.
mustNot
(
QueryBuilders
.
wildcardQuery
(
"USE_ORG_CODE"
,
"*"
));
syBuilder
.
mustNot
(
QueryBuilders
.
wildcardQuery
(
"USE_ORG_CODE"
,
"*"
));
boolMust
.
must
(
syBuilder
);
boolMust
.
must
(
syBuilder
);
this
.
setRepeatUsedCheckFilterParam
(
boolMust
,
companyCode
,
"useRegister"
);
this
.
setRepeatUsedCheckFilterParam
(
boolMust
,
companyCode
,
"useRegister"
);
}
else
if
(
ValidationUtil
.
equals
(
queryType
,
"FINISH_SY"
))
{
}
else
if
(
ValidationUtil
.
equals
(
queryType
,
"FINISH_SY"
))
{
// 注意:上面条件是过滤出【未做过】某个业务的设备,下面部分是过滤出【做过】某个业务的设备
// 注意:上面条件是过滤出【未做过】某个业务的设备,下面部分是过滤出【做过】某个业务的设备
// 查询 已经做过【使用登记】 的设备 【(EQU_STATUS != 空 ) && (USE_ORG_CODE(使用登记证编号) != 空)】
// 查询 已经做过【使用登记】 的设备 【(EQU_STATUS != 空 ) && (USE_ORG_CODE(使用登记证编号) != 空)】
BoolQueryBuilder
syBuilder
=
QueryBuilders
.
boolQuery
();
BoolQueryBuilder
syBuilder
=
QueryBuilders
.
boolQuery
();
syBuilder
.
must
(
QueryBuilders
.
existsQuery
(
"EQU_STATE"
))
syBuilder
.
must
(
QueryBuilders
.
existsQuery
(
"EQU_STATE"
))
.
must
(
QueryBuilders
.
wildcardQuery
(
"USE_ORG_CODE"
,
"*"
));
.
must
(
QueryBuilders
.
wildcardQuery
(
"USE_ORG_CODE"
,
"*"
));
boolMust
.
must
(
syBuilder
);
boolMust
.
must
(
syBuilder
);
}
else
if
(
ValidationUtil
.
equals
(
queryType
,
"GZ_GZ"
)
||
ValidationUtil
.
equals
(
queryType
,
"GZ_WX"
)
||
ValidationUtil
.
equals
(
queryType
,
"GZ_YZ"
))
{
}
else
if
(
ValidationUtil
.
equals
(
queryType
,
"GZ_GZ"
)
||
ValidationUtil
.
equals
(
queryType
,
"GZ_WX"
)
||
ValidationUtil
.
equals
(
queryType
,
"GZ_YZ"
))
{
BoolQueryBuilder
syBuilder
=
QueryBuilders
.
boolQuery
();
BoolQueryBuilder
syBuilder
=
QueryBuilders
.
boolQuery
();
syBuilder
.
must
(
QueryBuilders
.
existsQuery
(
"EQU_STATE"
));
syBuilder
.
must
(
QueryBuilders
.
existsQuery
(
"EQU_STATE"
));
syBuilder
.
must
(
QueryBuilders
.
wildcardQuery
(
"USE_ORG_CODE"
,
"*"
));
syBuilder
.
must
(
QueryBuilders
.
wildcardQuery
(
"USE_ORG_CODE"
,
"*"
));
...
@@ -1682,14 +1695,14 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
...
@@ -1682,14 +1695,14 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
syBuilder
.
mustNot
(
QueryBuilders
.
wildcardQuery
(
"USE_ORG_CODE"
,
"*"
));
syBuilder
.
mustNot
(
QueryBuilders
.
wildcardQuery
(
"USE_ORG_CODE"
,
"*"
));
boolMust
.
must
(
syBuilder
);
boolMust
.
must
(
syBuilder
);
this
.
setRepeatUsedCheckFilterParam
(
boolMust
,
companyCode
,
"useRegister"
);
this
.
setRepeatUsedCheckFilterParam
(
boolMust
,
companyCode
,
"useRegister"
);
}
else
if
(
ValidationUtil
.
equals
(
queryType
,
"FINISH_SY"
))
{
}
else
if
(
ValidationUtil
.
equals
(
queryType
,
"FINISH_SY"
))
{
// 注意:上面条件是过滤出【未做过】某个业务的设备,下面部分是过滤出【做过】某个业务的设备
// 注意:上面条件是过滤出【未做过】某个业务的设备,下面部分是过滤出【做过】某个业务的设备
// 查询 已经做过【使用登记】 的设备 【(EQU_STATUS != 空 ) && (USE_ORG_CODE(使用登记证编号) != 空)】
// 查询 已经做过【使用登记】 的设备 【(EQU_STATUS != 空 ) && (USE_ORG_CODE(使用登记证编号) != 空)】
BoolQueryBuilder
syBuilder
=
QueryBuilders
.
boolQuery
();
BoolQueryBuilder
syBuilder
=
QueryBuilders
.
boolQuery
();
syBuilder
.
must
(
QueryBuilders
.
existsQuery
(
"EQU_STATE"
))
syBuilder
.
must
(
QueryBuilders
.
existsQuery
(
"EQU_STATE"
))
.
must
(
QueryBuilders
.
wildcardQuery
(
"USE_ORG_CODE"
,
"*"
));
.
must
(
QueryBuilders
.
wildcardQuery
(
"USE_ORG_CODE"
,
"*"
));
boolMust
.
must
(
syBuilder
);
boolMust
.
must
(
syBuilder
);
}
else
if
(
ValidationUtil
.
equals
(
queryType
,
"GZ_GZ"
)
||
ValidationUtil
.
equals
(
queryType
,
"GZ_WX"
)
||
ValidationUtil
.
equals
(
queryType
,
"GZ_YZ"
))
{
}
else
if
(
ValidationUtil
.
equals
(
queryType
,
"GZ_GZ"
)
||
ValidationUtil
.
equals
(
queryType
,
"GZ_WX"
)
||
ValidationUtil
.
equals
(
queryType
,
"GZ_YZ"
))
{
BoolQueryBuilder
syBuilder
=
QueryBuilders
.
boolQuery
();
BoolQueryBuilder
syBuilder
=
QueryBuilders
.
boolQuery
();
syBuilder
.
must
(
QueryBuilders
.
existsQuery
(
"EQU_STATE"
));
syBuilder
.
must
(
QueryBuilders
.
existsQuery
(
"EQU_STATE"
));
syBuilder
.
must
(
QueryBuilders
.
wildcardQuery
(
"USE_ORG_CODE"
,
"*"
));
syBuilder
.
must
(
QueryBuilders
.
wildcardQuery
(
"USE_ORG_CODE"
,
"*"
));
...
@@ -2395,6 +2408,7 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
...
@@ -2395,6 +2408,7 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
});
});
return
result
;
return
result
;
}
}
@Override
@Override
public
Page
<
JSONObject
>
queryEquipCanUsedByVesselPageHistory
(
JSONObject
jsonObject
)
{
public
Page
<
JSONObject
>
queryEquipCanUsedByVesselPageHistory
(
JSONObject
jsonObject
)
{
ReginParams
reginParams
=
JSON
.
parseObject
(
redisUtils
.
get
(
RedisKey
.
buildReginKey
(
RequestContext
.
getExeUserId
(),
RequestContext
.
getToken
())).
toString
(),
ReginParams
.
class
);
ReginParams
reginParams
=
JSON
.
parseObject
(
redisUtils
.
get
(
RedisKey
.
buildReginKey
(
RequestContext
.
getExeUserId
(),
RequestContext
.
getToken
())).
toString
(),
ReginParams
.
class
);
...
@@ -2426,7 +2440,7 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
...
@@ -2426,7 +2440,7 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
.
doRead
();
.
doRead
();
return
pressureVesselListener
.
getResult
();
return
pressureVesselListener
.
getResult
();
}
catch
(
Exception
e
)
{
}
catch
(
Exception
e
)
{
String
err
=
(
e
.
getCause
()
instanceof
BadRequest
)
?
"模版数据填写有误:"
+
e
.
getCause
().
getMessage
()
:
"导入时出现异常:请联系管理员!"
;
String
err
=
(
e
.
getCause
()
instanceof
BadRequest
)
?
"模版数据填写有误:"
+
e
.
getCause
().
getMessage
()
:
"导入时出现异常:请联系管理员!"
;
throw
new
BadRequest
(
err
);
throw
new
BadRequest
(
err
);
}
}
}
}
...
@@ -2434,7 +2448,8 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
...
@@ -2434,7 +2448,8 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
@Override
@Override
public
Object
importPressureData
(
MultipartFile
multipartFile
)
throws
Exception
{
public
Object
importPressureData
(
MultipartFile
multipartFile
)
throws
Exception
{
List
<
EquipInfoCylinderExcelDto
>
aircraftList
=
new
ArrayList
<>();
List
<
EquipInfoCylinderExcelDto
>
aircraftList
=
new
ArrayList
<>();
resultError
.
clear
();
useInnerCodeList
.
clear
();
resultError
.
clear
();
useInnerCodeList
.
clear
();
equCodeList
.
clear
();
equCodeList
.
clear
();
factoryNumList
.
clear
();
factoryNumList
.
clear
();
try
{
try
{
...
@@ -2443,13 +2458,14 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
...
@@ -2443,13 +2458,14 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
@Override
@Override
public
void
invoke
(
EquipInfoCylinderExcelDto
data
,
AnalysisContext
context
)
{
public
void
invoke
(
EquipInfoCylinderExcelDto
data
,
AnalysisContext
context
)
{
EquipInfoCylinderExcelDto
fireExperts
=
new
EquipInfoCylinderExcelDto
();
EquipInfoCylinderExcelDto
fireExperts
=
new
EquipInfoCylinderExcelDto
();
BeanUtils
.
copyProperties
(
data
,
fireExperts
);
BeanUtils
.
copyProperties
(
data
,
fireExperts
);
resultError
.
add
(
checkExcelData
(
data
,
context
).
toString
());
resultError
.
add
(
checkExcelData
(
data
,
context
).
toString
());
aircraftList
.
add
(
fireExperts
);
aircraftList
.
add
(
fireExperts
);
useInnerCodeList
.
add
(
data
.
getUseInnerCode
());
useInnerCodeList
.
add
(
data
.
getUseInnerCode
());
equCodeList
.
add
(
data
.
getEquCode
());
equCodeList
.
add
(
data
.
getEquCode
());
factoryNumList
.
add
(
"0"
.
equals
(
data
.
getWhetherVehicleCylinder
())
?
data
.
getFactoryNum
()
:
null
);
factoryNumList
.
add
(
"0"
.
equals
(
data
.
getWhetherVehicleCylinder
())
?
data
.
getFactoryNum
()
:
null
);
}
}
// 全部读取完成就调用该方法
// 全部读取完成就调用该方法
@Override
@Override
public
void
doAfterAllAnalysed
(
AnalysisContext
context
)
{
public
void
doAfterAllAnalysed
(
AnalysisContext
context
)
{
...
@@ -2503,37 +2519,37 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
...
@@ -2503,37 +2519,37 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
LinkedHashMap
attachmentUpload
=
(
LinkedHashMap
)
checkAndCast
(
paramMap
.
get
(
ATTACHMENT_UPLOAD
));
LinkedHashMap
attachmentUpload
=
(
LinkedHashMap
)
checkAndCast
(
paramMap
.
get
(
ATTACHMENT_UPLOAD
));
EquipmentInfoDto
equipInfoDto
=
this
.
createEquipmentInfoDto
(
equipmentInfoForm
,
jgVehicleInformationMapper
);
EquipmentInfoDto
equipInfoDto
=
this
.
createEquipmentInfoDto
(
equipmentInfoForm
,
jgVehicleInformationMapper
);
// 登记证记录表主键
// 登记证记录表主键
Long
changeRecordId
=
sequence
.
nextId
();
Long
changeRecordId
=
sequence
.
nextId
();
List
<
EquipInfoCylinderExcelDto
>
equipInfoCylinderExcelDtoList
=
JSON
.
parseArray
(
JSON
.
toJSONString
(
attachmentUpload
.
get
(
EQU_LISTS
)),
EquipInfoCylinderExcelDto
.
class
);
List
<
EquipInfoCylinderExcelDto
>
equipInfoCylinderExcelDtoList
=
JSON
.
parseArray
(
JSON
.
toJSONString
(
attachmentUpload
.
get
(
EQU_LISTS
)),
EquipInfoCylinderExcelDto
.
class
);
equipInfoCylinderExcelDtoList
.
forEach
(
data
->
{
equipInfoCylinderExcelDtoList
.
forEach
(
data
->
{
if
(
"his"
.
equals
(
equipInfoDto
.
getDataSource
())&&
"1"
.
equals
(
data
.
getWhetherVehicleCylinder
()))
{
if
(
"his"
.
equals
(
equipInfoDto
.
getDataSource
())
&&
"1"
.
equals
(
data
.
getWhetherVehicleCylinder
()))
{
throw
new
BadRequest
(
"车用气瓶历史设备不能批量导入!"
);
throw
new
BadRequest
(
"车用气瓶历史设备不能批量导入!"
);
}
}
String
record
=
UUID
.
randomUUID
().
toString
();
String
record
=
UUID
.
randomUUID
().
toString
();
List
<
Map
<
String
,
Object
>>
fileDataList
=
(
List
<
Map
<
String
,
Object
>>)(
data
.
getFileData
());
List
<
Map
<
String
,
Object
>>
fileDataList
=
(
List
<
Map
<
String
,
Object
>>)
(
data
.
getFileData
());
String
productPhoto
=
getUrlByKey
(
fileDataList
,
"PRODUCT_PHOTO"
);
String
productPhoto
=
getUrlByKey
(
fileDataList
,
"PRODUCT_PHOTO"
);
String
otherAccessoriesReg
=
getUrlByKey
(
fileDataList
,
"OTHER_ACCESSORIES_REG"
);
String
otherAccessoriesReg
=
getUrlByKey
(
fileDataList
,
"OTHER_ACCESSORIES_REG"
);
String
designDoc
=
getUrlByKey
(
fileDataList
,
"DESIGN_DOC"
);
String
designDoc
=
getUrlByKey
(
fileDataList
,
"DESIGN_DOC"
);
String
designStandard
=
getUrlByKey
(
fileDataList
,
"DESIGN_STANDARD"
);
String
designStandard
=
getUrlByKey
(
fileDataList
,
"DESIGN_STANDARD"
);
String
otherAccessoriesDes
=
getUrlByKey
(
fileDataList
,
"OTHER_ACCESSORIES_DES"
);
String
otherAccessoriesDes
=
getUrlByKey
(
fileDataList
,
"OTHER_ACCESSORIES_DES"
);
String
productQualityYieldProve
=
getUrlByKey
(
fileDataList
,
"PRODUCT_QUALITY_YIELD_PROVE"
);
String
productQualityYieldProve
=
getUrlByKey
(
fileDataList
,
"PRODUCT_QUALITY_YIELD_PROVE"
);
String
factoryStandard
=
getUrlByKey
(
fileDataList
,
"FACTORY_STANDARD"
);
String
factoryStandard
=
getUrlByKey
(
fileDataList
,
"FACTORY_STANDARD"
);
String
insUseMaintainExplain
=
getUrlByKey
(
fileDataList
,
"INS_USE_MAINTAIN_EXPLAIN"
);
String
insUseMaintainExplain
=
getUrlByKey
(
fileDataList
,
"INS_USE_MAINTAIN_EXPLAIN"
);
String
otherAccessoriesFact
=
getUrlByKey
(
fileDataList
,
"OTHER_ACCESSORIES_FACT"
);
String
otherAccessoriesFact
=
getUrlByKey
(
fileDataList
,
"OTHER_ACCESSORIES_FACT"
);
String
factSupervisionInspectionReport
=
getUrlByKey
(
fileDataList
,
"FACT_SUPERVISION_INSPECTION_REPORT"
);
String
factSupervisionInspectionReport
=
getUrlByKey
(
fileDataList
,
"FACT_SUPERVISION_INSPECTION_REPORT"
);
//使用信息
//使用信息
IdxBizJgUseInfo
useInfo
=
new
IdxBizJgUseInfo
();
IdxBizJgUseInfo
useInfo
=
new
IdxBizJgUseInfo
();
BeanUtils
.
copyProperties
(
data
,
useInfo
);
BeanUtils
.
copyProperties
(
data
,
useInfo
);
useInfo
.
setRecord
(
record
);
useInfo
.
setRecord
(
record
);
useInfo
.
setRecDate
(
new
Date
());
useInfo
.
setRecDate
(
new
Date
());
useInfo
.
setDataSource
(
"his"
.
equals
(
equipInfoDto
.
getDataSource
())?
"jg_his"
:
"jg"
);
//区分历史设备和新增设备
useInfo
.
setDataSource
(
"his"
.
equals
(
equipInfoDto
.
getDataSource
())
?
"jg_his"
:
"jg"
);
//区分历史设备和新增设备
useInfo
.
setEquState
(
null
);
useInfo
.
setEquState
(
null
);
useInfo
.
setIsIntoManagement
(
"his"
.
equals
(
equipInfoDto
.
getDataSource
()));
//历史气瓶导入为已纳管设备
useInfo
.
setIsIntoManagement
(
"his"
.
equals
(
equipInfoDto
.
getDataSource
()));
//历史气瓶导入为已纳管设备
// 使用单位信息
// 使用单位信息
if
(
"个人主体"
.
equals
(
company
.
getCompanyType
()))
{
if
(
"个人主体"
.
equals
(
company
.
getCompanyType
()))
{
useInfo
.
setUseUnitCreditCode
(
company
.
getCompanyCode
().
split
(
"_"
)[
1
]);
useInfo
.
setUseUnitCreditCode
(
company
.
getCompanyCode
().
split
(
"_"
)[
1
]);
useInfo
.
setUseUnitName
(
company
.
getCompanyName
().
split
(
"_"
)[
1
]);
useInfo
.
setUseUnitName
(
company
.
getCompanyName
().
split
(
"_"
)[
1
]);
}
else
{
}
else
{
useInfo
.
setUseUnitCreditCode
(
company
.
getCompanyCode
());
useInfo
.
setUseUnitCreditCode
(
company
.
getCompanyCode
());
useInfo
.
setUseUnitName
(
company
.
getCompanyName
());
useInfo
.
setUseUnitName
(
company
.
getCompanyName
());
}
}
...
@@ -2544,7 +2560,7 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
...
@@ -2544,7 +2560,7 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
BeanUtils
.
copyProperties
(
data
,
designInfo
);
BeanUtils
.
copyProperties
(
data
,
designInfo
);
designInfo
.
setRecord
(
record
);
designInfo
.
setRecord
(
record
);
designInfo
.
setRecDate
(
new
Date
());
designInfo
.
setRecDate
(
new
Date
());
if
(
data
.
getDesignDate
()
!=
null
){
if
(
data
.
getDesignDate
()
!=
null
)
{
designInfo
.
setDesignDate
(
DateUtil
.
parse
(
data
.
getDesignDate
(),
"yyyy-MM-dd"
));
designInfo
.
setDesignDate
(
DateUtil
.
parse
(
data
.
getDesignDate
(),
"yyyy-MM-dd"
));
}
}
designInfo
.
setDesignDoc
(
designDoc
);
designInfo
.
setDesignDoc
(
designDoc
);
...
@@ -2578,7 +2594,7 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
...
@@ -2578,7 +2594,7 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
registerInfo
.
setProductPhoto
(
productPhoto
);
registerInfo
.
setProductPhoto
(
productPhoto
);
registerInfo
.
setOtherAccessoriesReg
(
otherAccessoriesReg
);
registerInfo
.
setOtherAccessoriesReg
(
otherAccessoriesReg
);
registerInfo
.
setUseOrgCode
(
equipInfoDto
.
getUseOrgCode
());
registerInfo
.
setUseOrgCode
(
equipInfoDto
.
getUseOrgCode
());
if
(
"his"
.
equals
(
equipInfoDto
.
getDataSource
())){
if
(
"his"
.
equals
(
equipInfoDto
.
getDataSource
()))
{
registerInfo
.
setEquCode
(
this
.
getEquCode
(
registerInfo
,
factoryInfo
,
equipInfoDto
.
getReceiveOrgCode
()));
registerInfo
.
setEquCode
(
this
.
getEquCode
(
registerInfo
,
factoryInfo
,
equipInfoDto
.
getReceiveOrgCode
()));
}
}
registerInfoList
.
add
(
registerInfo
);
registerInfoList
.
add
(
registerInfo
);
...
@@ -2586,7 +2602,7 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
...
@@ -2586,7 +2602,7 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
//检验检测
//检验检测
IdxBizJgInspectionDetectionInfo
inspectionDetectionInfo
=
new
IdxBizJgInspectionDetectionInfo
();
IdxBizJgInspectionDetectionInfo
inspectionDetectionInfo
=
new
IdxBizJgInspectionDetectionInfo
();
BeanUtils
.
copyProperties
(
data
,
inspectionDetectionInfo
);
BeanUtils
.
copyProperties
(
data
,
inspectionDetectionInfo
);
inspectionDetectionInfo
.
setInspectOrgCode
(
data
.
getInspectOrgCode
());
inspectionDetectionInfo
.
setInspectOrgCode
(
data
.
getInspectOrgCode
());
inspectionDetectionInfo
.
setRecord
(
record
);
inspectionDetectionInfo
.
setRecord
(
record
);
inspectionDetectionInfo
.
setRecDate
(
new
Date
());
inspectionDetectionInfo
.
setRecDate
(
new
Date
());
inspectionDetectionInfo
.
setInspectType
(
"ZZJDJY"
);
inspectionDetectionInfo
.
setInspectType
(
"ZZJDJY"
);
...
@@ -2605,7 +2621,7 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
...
@@ -2605,7 +2621,7 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
BeanUtils
.
copyProperties
(
data
,
otherInfo
);
BeanUtils
.
copyProperties
(
data
,
otherInfo
);
otherInfo
.
setRecord
(
record
);
otherInfo
.
setRecord
(
record
);
otherInfo
.
setRecDate
(
new
Date
());
otherInfo
.
setRecDate
(
new
Date
());
if
(
"his"
.
equals
(
equipInfoDto
.
getDataSource
())){
if
(
"his"
.
equals
(
equipInfoDto
.
getDataSource
()))
{
otherInfo
.
setSupervisoryCode
(
this
.
getSupervisoryCode
(
equipInfoDto
.
getPossession
(),
registerInfo
));
otherInfo
.
setSupervisoryCode
(
this
.
getSupervisoryCode
(
equipInfoDto
.
getPossession
(),
registerInfo
));
otherInfo
.
setClaimStatus
(
"已认领"
);
otherInfo
.
setClaimStatus
(
"已认领"
);
}
}
...
@@ -2627,7 +2643,7 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
...
@@ -2627,7 +2643,7 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
esEquipmentDto
.
setUSE_INNER_CODE
(
useInfo
.
getUseInnerCode
());
esEquipmentDto
.
setUSE_INNER_CODE
(
useInfo
.
getUseInnerCode
());
esEquipmentDto
.
setUSE_ORG_CODE
(
equipInfoDto
.
getUseOrgCode
());
esEquipmentDto
.
setUSE_ORG_CODE
(
equipInfoDto
.
getUseOrgCode
());
esEquipmentDto
.
setIS_INTO_MANAGEMENT
(
"his"
.
equals
(
equipInfoDto
.
getDataSource
()));
esEquipmentDto
.
setIS_INTO_MANAGEMENT
(
"his"
.
equals
(
equipInfoDto
.
getDataSource
()));
if
(
"his"
.
equals
(
equipInfoDto
.
getDataSource
())){
if
(
"his"
.
equals
(
equipInfoDto
.
getDataSource
()))
{
esEquipmentDto
.
setEQU_CODE
(
registerInfo
.
getEquCode
());
esEquipmentDto
.
setEQU_CODE
(
registerInfo
.
getEquCode
());
}
}
esEquipmentDto
.
setEQU_CATEGORY_CODE
(
equipInfoDto
.
getEquCategoryCode
());
esEquipmentDto
.
setEQU_CATEGORY_CODE
(
equipInfoDto
.
getEquCategoryCode
());
...
@@ -2638,15 +2654,15 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
...
@@ -2638,15 +2654,15 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
esEquipmentDto
.
setEQU_DEFINE
(
equipInfoDto
.
getEquDefine
());
esEquipmentDto
.
setEQU_DEFINE
(
equipInfoDto
.
getEquDefine
());
// 使用单位信息
// 使用单位信息
if
(
"个人主体"
.
equals
(
company
.
getCompanyType
()))
{
if
(
"个人主体"
.
equals
(
company
.
getCompanyType
()))
{
esEquipmentDto
.
setUSE_UNIT_CREDIT_CODE
(
company
.
getCompanyCode
().
split
(
"_"
)[
1
]);
esEquipmentDto
.
setUSE_UNIT_CREDIT_CODE
(
company
.
getCompanyCode
().
split
(
"_"
)[
1
]);
esEquipmentDto
.
setUSE_UNIT_NAME
(
company
.
getCompanyName
().
split
(
"_"
)[
1
]);
esEquipmentDto
.
setUSE_UNIT_NAME
(
company
.
getCompanyName
().
split
(
"_"
)[
1
]);
}
else
{
}
else
{
esEquipmentDto
.
setUSE_UNIT_CREDIT_CODE
(
company
.
getCompanyCode
());
esEquipmentDto
.
setUSE_UNIT_CREDIT_CODE
(
company
.
getCompanyCode
());
esEquipmentDto
.
setUSE_UNIT_NAME
(
company
.
getCompanyName
());
esEquipmentDto
.
setUSE_UNIT_NAME
(
company
.
getCompanyName
());
}
}
esEquipmentCategoryList
.
add
(
esEquipmentDto
);
esEquipmentCategoryList
.
add
(
esEquipmentDto
);
if
(
"his"
.
equals
(
equipInfoDto
.
getDataSource
())){
if
(
"his"
.
equals
(
equipInfoDto
.
getDataSource
()))
{
// 生成tzs_jg_certificate_change_record_eq记录
// 生成tzs_jg_certificate_change_record_eq记录
JgCertificateChangeRecordEq
changeRecordEq
=
new
JgCertificateChangeRecordEq
();
JgCertificateChangeRecordEq
changeRecordEq
=
new
JgCertificateChangeRecordEq
();
changeRecordEq
.
setChangeRecordId
(
String
.
valueOf
(
changeRecordId
));
//登记证记录主键
changeRecordEq
.
setChangeRecordId
(
String
.
valueOf
(
changeRecordId
));
//登记证记录主键
...
@@ -2663,7 +2679,7 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
...
@@ -2663,7 +2679,7 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
Optional
.
of
(
paramsVesselList
).
filter
(
list
->
!
list
.
isEmpty
()).
ifPresent
(
idxBizJgTechParamsVesselService:
:
saveBatch
);
Optional
.
of
(
paramsVesselList
).
filter
(
list
->
!
list
.
isEmpty
()).
ifPresent
(
idxBizJgTechParamsVesselService:
:
saveBatch
);
Optional
.
of
(
inspectionDetectionInfoList
).
filter
(
list
->
!
list
.
isEmpty
()).
ifPresent
(
idxBizJgInspectionDetectionInfoService:
:
saveBatch
);
Optional
.
of
(
inspectionDetectionInfoList
).
filter
(
list
->
!
list
.
isEmpty
()).
ifPresent
(
idxBizJgInspectionDetectionInfoService:
:
saveBatch
);
Optional
.
of
(
esEquipmentCategoryList
).
filter
(
list
->
!
list
.
isEmpty
()).
ifPresent
(
esEquipmentCategory:
:
saveAll
);
Optional
.
of
(
esEquipmentCategoryList
).
filter
(
list
->
!
list
.
isEmpty
()).
ifPresent
(
esEquipmentCategory:
:
saveAll
);
if
(
"his"
.
equals
(
equipInfoDto
.
getDataSource
())){
if
(
"his"
.
equals
(
equipInfoDto
.
getDataSource
()))
{
// 生成证书管理表记录
// 生成证书管理表记录
JgUseRegistrationManage
registrationManage
=
this
.
saveRegistrationManage
(
equipInfoDto
,
company
);
JgUseRegistrationManage
registrationManage
=
this
.
saveRegistrationManage
(
equipInfoDto
,
company
);
// 生成一条tzs_jg_certificate_change_record记录
// 生成一条tzs_jg_certificate_change_record记录
...
@@ -2685,7 +2701,7 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
...
@@ -2685,7 +2701,7 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
dto
.
setEquDefine
(
jgVehicleInformationMapper
.
getEquCategoryNameByCode
(
equDefineCode
));
dto
.
setEquDefine
(
jgVehicleInformationMapper
.
getEquCategoryNameByCode
(
equDefineCode
));
dto
.
setDataSource
((
String
)
equipmentInfoForm
.
get
(
"DATA_SOURCE"
));
dto
.
setDataSource
((
String
)
equipmentInfoForm
.
get
(
"DATA_SOURCE"
));
dto
.
setUseOrgCode
((
String
)
equipmentInfoForm
.
get
(
"USE_ORG_CODE"
));
dto
.
setUseOrgCode
((
String
)
equipmentInfoForm
.
get
(
"USE_ORG_CODE"
));
if
(
"his"
.
equals
(
equipmentInfoForm
.
get
(
"DATA_SOURCE"
))){
if
(
"his"
.
equals
(
equipmentInfoForm
.
get
(
"DATA_SOURCE"
)))
{
dto
.
setReceiveOrgCode
(((
String
)
equipmentInfoForm
.
get
(
"RECEIVE_ORG_CODE"
)).
split
(
"_"
)[
0
]);
dto
.
setReceiveOrgCode
(((
String
)
equipmentInfoForm
.
get
(
"RECEIVE_ORG_CODE"
)).
split
(
"_"
)[
0
]);
dto
.
setReceiveOrgName
(((
String
)
equipmentInfoForm
.
get
(
"RECEIVE_ORG_CODE"
)).
split
(
"_"
)[
1
]);
dto
.
setReceiveOrgName
(((
String
)
equipmentInfoForm
.
get
(
"RECEIVE_ORG_CODE"
)).
split
(
"_"
)[
1
]);
}
}
...
@@ -2742,18 +2758,19 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
...
@@ -2742,18 +2758,19 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
private
String
buildRecordContent
(
JgUseRegistrationManage
registrationManage
)
{
private
String
buildRecordContent
(
JgUseRegistrationManage
registrationManage
)
{
SimpleDateFormat
simpleDateFormat
=
new
SimpleDateFormat
(
"yyyy年MM月dd日"
);
SimpleDateFormat
simpleDateFormat
=
new
SimpleDateFormat
(
"yyyy年MM月dd日"
);
return
registrationManage
.
getRecUserName
()
+
"批量上传了【"
+
BusinessTypeEnum
.
JG_HISTORY_USAGE_REGISTRATION
.
getName
()+
"】,"
+
return
registrationManage
.
getRecUserName
()
+
"批量上传了【"
+
BusinessTypeEnum
.
JG_HISTORY_USAGE_REGISTRATION
.
getName
()
+
"】,"
+
"单号【"
+
registrationManage
.
getApplyNo
()
+
"】,上传日期"
+
simpleDateFormat
.
format
(
registrationManage
.
getRecDate
());
"单号【"
+
registrationManage
.
getApplyNo
()
+
"】,上传日期"
+
simpleDateFormat
.
format
(
registrationManage
.
getRecDate
());
}
}
/**
/**
* 生成使用登记证书唯一标识
* 生成使用登记证书唯一标识
*
* @param dto 包含有 设备种类 & 设备类别 & 设备品种 的map
* @param dto 包含有 设备种类 & 设备类别 & 设备品种 的map
* @param date 生成证日期 (不传取当前时间)
* @param date 生成证日期 (不传取当前时间)
* @param receiveCompanyCode 接收机构统一信用代码
* @param receiveCompanyCode 接收机构统一信用代码
* @return 使用登记证书唯一标识
* @return 使用登记证书唯一标识
*/
*/
private
String
generateCertificateNo
(
EquipmentInfoDto
dto
,
Date
date
,
String
receiveCompanyCode
)
{
private
String
generateCertificateNo
(
EquipmentInfoDto
dto
,
Date
date
,
String
receiveCompanyCode
)
{
String
ym
=
""
;
String
ym
=
""
;
try
{
try
{
ym
=
Optional
.
of
(
DateUtils
.
dateFormat
(
date
,
DateUtils
.
DATE_PATTERN_MM
)).
orElse
(
DateUtils
.
dateFormat
(
new
Date
(),
DateUtils
.
DATE_PATTERN_MM
));
ym
=
Optional
.
of
(
DateUtils
.
dateFormat
(
date
,
DateUtils
.
DATE_PATTERN_MM
)).
orElse
(
DateUtils
.
dateFormat
(
new
Date
(),
DateUtils
.
DATE_PATTERN_MM
));
...
@@ -2766,7 +2783,7 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
...
@@ -2766,7 +2783,7 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
return
responseModel
.
getResult
();
return
responseModel
.
getResult
();
}
}
private
String
getApplicationNo
(){
private
String
getApplicationNo
()
{
ResponseModel
<
List
<
String
>>
listResponseModel
=
tzsServiceFeignClient
.
applicationFormCode
(
ApplicationFormTypeEnum
.
SYDJ
.
getCode
(),
1
);
ResponseModel
<
List
<
String
>>
listResponseModel
=
tzsServiceFeignClient
.
applicationFormCode
(
ApplicationFormTypeEnum
.
SYDJ
.
getCode
(),
1
);
if
(!
ObjectUtils
.
isEmpty
(
listResponseModel
)
&&
listResponseModel
.
getStatus
()
!=
HttpStatus
.
OK
.
value
())
{
if
(!
ObjectUtils
.
isEmpty
(
listResponseModel
)
&&
listResponseModel
.
getStatus
()
!=
HttpStatus
.
OK
.
value
())
{
log
.
error
(
"车用气瓶使用登记申请单单号获取失败!"
);
log
.
error
(
"车用气瓶使用登记申请单单号获取失败!"
);
...
@@ -2862,7 +2879,7 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
...
@@ -2862,7 +2879,7 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
}
}
}
}
private
void
checkInspectOrg
(
String
inspectOrgCode
,
StringBuilder
result
){
private
void
checkInspectOrg
(
String
inspectOrgCode
,
StringBuilder
result
)
{
List
<
Map
<
String
,
Object
>>
InspectOrgList
=
commonService
.
getAllInspectionInfo
(
"inspection"
);
List
<
Map
<
String
,
Object
>>
InspectOrgList
=
commonService
.
getAllInspectionInfo
(
"inspection"
);
if
(
findUseCode
(
InspectOrgList
,
inspectOrgCode
)
==
null
)
{
if
(
findUseCode
(
InspectOrgList
,
inspectOrgCode
)
==
null
)
{
result
.
append
(
"未查询到该检验机构;"
);
result
.
append
(
"未查询到该检验机构;"
);
...
@@ -2885,6 +2902,7 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
...
@@ -2885,6 +2902,7 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
/**
/**
* 生成设备代码
* 生成设备代码
*
* @param registerInfo registerInfo
* @param registerInfo registerInfo
* @param factoryInfo factoryInfo
* @param factoryInfo factoryInfo
* @param receiveCompanyCode 接收机构
* @param receiveCompanyCode 接收机构
...
...
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