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
5974e866
Commit
5974e866
authored
Dec 05, 2025
by
suhuiguang
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'develop_tzs_feat/xzspj' into develop_tzs_register
parents
c2df9072
c4ab4bb2
Hide whitespace changes
Inline
Side-by-side
Showing
32 changed files
with
648 additions
and
167 deletions
+648
-167
TmCylinderFillingCheckService.java
...i/openapi/face/service/TmCylinderFillingCheckService.java
+1
-1
TmCylinderFillingRecordService.java
.../openapi/face/service/TmCylinderFillingRecordService.java
+1
-1
DPFilterParamDto.java
...oin/amos/boot/module/common/api/dto/DPFilterParamDto.java
+5
-0
FeedbackSuggestionsMapper.java
...t/module/common/api/mapper/FeedbackSuggestionsMapper.java
+0
-1
FeedbackSuggestionsMapper.xml
...i/src/main/resources/mapper/FeedbackSuggestionsMapper.xml
+0
-6
FeedbackSuggestionsServiceImpl.java
...mmon/biz/service/impl/FeedbackSuggestionsServiceImpl.java
+7
-2
CompanyTypeEnum.java
...eejoin/amos/boot/module/jg/api/enums/CompanyTypeEnum.java
+3
-0
CommonMapper.java
.../yeejoin/amos/boot/module/jg/api/mapper/CommonMapper.java
+10
-0
JgUseRegistrationManageMapper.java
...t/module/jg/api/mapper/JgUseRegistrationManageMapper.java
+4
-0
CommonMapper.xml
...-module-jg-api/src/main/resources/mapper/CommonMapper.xml
+16
-0
JgUseRegistrationManageMapper.xml
...c/main/resources/mapper/JgUseRegistrationManageMapper.xml
+79
-0
CommonController.java
.../amos/boot/module/jg/biz/controller/CommonController.java
+4
-9
JgUseRegistrationManageController.java
.../jg/biz/controller/JgUseRegistrationManageController.java
+2
-2
PlatformUserTopicMessage.java
...boot/module/jg/biz/listener/PlatformUserTopicMessage.java
+2
-1
CommonServiceImpl.java
...os/boot/module/jg/biz/service/impl/CommonServiceImpl.java
+50
-38
IdxBizJgRegisterInfoServiceImpl.java
.../jg/biz/service/impl/IdxBizJgRegisterInfoServiceImpl.java
+2
-1
JgCertificateReplenishServiceImpl.java
...g/biz/service/impl/JgCertificateReplenishServiceImpl.java
+3
-0
JgChangeVehicleRegistrationUnitServiceImpl.java
...vice/impl/JgChangeVehicleRegistrationUnitServiceImpl.java
+2
-0
JgEnableDisableServiceImpl.java
...odule/jg/biz/service/impl/JgEnableDisableServiceImpl.java
+1
-0
JgUseRegistrationManageServiceImpl.java
.../biz/service/impl/JgUseRegistrationManageServiceImpl.java
+14
-0
JgUseRegistrationServiceImpl.java
...ule/jg/biz/service/impl/JgUseRegistrationServiceImpl.java
+24
-13
CodeUtil.java
...a/com/yeejoin/amos/boot/module/jg/biz/utils/CodeUtil.java
+113
-3
CommonBaseMapper.java
...s/boot/module/statistics/api/mapper/CommonBaseMapper.java
+10
-0
JGStatisticsMapper.java
...boot/module/statistics/api/mapper/JGStatisticsMapper.java
+6
-0
CommonBaseMapper.xml
...istics-api/src/main/resources/mapper/CommonBaseMapper.xml
+9
-0
JGStatisticsMapper.xml
...tics-api/src/main/resources/mapper/JGStatisticsMapper.xml
+229
-70
JGDPStatisticsServiceImpl.java
...statistcs/biz/service/impl/JGDPStatisticsServiceImpl.java
+3
-3
StCommonServiceImpl.java
...odule/statistcs/biz/service/impl/StCommonServiceImpl.java
+40
-12
TzBaseEnterpriseInfoController.java
...le/tcm/biz/controller/TzBaseEnterpriseInfoController.java
+4
-0
PlatformUserTopicMessage.java
...oot/module/tcm/biz/listener/PlatformUserTopicMessage.java
+1
-1
EquipmentCategoryServiceImpl.java
...le/tcm/biz/service/impl/EquipmentCategoryServiceImpl.java
+1
-1
TzBaseEnterpriseInfoServiceImpl.java
...tcm/biz/service/impl/TzBaseEnterpriseInfoServiceImpl.java
+2
-2
No files found.
amos-boot-data/amos-boot-data-openapi/src/main/java/com/yeejoin/amos/api/openapi/face/service/TmCylinderFillingCheckService.java
View file @
5974e866
...
@@ -57,7 +57,7 @@ public class TmCylinderFillingCheckService extends MyBaseServiceImpl<TmCylinderF
...
@@ -57,7 +57,7 @@ public class TmCylinderFillingCheckService extends MyBaseServiceImpl<TmCylinderF
entity
->
new
MultiFieldKey
(
entity
.
getAppId
(),
entity
.
getSequenceCode
(),
entity
.
getFillingBeforeId
()),
entity
->
new
MultiFieldKey
(
entity
.
getAppId
(),
entity
.
getSequenceCode
(),
entity
.
getFillingBeforeId
()),
"appId"
,
"appId"
,
"sequenceCode"
,
"sequenceCode"
,
"fillBeforeId"
);
"fill
ing
BeforeId"
);
}
}
private
void
syncCylinderFillingAfter
(
List
<
TmCylinderFillingCheckModel
>
model
)
{
private
void
syncCylinderFillingAfter
(
List
<
TmCylinderFillingCheckModel
>
model
)
{
...
...
amos-boot-data/amos-boot-data-openapi/src/main/java/com/yeejoin/amos/api/openapi/face/service/TmCylinderFillingRecordService.java
View file @
5974e866
...
@@ -66,7 +66,7 @@ public class TmCylinderFillingRecordService extends MyBaseServiceImpl<TmCylinder
...
@@ -66,7 +66,7 @@ public class TmCylinderFillingRecordService extends MyBaseServiceImpl<TmCylinder
entity
->
new
MultiFieldKey
(
entity
.
getAppId
(),
entity
.
getSequenceCode
(),
entity
.
getFillingBeforeId
()),
entity
->
new
MultiFieldKey
(
entity
.
getAppId
(),
entity
.
getSequenceCode
(),
entity
.
getFillingBeforeId
()),
"appId"
,
"appId"
,
"sequenceCode"
,
"sequenceCode"
,
"filling
Record
Id"
"filling
Before
Id"
);
);
}
}
...
...
amos-boot-system-tzs/amos-boot-module-common/amos-boot-module-common-api/src/main/java/com/yeejoin/amos/boot/module/common/api/dto/DPFilterParamDto.java
View file @
5974e866
...
@@ -103,4 +103,9 @@ public class DPFilterParamDto {
...
@@ -103,4 +103,9 @@ public class DPFilterParamDto {
* 监管机构组织机构代码
* 监管机构组织机构代码
*/
*/
private
String
superviseOrgCode
;
private
String
superviseOrgCode
;
/**
* 区域下的所有单位监管、行政审批(地市、区县级)
*/
private
List
<
String
>
companyCodes
;
}
}
amos-boot-system-tzs/amos-boot-module-common/amos-boot-module-common-api/src/main/java/com/yeejoin/amos/boot/module/common/api/mapper/FeedbackSuggestionsMapper.java
View file @
5974e866
...
@@ -10,7 +10,6 @@ import com.yeejoin.amos.boot.module.common.api.entity.FeedbackSuggestions;
...
@@ -10,7 +10,6 @@ import com.yeejoin.amos.boot.module.common.api.entity.FeedbackSuggestions;
* @date 2025-05-15
* @date 2025-05-15
*/
*/
public
interface
FeedbackSuggestionsMapper
extends
BaseMapper
<
FeedbackSuggestions
>
{
public
interface
FeedbackSuggestionsMapper
extends
BaseMapper
<
FeedbackSuggestions
>
{
String
getCompanyNameByOrgCode
(
String
orgCode
);
String
getCompanySeqByCompanyCode
(
String
companyCode
);
String
getCompanySeqByCompanyCode
(
String
companyCode
);
...
...
amos-boot-system-tzs/amos-boot-module-common/amos-boot-module-common-api/src/main/resources/mapper/FeedbackSuggestionsMapper.xml
View file @
5974e866
<?xml version="1.0" encoding="UTF-8"?>
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<!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.common.api.mapper.FeedbackSuggestionsMapper"
>
<mapper
namespace=
"com.yeejoin.amos.boot.module.common.api.mapper.FeedbackSuggestionsMapper"
>
<select
id=
"getCompanyNameByOrgCode"
resultType=
"java.lang.String"
>
select company_name
from privilege_company
where org_code = #{orgCode}
limit 1
</select>
<select
id=
"getCompanySeqByCompanyCode"
resultType=
"java.lang.String"
>
<select
id=
"getCompanySeqByCompanyCode"
resultType=
"java.lang.String"
>
SELECT sequence_nbr as sequenceNbr
SELECT sequence_nbr as sequenceNbr
FROM "amos_tzs_biz"."tz_base_enterprise_info"
FROM "amos_tzs_biz"."tz_base_enterprise_info"
...
...
amos-boot-system-tzs/amos-boot-module-common/amos-boot-module-common-biz/src/main/java/com/yeejoin/amos/boot/module/common/biz/service/impl/FeedbackSuggestionsServiceImpl.java
View file @
5974e866
...
@@ -14,7 +14,9 @@ import com.yeejoin.amos.boot.module.common.api.enums.ProblemTypeEnum;
...
@@ -14,7 +14,9 @@ import com.yeejoin.amos.boot.module.common.api.enums.ProblemTypeEnum;
import
com.yeejoin.amos.boot.module.common.api.mapper.FeedbackSuggestionsMapper
;
import
com.yeejoin.amos.boot.module.common.api.mapper.FeedbackSuggestionsMapper
;
import
com.yeejoin.amos.boot.module.common.api.service.IFeedbackSuggestionsService
;
import
com.yeejoin.amos.boot.module.common.api.service.IFeedbackSuggestionsService
;
import
com.yeejoin.amos.boot.module.common.api.vo.FeedbackSuggestionsVo
;
import
com.yeejoin.amos.boot.module.common.api.vo.FeedbackSuggestionsVo
;
import
com.yeejoin.amos.feign.privilege.Privilege
;
import
com.yeejoin.amos.feign.privilege.model.AgencyUserModel
;
import
com.yeejoin.amos.feign.privilege.model.AgencyUserModel
;
import
com.yeejoin.amos.feign.privilege.model.CompanyModel
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
org.springframework.stereotype.Service
;
import
org.typroject.tyboot.component.emq.EmqKeeper
;
import
org.typroject.tyboot.component.emq.EmqKeeper
;
...
@@ -72,8 +74,11 @@ public class FeedbackSuggestionsServiceImpl extends BaseService<FeedbackSuggesti
...
@@ -72,8 +74,11 @@ public class FeedbackSuggestionsServiceImpl extends BaseService<FeedbackSuggesti
suggestions
.
setCreateUserName
(
userModel
.
getRealName
());
suggestions
.
setCreateUserName
(
userModel
.
getRealName
());
suggestions
.
setCreateDate
(
new
Date
());
suggestions
.
setCreateDate
(
new
Date
());
suggestions
.
setIsDelete
(
Boolean
.
FALSE
);
suggestions
.
setIsDelete
(
Boolean
.
FALSE
);
suggestions
.
setSuperviseOrgCode
(
company
.
getOrgCode
());
CompanyModel
parentCompany
=
Privilege
.
companyClient
.
seleteOne
(
company
.
getParentId
()).
getResult
();
suggestions
.
setSuperviseOrgName
(
feedbackSuggestionsMapper
.
getCompanyNameByOrgCode
(
company
.
getOrgCode
()));
if
(!
ValidationUtil
.
isEmpty
(
parentCompany
))
{
suggestions
.
setSuperviseOrgCode
(
parentCompany
.
getOrgCode
());
suggestions
.
setSuperviseOrgName
(
parentCompany
.
getCompanyName
());
}
suggestions
.
setCompanyCode
(
company
.
getCompanyCode
());
suggestions
.
setCompanyCode
(
company
.
getCompanyCode
());
suggestions
.
setCompanyName
(
company
.
getCompanyName
());
suggestions
.
setCompanyName
(
company
.
getCompanyName
());
suggestions
.
setReporterUserId
(
Objects
.
toString
(
userModel
.
getUserId
()));
suggestions
.
setReporterUserId
(
Objects
.
toString
(
userModel
.
getUserId
()));
...
...
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-api/src/main/java/com/yeejoin/amos/boot/module/jg/api/enums/CompanyTypeEnum.java
View file @
5974e866
...
@@ -19,6 +19,9 @@ public enum CompanyTypeEnum {
...
@@ -19,6 +19,9 @@ public enum CompanyTypeEnum {
/**
/**
* 单位类型枚举
* 单位类型枚举
*/
*/
APPROVAL
(
"supervision"
,
"approval"
,
"行政审批局"
),
SUPERVISION
(
"supervision"
,
"supervision"
,
"监管机构"
),
SUPERVISION
(
"supervision"
,
"supervision"
,
"监管机构"
),
USE
(
"company"
,
"use"
,
"使用单位"
),
USE
(
"company"
,
"use"
,
"使用单位"
),
...
...
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-api/src/main/java/com/yeejoin/amos/boot/module/jg/api/mapper/CommonMapper.java
View file @
5974e866
...
@@ -108,6 +108,14 @@ public interface CommonMapper extends BaseMapper<EquipmentCategory> {
...
@@ -108,6 +108,14 @@ public interface CommonMapper extends BaseMapper<EquipmentCategory> {
/**
/**
* 按照 地市或者区县查询对应行政区划seq
*
* @param receiveCompanyCode 地市或者区县companyCode
* @return 地市对应行政区划seq
*/
String
selectCompanyRegionSeq
(
@Param
(
"receiveCompanyCode"
)
String
receiveCompanyCode
);
/**
* 告知业务统计
* 告知业务统计
*
*
* @param reportAnalysisSearchDTO 条件
* @param reportAnalysisSearchDTO 条件
...
@@ -380,5 +388,7 @@ public interface CommonMapper extends BaseMapper<EquipmentCategory> {
...
@@ -380,5 +388,7 @@ public interface CommonMapper extends BaseMapper<EquipmentCategory> {
List
<
Map
<
String
,
Object
>>
queryInMaintenanceRecord
();
List
<
Map
<
String
,
Object
>>
queryInMaintenanceRecord
();
List
<
Map
<
String
,
Object
>>
queryInInspectionRecord
();
List
<
Map
<
String
,
Object
>>
queryInInspectionRecord
();
List
<
String
>
querySupervisionCompanyCode
();
}
}
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-api/src/main/java/com/yeejoin/amos/boot/module/jg/api/mapper/JgUseRegistrationManageMapper.java
View file @
5974e866
...
@@ -28,6 +28,10 @@ public interface JgUseRegistrationManageMapper extends BaseMapper<JgUseRegistrat
...
@@ -28,6 +28,10 @@ public interface JgUseRegistrationManageMapper extends BaseMapper<JgUseRegistrat
@Param
(
"dto"
)
JgUseRegistrationManageDto
dto
,
@Param
(
"dto"
)
JgUseRegistrationManageDto
dto
,
@Param
(
"sort"
)
SortVo
sortMap
);
@Param
(
"sort"
)
SortVo
sortMap
);
Page
<
JgUseRegistrationManageDto
>
queryForUnitChangePage
(
@Param
(
"page"
)
Page
<
JgUseRegistrationManageDto
>
page
,
@Param
(
"dto"
)
JgUseRegistrationManageDto
dto
,
@Param
(
"sort"
)
SortVo
sortMap
);
Page
<
JgUseRegistrationManageDto
>
queryForPageForJG
(
@Param
(
"page"
)
Page
<
JgUseRegistrationManageDto
>
page
,
Page
<
JgUseRegistrationManageDto
>
queryForPageForJG
(
@Param
(
"page"
)
Page
<
JgUseRegistrationManageDto
>
page
,
@Param
(
"dto"
)
JgUseRegistrationManageDto
dto
,
@Param
(
"dto"
)
JgUseRegistrationManageDto
dto
,
@Param
(
"sort"
)
SortVo
sortMap
,
@Param
(
"orgCode"
)
String
orgCode
);
@Param
(
"sort"
)
SortVo
sortMap
,
@Param
(
"orgCode"
)
String
orgCode
);
...
...
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-api/src/main/resources/mapper/CommonMapper.xml
View file @
5974e866
...
@@ -3553,4 +3553,20 @@
...
@@ -3553,4 +3553,20 @@
AND oi."CLAIM_STATUS" not in ('草稿','已拒领','待认领')
AND oi."CLAIM_STATUS" not in ('草稿','已拒领','待认领')
AND tt."NEXT_INSPECT_DATE" is not null
AND tt."NEXT_INSPECT_DATE" is not null
</select>
</select>
<select
id=
"selectCompanyRegionSeq"
resultType=
"java.lang.String"
>
select
region_seq
from
privilege_company
where
company_code = #{receiveCompanyCode} and is_deleted = false
</select>
<select
id=
"querySupervisionCompanyCode"
resultType=
"java.lang.String"
>
select
supervision_company_code as supervisionCompanyCode
from
tz_supervision_approval_mapping
</select>
</mapper>
</mapper>
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-api/src/main/resources/mapper/JgUseRegistrationManageMapper.xml
View file @
5974e866
...
@@ -82,6 +82,85 @@
...
@@ -82,6 +82,85 @@
</select>
</select>
<select
id=
"queryForPage"
resultType=
"com.yeejoin.amos.boot.module.jg.api.dto.JgUseRegistrationManageDto"
>
<select
id=
"queryForPage"
resultType=
"com.yeejoin.amos.boot.module.jg.api.dto.JgUseRegistrationManageDto"
>
<include
refid=
"page_list"
/>
<include
refid=
"page_list"
/>
FROM tzs_jg_use_registration_manage tjurm
<where>
tjurm.is_delete = 0
<if
test=
"dto.equList != null and dto.equList != ''"
>
and tjurm.equ_list = #{dto.equList}
</if>
<if
test=
"dto.equListCode != null and dto.equListCode != ''"
>
and tjurm.equ_list_code = #{dto.equListCode}
</if>
<if
test=
"dto.equCategory != null and dto.equCategory != ''"
>
and tjurm.equ_category = #{dto.equCategory}
</if>
<if
test=
"dto.equCategoryCode != null and dto.equCategoryCode != ''"
>
and tjurm.equ_category_code = #{dto.equCategoryCode}
</if>
<if
test=
"dto.equDefine != null and dto.equDefine != ''"
>
and tjurm.equ_define = #{dto.equDefine}
</if>
<if
test=
"dto.equDefineCode != null and dto.equDefineCode != ''"
>
and tjurm.equ_define_code = #{dto.equDefineCode}
</if>
<if
test=
"dto.useRegistrationCode != null and dto.useRegistrationCode != ''"
>
and tjurm.use_registration_code like concat('%',#{dto.useRegistrationCode},'%')
</if>
<if
test=
"dto.applyNo != null and dto.applyNo != ''"
>
and tjurm.apply_no like concat('%',#{dto.applyNo},'%')
</if>
<if
test=
"dto.certificateNo != null and dto.certificateNo != ''"
>
and tjurm.certificate_no = #{dto.certificateNo}
</if>
<if
test=
"dto.auditPassDate != null and dto.auditPassDate != ''"
>
and tjurm.audit_pass_date like concat('%',DATE_FORMAT(#{dto.auditPassDate},'%Y-%m-%d'),'%')
</if>
<if
test=
"dto.certificateStatus != null and dto.certificateStatus != ''"
>
and tjurm.certificate_status = #{dto.certificateStatus}
</if>
<if
test=
"dto.useUnitCreditCodeForSearch != null and dto.useUnitCreditCodeForSearch != ''"
>
and tjurm.use_unit_credit_code = #{dto.useUnitCreditCodeForSearch}
</if>
<if
test=
"dto.useUnitCreditNameForSearch != null and dto.useUnitCreditNameForSearch != ''"
>
and tjurm.use_unit_name like concat ('%',#{dto.useUnitCreditNameForSearch},'%')
</if>
<if
test=
"dto.receiveCompanyCode != null and dto.receiveCompanyCode != ''"
>
and (tjurm.receive_company_code = #{dto.receiveCompanyCode}
or tjurm.receive_company_code is null or tjurm.receive_company_code = '')
</if>
<if
test=
"dto.dataType == 'company' "
>
AND tjurm.use_unit_credit_code = #{dto.useUnitCreditCode}
</if>
<if
test=
"dto.dataType == 'supervision' "
>
AND tjurm.receive_company_code = #{dto.receiveCompanyCode}
</if>
<if
test=
"dto.whetherVehicleCylinder != null and dto.whetherVehicleCylinder == 1 "
>
AND tjurm.reg_type = '车用气瓶登记'
</if>
<if
test=
"dto.isScrap != null and dto.isScrap != ''"
>
and tjurm.is_scrap = #{dto.isScrap}
</if>
<if
test=
"dto.isDoBusiness != null and dto.isDoBusiness != ''"
>
and tjurm.is_do_business = #{dto.isDoBusiness}
</if>
<if
test=
"dto.cityName != null and dto.cityName != ''"
>
and tjurm.equ_use_address LIKE CONCAT('%', #{dto.cityName}, '%')
</if>
<if
test=
"dto.carNumber != null and dto.carNumber != ''"
>
and tjurm.car_number LIKE CONCAT('%', #{dto.carNumber}, '%')
</if>
<if
test=
"dto.certInBusinessFlag != null and dto.certInBusinessFlag != '' and dto.certInBusinessFlag == 'false'"
>
and NOT EXISTS (
<include
refid=
"useRegCertInBusiness"
/>
)
</if>
ORDER BY
<if
test=
"sort != null"
>
tjurm.${sort.field} ${sort.sortType},
</if>
tjurm.create_date DESC
</where>
</select>
<select
id=
"queryForUnitChangePage"
resultType=
"com.yeejoin.amos.boot.module.jg.api.dto.JgUseRegistrationManageDto"
>
<include
refid=
"page_list"
/>
,estate.sequence_nbr AS estateUnitName
,estate.sequence_nbr AS estateUnitName
FROM tzs_jg_use_registration_manage tjurm
FROM tzs_jg_use_registration_manage tjurm
LEFT JOIN (
LEFT JOIN (
...
...
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-biz/src/main/java/com/yeejoin/amos/boot/module/jg/biz/controller/CommonController.java
View file @
5974e866
...
@@ -73,11 +73,6 @@ public class CommonController extends BaseController {
...
@@ -73,11 +73,6 @@ public class CommonController extends BaseController {
private
final
CodeUtil
codeUtil
;
private
final
CodeUtil
codeUtil
;
private
final
DataDictionaryServiceImpl
iDataDictionaryService
;
private
final
DataDictionaryServiceImpl
iDataDictionaryService
;
/**
* 监管机构
*/
public
static
final
String
COMPANY_TYPE_SUPERVISION_NAME
=
"监管机构"
;
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@GetMapping
(
value
=
"/currentLoginInfo"
)
@GetMapping
(
value
=
"/currentLoginInfo"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"当前登录人信息"
,
notes
=
"当前登录人信息"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"当前登录人信息"
,
notes
=
"当前登录人信息"
)
...
@@ -165,15 +160,15 @@ public class CommonController extends BaseController {
...
@@ -165,15 +160,15 @@ public class CommonController extends BaseController {
@GetMapping
(
value
=
"/getUseUnitListByCurrentLoginUser"
)
@GetMapping
(
value
=
"/getUseUnitListByCurrentLoginUser"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"根据当前登录人获取使用单位列表(用作设备列表查询)"
,
notes
=
"根据当前登录人获取使用单位列表(用作设备列表查询)"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"根据当前登录人获取使用单位列表(用作设备列表查询)"
,
notes
=
"根据当前登录人获取使用单位列表(用作设备列表查询)"
)
public
ResponseModel
<
List
<
Map
<
String
,
Object
>>>
getUseUnitListByCurrentLoginUser
()
{
public
ResponseModel
<
List
<
Map
<
String
,
Object
>>>
getUseUnitListByCurrentLoginUser
()
{
String
company
Type
=
getSelectedOrgInfo
().
getCompany
().
getCompanyType
();
String
company
Level
=
getSelectedOrgInfo
().
getCompany
().
getLevel
();
List
<
Map
<
String
,
Object
>>
result
=
new
ArrayList
<>();
List
<
Map
<
String
,
Object
>>
result
=
new
ArrayList
<>();
if
(
COMPANY_TYPE_SUPERVISION_NAME
.
equals
(
companyType
))
{
if
(
BaseController
.
COMPANY_TYPE_COMPANY
.
equals
(
companyLevel
))
{
result
=
commonService
.
getUnitListByType
(
"use"
,
null
,
false
);
}
else
{
result
.
add
(
MapBuilder
.<
String
,
Object
>
create
()
result
.
add
(
MapBuilder
.<
String
,
Object
>
create
()
.
put
(
"useCode"
,
getSelectedOrgInfo
().
getCompany
().
getCompanyCode
())
.
put
(
"useCode"
,
getSelectedOrgInfo
().
getCompany
().
getCompanyCode
())
.
put
(
"useUnit"
,
getSelectedOrgInfo
().
getCompany
().
getCompanyName
())
.
put
(
"useUnit"
,
getSelectedOrgInfo
().
getCompany
().
getCompanyName
())
.
build
());
.
build
());
}
else
{
result
=
commonService
.
getUnitListByType
(
"use"
,
null
,
false
);
}
}
return
ResponseHelper
.
buildResponse
(
result
);
return
ResponseHelper
.
buildResponse
(
result
);
}
}
...
...
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-biz/src/main/java/com/yeejoin/amos/boot/module/jg/biz/controller/JgUseRegistrationManageController.java
View file @
5974e866
...
@@ -341,7 +341,7 @@ public class JgUseRegistrationManageController extends BaseController {
...
@@ -341,7 +341,7 @@ public class JgUseRegistrationManageController extends BaseController {
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@GetMapping
(
value
=
"/unitChange/page"
)
@GetMapping
(
value
=
"/unitChange/page"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"单位变更分页查询
"
,
notes
=
"单位变更分页查询
"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"单位变更分页查询
-带产权单位"
,
notes
=
"单位变更分页查询-带产权单位
"
)
@FieldMapping
({
@FieldMapping
.
FieldMap
(
sourceField
=
"useUnitSeq"
,
targetField
=
"originalUseUnitCreditCode"
,
serviceClass
=
CommonServiceImpl
.
class
,
queryMethod
=
"queryUnitCreditInfoBySeq"
)})
@FieldMapping
({
@FieldMapping
.
FieldMap
(
sourceField
=
"useUnitSeq"
,
targetField
=
"originalUseUnitCreditCode"
,
serviceClass
=
CommonServiceImpl
.
class
,
queryMethod
=
"queryUnitCreditInfoBySeq"
)})
public
ResponseModel
<
Page
<
JgUseRegistrationManageDto
>>
queryForUnitChangePage
(
JgUseRegistrationManageDto
dto
,
public
ResponseModel
<
Page
<
JgUseRegistrationManageDto
>>
queryForUnitChangePage
(
JgUseRegistrationManageDto
dto
,
@RequestParam
(
value
=
"sort"
,
required
=
false
)
String
sort
,
@RequestParam
(
value
=
"sort"
,
required
=
false
)
String
sort
,
...
@@ -361,7 +361,7 @@ public class JgUseRegistrationManageController extends BaseController {
...
@@ -361,7 +361,7 @@ public class JgUseRegistrationManageController extends BaseController {
return
ResponseHelper
.
buildResponse
(
page
);
return
ResponseHelper
.
buildResponse
(
page
);
}
}
dto
.
setIsDoBusiness
(
"1"
);
dto
.
setIsDoBusiness
(
"1"
);
return
ResponseHelper
.
buildResponse
(
jgUseRegistrationManageServiceImpl
.
queryFor
JgUseRegistrationMana
gePage
(
page
,
dto
,
sort
));
return
ResponseHelper
.
buildResponse
(
jgUseRegistrationManageServiceImpl
.
queryFor
UnitChan
gePage
(
page
,
dto
,
sort
));
}
}
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
...
...
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-biz/src/main/java/com/yeejoin/amos/boot/module/jg/biz/listener/PlatformUserTopicMessage.java
View file @
5974e866
...
@@ -79,8 +79,9 @@ public class PlatformUserTopicMessage extends EmqxListener {
...
@@ -79,8 +79,9 @@ public class PlatformUserTopicMessage extends EmqxListener {
private
void
processDataResult
(
JSONObject
dataResultObject
)
{
private
void
processDataResult
(
JSONObject
dataResultObject
)
{
try
{
try
{
String
companyType
=
"监管机构"
;
String
companyType
=
"监管机构"
;
String
companyType2
=
"行政审批局"
;
String
companyTypeValue
=
dataResultObject
.
getString
(
"companyType"
);
String
companyTypeValue
=
dataResultObject
.
getString
(
"companyType"
);
if
(
StringUtils
.
isNotEmpty
(
companyTypeValue
)
&&
companyTypeValue
.
contains
(
companyType
))
{
if
(
StringUtils
.
isNotEmpty
(
companyTypeValue
)
&&
(
companyTypeValue
.
contains
(
companyType
)
||
companyTypeValue
.
contains
(
companyType2
)
))
{
commonService
.
creatApproveTree
();
commonService
.
creatApproveTree
();
}
}
}
catch
(
Exception
e
)
{
}
catch
(
Exception
e
)
{
...
...
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/CommonServiceImpl.java
View file @
5974e866
...
@@ -57,10 +57,7 @@ import com.yeejoin.amos.boot.module.jg.biz.feign.TzsServiceFeignClient;
...
@@ -57,10 +57,7 @@ import com.yeejoin.amos.boot.module.jg.biz.feign.TzsServiceFeignClient;
import
com.yeejoin.amos.boot.module.jg.biz.reminder.service.RemindServiceImpl
;
import
com.yeejoin.amos.boot.module.jg.biz.reminder.service.RemindServiceImpl
;
import
com.yeejoin.amos.boot.module.jg.biz.service.ICmWorkflowService
;
import
com.yeejoin.amos.boot.module.jg.biz.service.ICmWorkflowService
;
import
com.yeejoin.amos.boot.module.jg.biz.service.ICommonService
;
import
com.yeejoin.amos.boot.module.jg.biz.service.ICommonService
;
import
com.yeejoin.amos.boot.module.jg.biz.utils.FileExporter
;
import
com.yeejoin.amos.boot.module.jg.biz.utils.*
;
import
com.yeejoin.amos.boot.module.jg.biz.utils.ImageUtils
;
import
com.yeejoin.amos.boot.module.jg.biz.utils.JsonUtils
;
import
com.yeejoin.amos.boot.module.jg.biz.utils.WordTemplateUtils
;
import
com.yeejoin.amos.boot.module.ymt.api.dto.EquipmentCategoryDto
;
import
com.yeejoin.amos.boot.module.ymt.api.dto.EquipmentCategoryDto
;
import
com.yeejoin.amos.boot.module.ymt.api.entity.*
;
import
com.yeejoin.amos.boot.module.ymt.api.entity.*
;
import
com.yeejoin.amos.boot.module.ymt.api.enums.*
;
import
com.yeejoin.amos.boot.module.ymt.api.enums.*
;
...
@@ -215,6 +212,11 @@ public class CommonServiceImpl implements ICommonService {
...
@@ -215,6 +212,11 @@ public class CommonServiceImpl implements ICommonService {
private
static
final
String
UNIT
=
"unit"
;
private
static
final
String
UNIT
=
"unit"
;
private
static
final
String
SET
=
"set"
;
private
static
final
String
SET
=
"set"
;
private
static
final
String
OVER_DESIGN
=
"overDesign"
;
private
static
final
String
OVER_DESIGN
=
"overDesign"
;
private
static
final
String
COMPANY_TYPE_KEY
=
"companyType"
;
private
static
final
String
CHILDREN_KEY
=
"children"
;
private
static
final
String
COMPANY_TYPE_DELIMITER
=
"/"
;
@Autowired
@Autowired
EquipmentCategoryMapper
equipmentCategoryMapper
;
EquipmentCategoryMapper
equipmentCategoryMapper
;
@Autowired
@Autowired
...
@@ -319,6 +321,9 @@ public class CommonServiceImpl implements ICommonService {
...
@@ -319,6 +321,9 @@ public class CommonServiceImpl implements ICommonService {
@Autowired
@Autowired
private
RestHighLevelClient
restHighLevelClient
;
private
RestHighLevelClient
restHighLevelClient
;
@Autowired
CodeUtil
codeUtil
;
public
static
final
String
DATA_QUALITY_SCORE
=
"DATA_QUALITY_SCORE"
;
public
static
final
String
DATA_QUALITY_SCORE
=
"DATA_QUALITY_SCORE"
;
public
static
byte
[]
file2byte
(
File
file
)
{
public
static
byte
[]
file2byte
(
File
file
)
{
...
@@ -502,7 +507,7 @@ public class CommonServiceImpl implements ICommonService {
...
@@ -502,7 +507,7 @@ public class CommonServiceImpl implements ICommonService {
public
List
<
LinkedHashMap
>
getCreatTreeByInstallationTree
()
{
public
List
<
LinkedHashMap
>
getCreatTreeByInstallationTree
()
{
FeignClientResult
tree
=
privilegeFeginService
.
queryAgencyTreeForCache
(
RequestContext
.
getToken
(),
RequestContext
.
getAppKey
(),
RequestContext
.
getProduct
());
FeignClientResult
tree
=
privilegeFeginService
.
queryAgencyTreeForCache
(
RequestContext
.
getToken
(),
RequestContext
.
getAppKey
(),
RequestContext
.
getProduct
());
List
<
LinkedHashMap
>
result
=
(
List
<
LinkedHashMap
>)
tree
.
getResult
();
List
<
LinkedHashMap
>
result
=
(
List
<
LinkedHashMap
>)
tree
.
getResult
();
List
<
LinkedHashMap
>
treeData
=
deleteData
(
result
,
REGULATOR_UNIT
);
List
<
LinkedHashMap
>
treeData
=
deleteData
(
result
,
Collections
.
singletonList
(
REGULATOR_UNIT
)
);
List
<
LinkedHashMap
>
supervisionTree
=
treeData
.
stream
().
filter
(
e
->
code
.
equals
(
e
.
get
(
"orgCode"
))).
collect
(
Collectors
.
toList
());
List
<
LinkedHashMap
>
supervisionTree
=
treeData
.
stream
().
filter
(
e
->
code
.
equals
(
e
.
get
(
"orgCode"
))).
collect
(
Collectors
.
toList
());
List
<
LinkedHashMap
>
resultTree
=
updateNullChildren
(
supervisionTree
);
List
<
LinkedHashMap
>
resultTree
=
updateNullChildren
(
supervisionTree
);
redisUtils
.
set
(
REGULATOR_UNIT_TREE_ALL
,
resultTree
);
redisUtils
.
set
(
REGULATOR_UNIT_TREE_ALL
,
resultTree
);
...
@@ -644,7 +649,8 @@ public class CommonServiceImpl implements ICommonService {
...
@@ -644,7 +649,8 @@ public class CommonServiceImpl implements ICommonService {
// 日期设置
// 日期设置
setNextDate
(
useFlagParamDto
,
paramMap
);
setNextDate
(
useFlagParamDto
,
paramMap
);
// 登记机关调整为H列内容(原因目前公司结构无行政审批局)
// 登记机关调整为H列内容(原因目前公司结构无行政审批局)
setRegName
(
useFlagParamDto
,
paramMap
);
// 20251203行政审批局调整:直接使用单据选择的接收机构
// setRegName(useFlagParamDto, paramMap);
String
ftlPath
=
this
.
getFtlPathByBiz
(
useFlagParamDto
);
String
ftlPath
=
this
.
getFtlPathByBiz
(
useFlagParamDto
);
if
(
StringUtils
.
isEmpty
(
ftlPath
))
{
if
(
StringUtils
.
isEmpty
(
ftlPath
))
{
throw
new
BadRequest
(
"无法找到使用标志模板!"
);
throw
new
BadRequest
(
"无法找到使用标志模板!"
);
...
@@ -769,7 +775,7 @@ public class CommonServiceImpl implements ICommonService {
...
@@ -769,7 +775,7 @@ public class CommonServiceImpl implements ICommonService {
public
List
<
LinkedHashMap
>
creatTree
()
{
public
List
<
LinkedHashMap
>
creatTree
()
{
FeignClientResult
tree
=
privilegeFeginService
.
queryAgencyTreeForCache
(
RequestContext
.
getToken
(),
RequestContext
.
getAppKey
(),
RequestContext
.
getProduct
());
FeignClientResult
tree
=
privilegeFeginService
.
queryAgencyTreeForCache
(
RequestContext
.
getToken
(),
RequestContext
.
getAppKey
(),
RequestContext
.
getProduct
());
List
<
LinkedHashMap
>
result
=
(
List
<
LinkedHashMap
>)
tree
.
getResult
();
List
<
LinkedHashMap
>
result
=
(
List
<
LinkedHashMap
>)
tree
.
getResult
();
List
<
LinkedHashMap
>
treeData
=
delete
TreeData
(
result
,
REGULATOR_UNIT
);
List
<
LinkedHashMap
>
treeData
=
delete
Data
(
result
,
Lists
.
newArrayList
(
REGULATOR_UNIT
)
);
List
<
LinkedHashMap
>
supervisionTree
=
treeData
.
stream
().
filter
(
e
->
code
.
equals
(
e
.
get
(
"orgCode"
))).
collect
(
Collectors
.
toList
());
List
<
LinkedHashMap
>
supervisionTree
=
treeData
.
stream
().
filter
(
e
->
code
.
equals
(
e
.
get
(
"orgCode"
))).
collect
(
Collectors
.
toList
());
List
<
LinkedHashMap
>
resultTree
=
updateNullChildren
(
supervisionTree
);
List
<
LinkedHashMap
>
resultTree
=
updateNullChildren
(
supervisionTree
);
redisUtils
.
set
(
REGULATOR_UNIT_TREE
,
resultTree
);
redisUtils
.
set
(
REGULATOR_UNIT_TREE
,
resultTree
);
...
@@ -779,7 +785,7 @@ public class CommonServiceImpl implements ICommonService {
...
@@ -779,7 +785,7 @@ public class CommonServiceImpl implements ICommonService {
public
List
<
LinkedHashMap
>
creatlLoginUnitAndBelowGetTree
(
String
orgCode
)
{
public
List
<
LinkedHashMap
>
creatlLoginUnitAndBelowGetTree
(
String
orgCode
)
{
FeignClientResult
tree
=
privilegeFeginService
.
queryAgencyTreeForCache
(
RequestContext
.
getToken
(),
RequestContext
.
getAppKey
(),
RequestContext
.
getProduct
());
FeignClientResult
tree
=
privilegeFeginService
.
queryAgencyTreeForCache
(
RequestContext
.
getToken
(),
RequestContext
.
getAppKey
(),
RequestContext
.
getProduct
());
List
<
LinkedHashMap
>
result
=
(
List
<
LinkedHashMap
>)
tree
.
getResult
();
List
<
LinkedHashMap
>
result
=
(
List
<
LinkedHashMap
>)
tree
.
getResult
();
List
<
LinkedHashMap
>
treeData
=
delete
TreeData
(
result
,
REGULATOR_UNIT
);
List
<
LinkedHashMap
>
treeData
=
delete
Data
(
result
,
Lists
.
newArrayList
(
REGULATOR_UNIT
)
);
List
<
LinkedHashMap
>
supervisionTree
=
orgCodeAndBelowGetTree
(
treeData
,
orgCode
);
List
<
LinkedHashMap
>
supervisionTree
=
orgCodeAndBelowGetTree
(
treeData
,
orgCode
);
List
<
LinkedHashMap
>
resultTree
=
updateNullChildren
(
supervisionTree
);
List
<
LinkedHashMap
>
resultTree
=
updateNullChildren
(
supervisionTree
);
redisUtils
.
set
(
REGULATOR_UNIT_TREE
+
"_"
+
orgCode
,
resultTree
);
redisUtils
.
set
(
REGULATOR_UNIT_TREE
+
"_"
+
orgCode
,
resultTree
);
...
@@ -807,8 +813,8 @@ public class CommonServiceImpl implements ICommonService {
...
@@ -807,8 +813,8 @@ public class CommonServiceImpl implements ICommonService {
private
List
<
LinkedHashMap
>
creatReceiveUnitTree
(
String
bizType
)
{
private
List
<
LinkedHashMap
>
creatReceiveUnitTree
(
String
bizType
)
{
FeignClientResult
tree
=
privilegeFeginService
.
queryAgencyTreeForCache
(
RequestContext
.
getToken
(),
RequestContext
.
getAppKey
(),
RequestContext
.
getProduct
());
FeignClientResult
tree
=
privilegeFeginService
.
queryAgencyTreeForCache
(
RequestContext
.
getToken
(),
RequestContext
.
getAppKey
(),
RequestContext
.
getProduct
());
List
<
LinkedHashMap
>
result
=
(
List
<
LinkedHashMap
>)
tree
.
getResult
();
List
<
LinkedHashMap
>
result
=
(
List
<
LinkedHashMap
>)
tree
.
getResult
();
// 删除非监管机构的单位
// 删除非监管机构
、非审批局
的单位
deleteData
(
result
,
REGULATOR_UNIT
);
deleteData
(
result
,
Lists
.
newArrayList
(
REGULATOR_UNIT
,
ADMINISTRATION_UNIT
)
);
// 过滤符合指定业务的监管单位
// 过滤符合指定业务的监管单位
filterTreeDataByType
(
result
,
bizType
);
filterTreeDataByType
(
result
,
bizType
);
List
<
LinkedHashMap
>
supervisionTree
=
result
.
stream
().
filter
(
e
->
code
.
equals
(
e
.
get
(
"orgCode"
))).
collect
(
Collectors
.
toList
());
List
<
LinkedHashMap
>
supervisionTree
=
result
.
stream
().
filter
(
e
->
code
.
equals
(
e
.
get
(
"orgCode"
))).
collect
(
Collectors
.
toList
());
...
@@ -840,7 +846,7 @@ public class CommonServiceImpl implements ICommonService {
...
@@ -840,7 +846,7 @@ public class CommonServiceImpl implements ICommonService {
FeignClientResult
tree
=
privilegeFeginService
.
queryAgencyTreeForCache
(
RequestContext
.
getToken
(),
RequestContext
.
getAppKey
(),
RequestContext
.
getProduct
());
FeignClientResult
tree
=
privilegeFeginService
.
queryAgencyTreeForCache
(
RequestContext
.
getToken
(),
RequestContext
.
getAppKey
(),
RequestContext
.
getProduct
());
List
<
LinkedHashMap
>
result
=
(
List
<
LinkedHashMap
>)
tree
.
getResult
();
List
<
LinkedHashMap
>
result
=
(
List
<
LinkedHashMap
>)
tree
.
getResult
();
List
<
LinkedHashMap
>
children
=
(
List
<
LinkedHashMap
>)
result
.
get
(
0
).
get
(
"children"
);
List
<
LinkedHashMap
>
children
=
(
List
<
LinkedHashMap
>)
result
.
get
(
0
).
get
(
"children"
);
List
<
LinkedHashMap
>
treeData
=
delete
TreeData
(
children
,
REGULATOR_UNIT
);
List
<
LinkedHashMap
>
treeData
=
delete
Data
(
children
,
Lists
.
newArrayList
(
REGULATOR_UNIT
,
ADMINISTRATION_UNIT
)
);
List
<
LinkedHashMap
>
resultTree
=
updateNullChildren
(
treeData
);
List
<
LinkedHashMap
>
resultTree
=
updateNullChildren
(
treeData
);
redisUtils
.
set
(
ADMINISTRATION_UNIT_TREE
,
resultTree
);
redisUtils
.
set
(
ADMINISTRATION_UNIT_TREE
,
resultTree
);
return
resultTree
;
return
resultTree
;
...
@@ -887,22 +893,6 @@ public class CommonServiceImpl implements ICommonService {
...
@@ -887,22 +893,6 @@ public class CommonServiceImpl implements ICommonService {
}
}
private
List
<
LinkedHashMap
>
deleteTreeData
(
List
<
LinkedHashMap
>
result
,
String
companyType
)
{
Iterator
it
=
result
.
iterator
();
while
(
it
.
hasNext
())
{
LinkedHashMap
e
=
(
LinkedHashMap
)
it
.
next
();
// 删除非监管机构
Object
companyTypeObj
=
e
.
get
(
"companyType"
);
if
(
companyTypeObj
==
null
||
!
companyTypeObj
.
toString
().
contains
(
companyType
))
{
it
.
remove
();
}
if
(!
ObjectUtils
.
isEmpty
(
e
.
get
(
"children"
)))
{
deleteTreeData
((
List
<
LinkedHashMap
>)
e
.
get
(
"children"
),
companyType
);
}
}
return
result
;
}
private
List
<
LinkedHashMap
>
filterTreeDataByType
(
List
<
LinkedHashMap
>
result
,
String
type
)
{
private
List
<
LinkedHashMap
>
filterTreeDataByType
(
List
<
LinkedHashMap
>
result
,
String
type
)
{
Iterator
<
LinkedHashMap
>
it
=
result
.
iterator
();
Iterator
<
LinkedHashMap
>
it
=
result
.
iterator
();
while
(
it
.
hasNext
())
{
while
(
it
.
hasNext
())
{
...
@@ -918,24 +908,44 @@ public class CommonServiceImpl implements ICommonService {
...
@@ -918,24 +908,44 @@ public class CommonServiceImpl implements ICommonService {
}
}
if
(!
ObjectUtils
.
isEmpty
(
e
.
get
(
"children"
)))
{
if
(!
ObjectUtils
.
isEmpty
(
e
.
get
(
"children"
)))
{
filterTreeDataByType
((
List
<
LinkedHashMap
>)
e
.
get
(
"children"
),
type
);
filterTreeDataByType
((
List
<
LinkedHashMap
>)
e
.
get
(
"children"
),
type
);
}
}
}
}
return
result
;
return
result
;
}
}
private
List
<
LinkedHashMap
>
deleteData
(
List
<
LinkedHashMap
>
result
,
String
companyType
)
{
private
List
<
LinkedHashMap
>
deleteData
(
List
<
LinkedHashMap
>
result
,
List
<
String
>
companyTypes
)
{
Iterator
it
=
result
.
iterator
();
if
(
result
==
null
||
companyTypes
==
null
||
companyTypes
.
isEmpty
())
{
return
result
;
}
// 使用迭代器遍历并删除元素
Iterator
<
LinkedHashMap
>
it
=
result
.
iterator
();
while
(
it
.
hasNext
())
{
while
(
it
.
hasNext
())
{
LinkedHashMap
e
=
(
LinkedHashMap
)
it
.
next
();
LinkedHashMap
<
String
,
Object
>
e
=
it
.
next
();
Object
companyTypeObj
=
e
.
get
(
COMPANY_TYPE_KEY
);
Object
childrenObj
=
e
.
get
(
CHILDREN_KEY
);
// 删除非指定的单位类型
// 删除非指定的单位类型
if
(
e
.
get
(
"companyType"
)
!=
null
&&
!
e
.
get
(
"companyType"
).
toString
().
contains
(
companyType
))
{
if
(
companyTypeObj
!=
null
)
{
it
.
remove
();
String
companyType
=
companyTypeObj
.
toString
();
}
String
[]
companyTypeArray
=
companyType
.
split
(
COMPANY_TYPE_DELIMITER
);
if
(!
ObjectUtils
.
isEmpty
(
e
.
get
(
"children"
)))
{
boolean
matches
=
false
;
deleteData
((
List
<
LinkedHashMap
>)
e
.
get
(
"children"
),
companyType
);
for
(
String
type
:
companyTypeArray
)
{
}
if
(
companyTypes
.
contains
(
type
))
{
matches
=
true
;
break
;
}
}
if
(!
matches
)
{
it
.
remove
();
}
else
if
(
childrenObj
instanceof
List
)
{
@SuppressWarnings
(
"unchecked"
)
List
<
LinkedHashMap
>
children
=
(
List
<
LinkedHashMap
>)
childrenObj
;
deleteData
(
children
,
companyTypes
);
}}
}
}
return
result
;
return
result
;
}
}
...
@@ -2097,6 +2107,8 @@ public class CommonServiceImpl implements ICommonService {
...
@@ -2097,6 +2107,8 @@ public class CommonServiceImpl implements ICommonService {
// 登记机关代号,特殊区域用特殊区域如韩城-Y、杨凌-V、西咸-U
// 登记机关代号,特殊区域用特殊区域如韩城-Y、杨凌-V、西咸-U
String
city
=
""
;
String
city
=
""
;
if
(!
ValidationUtil
.
isEmpty
(
supervisoryCompanyCode
))
{
if
(!
ValidationUtil
.
isEmpty
(
supervisoryCompanyCode
))
{
// 根据接收机构动态获取接收机构对应行政区划code
supervisoryCompanyCode
=
codeUtil
.
getCityRegionCode
(
supervisoryCompanyCode
);
DataDictionary
specialRegionCode
=
dataDictionaryService
.
getByCode
(
supervisoryCompanyCode
,
SPECIAL_REGION_CODE
);
DataDictionary
specialRegionCode
=
dataDictionaryService
.
getByCode
(
supervisoryCompanyCode
,
SPECIAL_REGION_CODE
);
if
(!
ValidationUtil
.
isEmpty
(
specialRegionCode
))
{
// 特殊的区域
if
(!
ValidationUtil
.
isEmpty
(
specialRegionCode
))
{
// 特殊的区域
city
=
specialRegionCode
.
getName
();
city
=
specialRegionCode
.
getName
();
...
@@ -3049,7 +3061,7 @@ public class CommonServiceImpl implements ICommonService {
...
@@ -3049,7 +3061,7 @@ public class CommonServiceImpl implements ICommonService {
Map
<
String
,
Object
>
paramMap
=
Bean
.
BeantoMap
(
useFlagParamDto
);
Map
<
String
,
Object
>
paramMap
=
Bean
.
BeantoMap
(
useFlagParamDto
);
setNextDate
(
useFlagParamDto
,
paramMap
);
setNextDate
(
useFlagParamDto
,
paramMap
);
setRegName
(
useFlagParamDto
,
paramMap
);
//
setRegName(useFlagParamDto, paramMap);
// 生成二维码,之前为设备监管码,调整为证编号
// 生成二维码,之前为设备监管码,调整为证编号
String
qrCode
=
ImageUtils
.
generateQRCode
(
getEncodeQrCode
(
useFlagParamDto
.
getCertificateNo
(),
"useFlag"
,
useFlagParamDto
.
getVersion
()
+
""
),
100
,
100
);
String
qrCode
=
ImageUtils
.
generateQRCode
(
getEncodeQrCode
(
useFlagParamDto
.
getCertificateNo
(),
"useFlag"
,
useFlagParamDto
.
getVersion
()
+
""
),
100
,
100
);
paramMap
.
put
(
"supervisoryCode"
,
qrCode
);
paramMap
.
put
(
"supervisoryCode"
,
qrCode
);
...
...
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 @
5974e866
...
@@ -1965,7 +1965,8 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
...
@@ -1965,7 +1965,8 @@ public class IdxBizJgRegisterInfoServiceImpl extends BaseService<IdxBizJgRegiste
StringBuilder
businessBuilder
=
new
StringBuilder
(
business
);
StringBuilder
businessBuilder
=
new
StringBuilder
(
business
);
if
(!
ObjectUtils
.
isEmpty
(
useRegistrationCode
))
{
if
(!
ObjectUtils
.
isEmpty
(
useRegistrationCode
))
{
List
<
JgUseRegistrationManage
>
regs
=
jgUseRegistrationManageService
.
lambdaQuery
()
List
<
JgUseRegistrationManage
>
regs
=
jgUseRegistrationManageService
.
lambdaQuery
()
.
select
(
JgUseRegistrationManage:
:
getReceiveOrgName
,
.
select
(
JgUseRegistrationManage:
:
getSequenceNbr
,
JgUseRegistrationManage:
:
getReceiveOrgName
,
JgUseRegistrationManage:
:
getReceiveCompanyCode
)
JgUseRegistrationManage:
:
getReceiveCompanyCode
)
.
eq
(
JgUseRegistrationManage:
:
getUseRegistrationCode
,
useRegistrationCode
)
.
eq
(
JgUseRegistrationManage:
:
getUseRegistrationCode
,
useRegistrationCode
)
.
eq
(
JgUseRegistrationManage:
:
getIsDelete
,
false
)
.
eq
(
JgUseRegistrationManage:
:
getIsDelete
,
false
)
...
...
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/JgCertificateReplenishServiceImpl.java
View file @
5974e866
...
@@ -92,6 +92,7 @@ public class JgCertificateReplenishServiceImpl extends BaseService<JgCertificate
...
@@ -92,6 +92,7 @@ public class JgCertificateReplenishServiceImpl extends BaseService<JgCertificate
public
static
final
String
EQU_LISTS
=
"equLists"
;
public
static
final
String
EQU_LISTS
=
"equLists"
;
public
static
final
String
EQU_LIST_CODE
=
"equListCode"
;
public
static
final
String
EQU_LIST_CODE
=
"equListCode"
;
public
static
final
String
RECEIVE_ORG_CODE
=
"receiveOrgCode"
;
public
static
final
String
RECEIVE_ORG_CODE
=
"receiveOrgCode"
;
public
static
final
String
RECEIVE_ORG_NAME
=
"receiveOrgName"
;
public
static
final
String
APPLICATION_FORM_FILE
=
"applicationFormFile"
;
public
static
final
String
APPLICATION_FORM_FILE
=
"applicationFormFile"
;
public
static
final
String
OTHER_ACCESSORIES
=
"otherAccessories"
;
public
static
final
String
OTHER_ACCESSORIES
=
"otherAccessories"
;
public
static
final
String
SAFETY_MANAGER_ID
=
"safetyManagerId"
;
public
static
final
String
SAFETY_MANAGER_ID
=
"safetyManagerId"
;
...
@@ -963,6 +964,8 @@ public class JgCertificateReplenishServiceImpl extends BaseService<JgCertificate
...
@@ -963,6 +964,8 @@ public class JgCertificateReplenishServiceImpl extends BaseService<JgCertificate
jsonObject
.
put
(
APPLY_STATUS
,
FlowStatusEnum
.
TO_BE_FINISHED
.
getCode
());
jsonObject
.
put
(
APPLY_STATUS
,
FlowStatusEnum
.
TO_BE_FINISHED
.
getCode
());
ATTACHMENT_FIELD
.
forEach
(
item
->
jsonObject
.
put
(
item
,
JSONObject
.
parse
(
jsonObject
.
getString
(
item
))));
ATTACHMENT_FIELD
.
forEach
(
item
->
jsonObject
.
put
(
item
,
JSONObject
.
parse
(
jsonObject
.
getString
(
item
))));
jsonObject
.
put
(
APPLICATION_FORM_FILE_URL
,
certRep
.
getApplicationFormFileUrl
());
jsonObject
.
put
(
APPLICATION_FORM_FILE_URL
,
certRep
.
getApplicationFormFileUrl
());
jsonObject
.
put
(
RECEIVE_ORG_CODE
,
certRep
.
getReceiveOrgCode
());
jsonObject
.
put
(
RECEIVE_ORG_NAME
,
certRep
.
getReceiveOrgName
());
return
jsonObject
;
return
jsonObject
;
}
else
{
}
else
{
ObjectMapper
mapper
=
new
ObjectMapper
();
ObjectMapper
mapper
=
new
ObjectMapper
();
...
...
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/JgChangeVehicleRegistrationUnitServiceImpl.java
View file @
5974e866
...
@@ -978,6 +978,8 @@ public class JgChangeVehicleRegistrationUnitServiceImpl extends BaseService<JgCh
...
@@ -978,6 +978,8 @@ public class JgChangeVehicleRegistrationUnitServiceImpl extends BaseService<JgCh
// todo 注意顺序3
// todo 注意顺序3
object
.
put
(
"companyType2"
,
CommonServiceImpl
.
getCompanyType
(
selectedOrgInfo
.
getCompany
()));
object
.
put
(
"companyType2"
,
CommonServiceImpl
.
getCompanyType
(
selectedOrgInfo
.
getCompany
()));
object
.
put
(
"havingPermission"
,
registrationUnit
.
getNextExecuteUserIds
()
!=
null
&&
registrationUnit
.
getNextExecuteUserIds
().
contains
(
RequestContext
.
getExeUserId
()));
object
.
put
(
"havingPermission"
,
registrationUnit
.
getNextExecuteUserIds
()
!=
null
&&
registrationUnit
.
getNextExecuteUserIds
().
contains
(
RequestContext
.
getExeUserId
()));
object
.
put
(
"receiveCompanyCode"
,
registrationUnit
.
getReceiveCompanyCode
()
+
"_"
+
registrationUnit
.
getReceiveOrgName
());
object
.
put
(
"receiveOrgCode"
,
registrationUnit
.
getReceiveOrgCode
()
+
"_"
+
registrationUnit
.
getReceiveOrgName
());
return
object
;
return
object
;
}
else
{
}
else
{
return
new
HashMap
<>();
return
new
HashMap
<>();
...
...
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/JgEnableDisableServiceImpl.java
View file @
5974e866
...
@@ -837,6 +837,7 @@ public class JgEnableDisableServiceImpl extends BaseService<JgEnableDisableDto,
...
@@ -837,6 +837,7 @@ public class JgEnableDisableServiceImpl extends BaseService<JgEnableDisableDto,
resultMap
.
putAll
(
jsonObject
);
resultMap
.
putAll
(
jsonObject
);
}
}
resultMap
.
put
(
"receiveOrgCode"
,
enableDisable
.
getReceiveCompanyCode
()
+
'_'
+
enableDisable
.
getReceiveOrgName
());
resultMap
.
put
(
"receiveOrgCode"
,
enableDisable
.
getReceiveCompanyCode
()
+
'_'
+
enableDisable
.
getReceiveOrgName
());
resultMap
.
put
(
"receiveCompanyCode"
,
enableDisable
.
getReceiveCompanyCode
());
resultMap
.
put
(
"sequenceNbr"
,
enableDisable
.
getSequenceNbr
());
resultMap
.
put
(
"sequenceNbr"
,
enableDisable
.
getSequenceNbr
());
resultMap
.
put
(
"applyNo"
,
enableDisable
.
getApplyNo
());
resultMap
.
put
(
"applyNo"
,
enableDisable
.
getApplyNo
());
resultMap
.
put
(
"auditStatus"
,
enableDisable
.
getAuditStatus
());
resultMap
.
put
(
"auditStatus"
,
enableDisable
.
getAuditStatus
());
...
...
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/JgUseRegistrationManageServiceImpl.java
View file @
5974e866
...
@@ -335,6 +335,20 @@ public class JgUseRegistrationManageServiceImpl extends BaseService<JgUseRegistr
...
@@ -335,6 +335,20 @@ public class JgUseRegistrationManageServiceImpl extends BaseService<JgUseRegistr
}
}
/**
/**
* 单位变更证-查询
*/
public
Page
<
JgUseRegistrationManageDto
>
queryForUnitChangePage
(
Page
<
JgUseRegistrationManageDto
>
page
,
JgUseRegistrationManageDto
dto
,
String
sort
)
{
SortVo
sortMap
=
commonServiceImpl
.
sortFieldConversion
(
sort
);
if
(
ApplicationFormTypeEnum
.
BF
.
getBusinessCode
().
equals
(
dto
.
getApplyType
())
&&
(!
CylinderTypeEnum
.
CYLINDER
.
getCode
().
equals
(
dto
.
getEquCategoryCode
())
||
dto
.
getRegType
().
equals
(
BusinessTypeEnum
.
JG_VEHICLE_GAS_APPLICATION
.
getName
()))){
dto
.
setCertificateStatus
(
null
);
dto
.
setIsScrap
(
"0"
);
}
return
jgUseRegistrationManageMapper
.
queryForUnitChangePage
(
page
,
dto
,
sortMap
);
}
/**
* 分页查询证管理表-选择证使用,添加产权单位id
* 分页查询证管理表-选择证使用,添加产权单位id
*/
*/
public
Page
<
JgUseRegistrationManageDto
>
queryUseRegistrationManagePage
(
Page
<
JgUseRegistrationManageDto
>
page
,
public
Page
<
JgUseRegistrationManageDto
>
queryUseRegistrationManagePage
(
Page
<
JgUseRegistrationManageDto
>
page
,
...
...
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/JgUseRegistrationServiceImpl.java
View file @
5974e866
...
@@ -161,6 +161,7 @@ public class JgUseRegistrationServiceImpl extends BaseService<JgUseRegistrationD
...
@@ -161,6 +161,7 @@ public class JgUseRegistrationServiceImpl extends BaseService<JgUseRegistrationD
private
static
final
String
DEFINITION_KEY
=
"useRegistration"
;
private
static
final
String
DEFINITION_KEY
=
"useRegistration"
;
private
static
final
String
JIAN_CHA_ROLE_ID
=
"1864242478501093377"
;
private
static
final
String
JIAN_CHA_ROLE_ID
=
"1864242478501093377"
;
private
static
final
int
ONCE_MAX_SUBMIT
=
5000
;
private
static
final
DateTimeFormatter
formatter
=
DateTimeFormatter
.
ofPattern
(
"yyyy-MM-dd"
);;
private
static
final
DateTimeFormatter
formatter
=
DateTimeFormatter
.
ofPattern
(
"yyyy-MM-dd"
);;
private
static
final
int
BATCH_SIZE
=
1000
;
private
static
final
int
BATCH_SIZE
=
1000
;
private
final
List
<
String
>
NOT_FLOWING_STATE
=
Arrays
.
asList
(
"使用单位待提交"
,
"一级受理已驳回"
,
"使用单位已撤回"
,
"已作废"
);
private
final
List
<
String
>
NOT_FLOWING_STATE
=
Arrays
.
asList
(
"使用单位待提交"
,
"一级受理已驳回"
,
"使用单位已撤回"
,
"已作废"
);
...
@@ -940,6 +941,9 @@ public class JgUseRegistrationServiceImpl extends BaseService<JgUseRegistrationD
...
@@ -940,6 +941,9 @@ public class JgUseRegistrationServiceImpl extends BaseService<JgUseRegistrationD
if
(!
ObjectUtils
.
isEmpty
(
map
.
get
(
"submit"
))
&&
hasExistingCertificate
&&
map
.
get
(
"isAddEquip"
).
equals
(
"0"
))
{
if
(!
ObjectUtils
.
isEmpty
(
map
.
get
(
"submit"
))
&&
hasExistingCertificate
&&
map
.
get
(
"isAddEquip"
).
equals
(
"0"
))
{
throw
new
BadRequest
(
"该企业已存在气瓶证书,请选择增补功能进行登记!"
);
throw
new
BadRequest
(
"该企业已存在气瓶证书,请选择增补功能进行登记!"
);
}
}
if
(
equipmentLists
.
size
()
>
ONCE_MAX_SUBMIT
)
{
throw
new
BadRequest
(
"单次提交最多允许 "
+
ONCE_MAX_SUBMIT
+
" 条数据,请分批提交!"
);
}
}
}
// 压力管道逻辑(如果是合并到已有证的工程装置,需要去除已完成设备)
// 压力管道逻辑(如果是合并到已有证的工程装置,需要去除已完成设备)
...
@@ -2490,6 +2494,7 @@ public class JgUseRegistrationServiceImpl extends BaseService<JgUseRegistrationD
...
@@ -2490,6 +2494,7 @@ public class JgUseRegistrationServiceImpl extends BaseService<JgUseRegistrationD
jsonObject
.
put
(
"manageType"
,
jgUseRegistration
.
getManageType
());
jsonObject
.
put
(
"manageType"
,
jgUseRegistration
.
getManageType
());
jsonObject
.
put
(
"createUserId"
,
jgUseRegistration
.
getCreateUserId
());
jsonObject
.
put
(
"createUserId"
,
jgUseRegistration
.
getCreateUserId
());
jsonObject
.
put
(
"receiveOrgCode"
,
jgUseRegistration
.
getReceiveCompanyCode
()
+
"_"
+
jgUseRegistration
.
getReceiveOrgName
());
jsonObject
.
put
(
"receiveOrgCode"
,
jgUseRegistration
.
getReceiveCompanyCode
()
+
"_"
+
jgUseRegistration
.
getReceiveOrgName
());
jsonObject
.
put
(
"receiveCompanyCode"
,
jgUseRegistration
.
getReceiveCompanyCode
()
+
"_"
+
jgUseRegistration
.
getReceiveOrgName
());
jsonObject
.
put
(
"status"
,
jgUseRegistration
.
getStatus
());
jsonObject
.
put
(
"status"
,
jgUseRegistration
.
getStatus
());
jsonObject
.
put
(
"applyNo"
,
jgUseRegistration
.
getApplyNo
());
jsonObject
.
put
(
"applyNo"
,
jgUseRegistration
.
getApplyNo
());
jsonObject
.
put
(
"installLeaderName"
,
jsonObject
.
getString
(
"installLeaderId"
));
jsonObject
.
put
(
"installLeaderName"
,
jsonObject
.
getString
(
"installLeaderId"
));
...
@@ -3271,9 +3276,10 @@ public class JgUseRegistrationServiceImpl extends BaseService<JgUseRegistrationD
...
@@ -3271,9 +3276,10 @@ public class JgUseRegistrationServiceImpl extends BaseService<JgUseRegistrationD
*/
*/
void
fillHistoryDataWithNewEquip
(
JSONObject
jsonObject
,
JgUseRegistration
jgUseRegistration
,
String
record
)
{
void
fillHistoryDataWithNewEquip
(
JSONObject
jsonObject
,
JgUseRegistration
jgUseRegistration
,
String
record
)
{
// 非已完成、非作废时显示设备最新信息。前置需求:一个设备只能同时发起一个流程
// 非已完成、非作废时显示设备最新信息。前置需求:一个设备只能同时发起一个流程
// 流程中的新设备处理逻辑(历史有证已完成不执行、历史黑设备在使用登记编辑维保、安装信息,所以详情从json取)
if
(!(
FlowStatusEnum
.
TO_BE_FINISHED
.
getName
().
equals
(
jgUseRegistration
.
getStatus
())
if
(!(
FlowStatusEnum
.
TO_BE_FINISHED
.
getName
().
equals
(
jgUseRegistration
.
getStatus
())
||
FlowStatusEnum
.
TO_BE_DISCARD
.
getName
().
equals
(
jgUseRegistration
.
getStatus
()))
||
FlowStatusEnum
.
TO_BE_DISCARD
.
getName
().
equals
(
jgUseRegistration
.
getStatus
()))
||
"1
"
.
equals
(
jgUseRegistration
.
getRegType
()))
{
&&
!
"2
"
.
equals
(
jgUseRegistration
.
getRegType
()))
{
fillLastEquipDetail
(
jsonObject
,
record
);
fillLastEquipDetail
(
jsonObject
,
record
);
}
}
}
}
...
@@ -3282,16 +3288,16 @@ public class JgUseRegistrationServiceImpl extends BaseService<JgUseRegistrationD
...
@@ -3282,16 +3288,16 @@ public class JgUseRegistrationServiceImpl extends BaseService<JgUseRegistrationD
// 基本信息 + 制造信息 + 设计信息
// 基本信息 + 制造信息 + 设计信息
fillLastEquipBaseInfo
(
jsonObject
,
record
);
fillLastEquipBaseInfo
(
jsonObject
,
record
);
// 安装信息
// 安装信息
if
(!
jsonObject
.
containsKey
(
"installationIsComplete"
))
{
Map
<
String
,
Object
>
installDetail
=
this
.
baseMapper
.
getInstallDetail
(
record
);
Map
<
String
,
Object
>
installDetail
=
this
.
baseMapper
.
getInstallDetail
(
record
);
// 历史设备登记来的数据没有安装业务信息 从一码通数据拿
// 历史设备登记来的数据没有安装业务信息 从一码通数据拿
if
(
ValidationUtil
.
isEmpty
(
installDetail
))
{
if
(
ValidationUtil
.
isEmpty
(
installDetail
))
{
installDetail
=
this
.
baseMapper
.
getiInstallDetailByIdx
(
record
);
installDetail
=
this
.
baseMapper
.
getiInstallDetailByIdx
(
record
);
}
if
(!
ObjectUtils
.
isEmpty
(
installDetail
))
{
jsonObject
.
putAll
(
installDetail
);
}
}
}
if
(!
ObjectUtils
.
isEmpty
(
installDetail
))
{
jsonObject
.
putAll
(
installDetail
);
}
// 维保信息
// 维保信息
Map
<
String
,
Object
>
maintenanceDetail
=
this
.
baseMapper
.
getMaintenanceDetail
(
record
);
Map
<
String
,
Object
>
maintenanceDetail
=
this
.
baseMapper
.
getMaintenanceDetail
(
record
);
// 历史设备登记来的数据没有维保业务信息 从一码通数据拿
// 历史设备登记来的数据没有维保业务信息 从一码通数据拿
...
@@ -4499,9 +4505,14 @@ public class JgUseRegistrationServiceImpl extends BaseService<JgUseRegistrationD
...
@@ -4499,9 +4505,14 @@ public class JgUseRegistrationServiceImpl extends BaseService<JgUseRegistrationD
useInfo
.
setStreetName
(
useStreetName
);
useInfo
.
setStreetName
(
useStreetName
);
useInfo
.
setAddress
(
String
.
valueOf
(
map
.
get
(
"address"
)));
useInfo
.
setAddress
(
String
.
valueOf
(
map
.
get
(
"address"
)));
useInfo
.
setIsNotXiXian
(
String
.
valueOf
(
map
.
get
(
"isXixian"
)));
useInfo
.
setIsNotXiXian
(
String
.
valueOf
(
map
.
get
(
"isXixian"
)));
Map
<
String
,
String
>
propertyUnitInfo
=
commonServiceImpl
.
queryTcmUnitInfoBySeq
(
MapUtil
.
getStr
(
map
,
"estateUnitName"
),
TcmUnitTypeEnum
.
CQ
.
getCode
());
if
(!
ValidationUtil
.
isEmpty
(
MapUtil
.
getStr
(
map
,
"estateUnitName"
))
&&
MapUtil
.
getStr
(
map
,
"estateUnitName"
).
split
(
"_"
).
length
==
2
)
{
useInfo
.
setEstateUnitCreditCode
(
MapUtil
.
getStr
(
propertyUnitInfo
,
"unitCode"
));
useInfo
.
setEstateUnitCreditCode
(
MapUtil
.
getStr
(
map
,
"estateUnitName"
).
split
(
"_"
)[
0
]);
useInfo
.
setEstateUnitName
(
MapUtil
.
getStr
(
propertyUnitInfo
,
"unitName"
));
useInfo
.
setEstateUnitName
(
MapUtil
.
getStr
(
map
,
"estateUnitName"
).
split
(
"_"
)[
1
]);
}
else
{
Map
<
String
,
String
>
propertyUnitInfo
=
commonServiceImpl
.
queryTcmUnitInfoBySeq
(
MapUtil
.
getStr
(
map
,
"estateUnitName"
),
TcmUnitTypeEnum
.
CQ
.
getCode
());
useInfo
.
setEstateUnitCreditCode
(
MapUtil
.
getStr
(
propertyUnitInfo
,
"unitCode"
));
useInfo
.
setEstateUnitName
(
MapUtil
.
getStr
(
propertyUnitInfo
,
"unitName"
));
}
useInfo
.
setPhone
(
String
.
valueOf
(
map
.
get
(
"phone"
)));
useInfo
.
setPhone
(
String
.
valueOf
(
map
.
get
(
"phone"
)));
useInfo
.
setSafetyManager
(
map
.
getString
(
"safetyManagerName"
));
useInfo
.
setSafetyManager
(
map
.
getString
(
"safetyManagerName"
));
useInfo
.
setSafetyManagerId
(
map
.
getString
(
"safetyManagerId"
));
useInfo
.
setSafetyManagerId
(
map
.
getString
(
"safetyManagerId"
));
...
...
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-biz/src/main/java/com/yeejoin/amos/boot/module/jg/biz/utils/CodeUtil.java
View file @
5974e866
package
com
.
yeejoin
.
amos
.
boot
.
module
.
jg
.
biz
.
utils
;
package
com
.
yeejoin
.
amos
.
boot
.
module
.
jg
.
biz
.
utils
;
import
com.yeejoin.amos.boot.biz.common.utils.RedisUtils
;
import
com.yeejoin.amos.boot.module.jg.api.dto.CodeGenerateDto
;
import
com.yeejoin.amos.boot.module.jg.api.dto.CodeGenerateDto
;
import
com.yeejoin.amos.boot.module.jg.api.mapper.CommonMapper
;
import
com.yeejoin.amos.boot.module.jg.api.mapper.CommonMapper
;
import
com.yeejoin.amos.feign.systemctl.Systemctl
;
import
com.yeejoin.amos.feign.systemctl.model.RegionModel
;
import
lombok.extern.slf4j.Slf4j
;
import
org.redisson.api.RBucket
;
import
org.redisson.api.RBucket
;
import
org.redisson.api.RLock
;
import
org.redisson.api.RLock
;
import
org.redisson.api.RedissonClient
;
import
org.redisson.api.RedissonClient
;
import
org.springframework.stereotype.Component
;
import
org.springframework.stereotype.Component
;
import
org.typroject.tyboot.core.foundation.utils.ValidationUtil
;
import
java.util.Arrays
;
import
java.util.*
;
import
java.util.concurrent.ConcurrentHashMap
;
/**
/**
* @author Administrator
* @author Administrator
*/
*/
@Component
@Component
@Slf4j
public
class
CodeUtil
{
public
class
CodeUtil
{
...
@@ -25,10 +32,16 @@ public class CodeUtil {
...
@@ -25,10 +32,16 @@ public class CodeUtil {
*/
*/
private
static
String
[]
EXCLUSION_CITY_REGIONS
=
{
"610403"
,
"610581"
};
private
static
String
[]
EXCLUSION_CITY_REGIONS
=
{
"610403"
,
"610581"
};
private
final
RedisUtils
redisUtils
;
public
CodeUtil
(
RedissonClient
redissonClient
,
CommonMapper
commonMapper
)
{
private
final
Map
<
String
,
String
>
REGIONSEQ_CODE_MAP
=
new
ConcurrentHashMap
<>();
private
static
final
String
REGION_SEQ_MAP_KEY
=
"region:seq_map"
;
public
CodeUtil
(
RedissonClient
redissonClient
,
CommonMapper
commonMapper
,
RedisUtils
redisUtils
)
{
this
.
redissonClient
=
redissonClient
;
this
.
redissonClient
=
redissonClient
;
this
.
commonMapper
=
commonMapper
;
this
.
commonMapper
=
commonMapper
;
this
.
redisUtils
=
redisUtils
;
}
}
...
@@ -88,7 +101,104 @@ public class CodeUtil {
...
@@ -88,7 +101,104 @@ public class CodeUtil {
if
(
Arrays
.
asList
(
EXCLUSION_CITY_REGIONS
).
contains
(
receiveCompanyCode
))
{
if
(
Arrays
.
asList
(
EXCLUSION_CITY_REGIONS
).
contains
(
receiveCompanyCode
))
{
return
receiveCompanyCode
;
return
receiveCompanyCode
;
}
else
{
}
else
{
return
commonMapper
.
selectCityCompanyCode
(
receiveCompanyCode
,
EXCLUSION_CITY_REGIONS
);
if
(!
ValidationUtil
.
isEmpty
(
receiveCompanyCode
))
{
String
regionSeq
=
commonMapper
.
selectCompanyRegionSeq
(
receiveCompanyCode
);
return
this
.
getRegionCodeByRegionSeq
(
regionSeq
);
// return commonMapper.selectCityCompanyCode(this.getRegionCodeByRegionSeq(regionSeq), EXCLUSION_CITY_REGIONS);
}
return
null
;
}
}
public
String
getRegionCodeByRegionSeq
(
String
regionSeq
)
{
return
REGIONSEQ_CODE_MAP
.
computeIfAbsent
(
regionSeq
,
(
k
)
->
getRegionCodeFromRedisOrRemote
(
regionSeq
));
}
/**
* 从 Redis 或远程接口获取 regionCode
*/
private
String
getRegionCodeFromRedisOrRemote
(
String
regionSeq
)
{
// 1. 先从 Redis 获取整个 seqToCodeMap
Map
<
String
,
RegionModel
>
seqToCodeMap
=
getRegionSeqToCodeMapFromRedis
();
// 2. 如果在 Redis Map 中找到,直接返回
RegionModel
regionModel
=
seqToCodeMap
.
get
(
regionSeq
);
if
(!
ValidationUtil
.
isEmpty
(
regionModel
))
{
return
regionModel
.
getRegionCode
().
toString
();
}
// 3. Redis 中没有,调用远程接口获取最新数据
return
getRegionCodeFromRemoteAndRefreshCache
(
regionSeq
);
}
/**
* 从 Redis 获取 seqToCodeMap
*/
@SuppressWarnings
(
"unchecked"
)
private
Map
<
String
,
RegionModel
>
getRegionSeqToCodeMapFromRedis
()
{
try
{
Object
cachedMap
=
redisUtils
.
get
(
REGION_SEQ_MAP_KEY
);
if
(
cachedMap
instanceof
Map
)
{
return
(
Map
<
String
,
RegionModel
>)
cachedMap
;
}
}
catch
(
Exception
e
)
{
log
.
warn
(
"从 Redis 获取 seqToCodeMap 失败,将重新加载"
,
e
);
}
return
new
HashMap
<>();
}
/**
* 调用远程接口获取数据,并刷新 Redis 缓存
*/
private
String
getRegionCodeFromRemoteAndRefreshCache
(
String
regionSeq
)
{
// 1. 调用远程接口获取完整的树结构数据
Collection
<
RegionModel
>
regionTree
=
Systemctl
.
regionClient
.
queryForTreeByAgencyCodeRightLike
(
null
).
getResult
();
// 2. 将树结构转换为 seqToCodeMap
Map
<
String
,
RegionModel
>
seqToCodeMap
=
convertRegionTreeToMap
(
regionTree
);
// 3. 将转换后的 Map 写入 Redis
try
{
redisUtils
.
set
(
REGION_SEQ_MAP_KEY
,
seqToCodeMap
);
log
.
info
(
"已更新 Redis 中的 region seqToCodeMap,包含 {} 条记录"
,
seqToCodeMap
.
size
());
}
catch
(
Exception
e
)
{
log
.
error
(
"更新 Redis seqToCodeMap 失败"
,
e
);
}
// 4. 从新生成的 Map 中查找需要的值
return
Optional
.
ofNullable
(
seqToCodeMap
.
get
(
regionSeq
)).
map
(
RegionModel:
:
getRegionCode
).
map
(
String:
:
valueOf
).
orElse
(
null
);
}
/**
* 将 RegionModel 树结构转换为 Map<sequenceNbr, regionCode>
*/
private
Map
<
String
,
RegionModel
>
convertRegionTreeToMap
(
Collection
<
RegionModel
>
regionTree
)
{
Map
<
String
,
RegionModel
>
seqToCodeMap
=
new
HashMap
<>();
for
(
RegionModel
region
:
regionTree
)
{
traverseAndAddToMap
(
region
,
seqToCodeMap
);
}
return
seqToCodeMap
;
}
/**
* 递归遍历 RegionModel 树,将每个节点的 sequenceNbr 和 regionCode 存入 Map
*/
private
void
traverseAndAddToMap
(
RegionModel
region
,
Map
<
String
,
RegionModel
>
seqToCodeMap
)
{
if
(
region
==
null
)
{
return
;
}
// 将当前节点存入 Map
if
(
region
.
getSequenceNbr
()
!=
null
&&
region
.
getRegionCode
()
!=
null
)
{
seqToCodeMap
.
put
(
String
.
valueOf
(
region
.
getSequenceNbr
()),
region
);
}
// 递归处理子节点
Collection
<
RegionModel
>
children
=
region
.
getChildren
();
if
(
children
!=
null
&&
!
children
.
isEmpty
())
{
for
(
RegionModel
child
:
children
)
{
traverseAndAddToMap
(
child
,
seqToCodeMap
);
}
}
}
}
}
...
...
amos-boot-system-tzs/amos-boot-module-statistics/amos-boot-module-statistics-api/src/main/java/com/yeejoin/amos/boot/module/statistics/api/mapper/CommonBaseMapper.java
View file @
5974e866
package
com
.
yeejoin
.
amos
.
boot
.
module
.
statistics
.
api
.
mapper
;
package
com
.
yeejoin
.
amos
.
boot
.
module
.
statistics
.
api
.
mapper
;
import
org.apache.ibatis.annotations.Mapper
;
import
org.apache.ibatis.annotations.Mapper
;
import
org.apache.ibatis.annotations.Param
;
/**
/**
* Mapper 接口
* Mapper 接口
...
@@ -14,4 +15,13 @@ public interface CommonBaseMapper {
...
@@ -14,4 +15,13 @@ public interface CommonBaseMapper {
String
getOrgCodeByCompanyCode
(
String
companyCode
);
String
getOrgCodeByCompanyCode
(
String
companyCode
);
String
getCompanyCodeByOrgCode
(
String
orgCode
);
String
getCompanyCodeByOrgCode
(
String
orgCode
);
/**
* 按照 地市或者区县查询对应行政区划seq
*
* @param receiveCompanyCode 地市或者区县companyCode
* @return 地市对应行政区划seq
*/
String
selectCompanyRegionSeq
(
@Param
(
"receiveCompanyCode"
)
String
receiveCompanyCode
);
}
}
amos-boot-system-tzs/amos-boot-module-statistics/amos-boot-module-statistics-api/src/main/java/com/yeejoin/amos/boot/module/statistics/api/mapper/JGStatisticsMapper.java
View file @
5974e866
...
@@ -72,6 +72,12 @@ public interface JGStatisticsMapper {
...
@@ -72,6 +72,12 @@ public interface JGStatisticsMapper {
List
<
Map
<
String
,
Object
>>
selectNoticeCountTopTen
(
@Param
(
"orgCode"
)
String
orgCode
,
@Param
(
"time"
)
String
time
);
List
<
Map
<
String
,
Object
>>
selectNoticeCountTopTen
(
@Param
(
"orgCode"
)
String
orgCode
,
@Param
(
"time"
)
String
time
);
/**
* 告知类业务平均办理时效,统计维度:接收机构所在的行政区域;
* @param dpFilterParamDto 过滤条件
* @param orgCode 登录人或者选择区域转换后的orgCode
* @return 告知类业务平均办理时效
*/
List
<
CountDto
>
queryNoticeAvgDayByReceiveCompany
(
@Param
(
"dto"
)
DPFilterParamDto
dpFilterParamDto
,
@Param
(
"orgCode"
)
String
orgCode
);
List
<
CountDto
>
queryNoticeAvgDayByReceiveCompany
(
@Param
(
"dto"
)
DPFilterParamDto
dpFilterParamDto
,
@Param
(
"orgCode"
)
String
orgCode
);
List
<
CountDto
>
queryUseAvgDayByReceiveCompany
(
@Param
(
"dto"
)
DPFilterParamDto
dpFilterParamDto
,
@Param
(
"orgCode"
)
String
orgCode
);
List
<
CountDto
>
queryUseAvgDayByReceiveCompany
(
@Param
(
"dto"
)
DPFilterParamDto
dpFilterParamDto
,
@Param
(
"orgCode"
)
String
orgCode
);
...
...
amos-boot-system-tzs/amos-boot-module-statistics/amos-boot-module-statistics-api/src/main/resources/mapper/CommonBaseMapper.xml
View file @
5974e866
...
@@ -9,4 +9,13 @@
...
@@ -9,4 +9,13 @@
<select
id=
"getCompanyCodeByOrgCode"
resultType=
"java.lang.String"
>
<select
id=
"getCompanyCodeByOrgCode"
resultType=
"java.lang.String"
>
select company_code from privilege_company where org_code = #{orgCode} limit 1
select company_code from privilege_company where org_code = #{orgCode} limit 1
</select>
</select>
<select
id=
"selectCompanyRegionSeq"
resultType=
"java.lang.String"
>
select
region_seq
from
privilege_company
where
company_code = #{receiveCompanyCode} and is_deleted = false
</select>
</mapper>
</mapper>
amos-boot-system-tzs/amos-boot-module-statistics/amos-boot-module-statistics-api/src/main/resources/mapper/JGStatisticsMapper.xml
View file @
5974e866
...
@@ -665,212 +665,360 @@
...
@@ -665,212 +665,360 @@
COUNT DESC
COUNT DESC
limit 10
limit 10
</select>
</select>
<select
id=
"queryNoticeAvgDayByReceiveCompany"
resultType=
"com.yeejoin.amos.boot.biz.common.dto.CountDto"
>
<select
id=
"queryNoticeAvgDayByReceiveCompany"
resultType=
"com.yeejoin.amos.boot.biz.common.dto.CountDto"
>
SELECT
SELECT
round(avg(T.handle_date::date - T.notice_date::date + 1),1) as strValue,
round(avg(T.handle_date::date - T.notice_date::date + 1),1) as strValue,
T.receive_
company_org
_code AS keyStr
T.receive_
org_credit
_code AS keyStr
FROM
FROM
tzs_jg_installation_notice T
tzs_jg_installation_notice T
WHERE
WHERE
T.notice_status = 6616
T.notice_status = 6616
<choose>
<when
test=
'dto.cityCode != null and dto.cityCode == "610000"'
>
and 1=1
</when>
<otherwise>
<if
test=
"dto.companyCodes != null and dto.companyCodes.size > 0"
>
and T.receive_org_credit_code = ANY(ARRAY[
<foreach
collection=
"dto.companyCodes"
item=
"companyCode"
separator=
","
>
#{companyCode}
</foreach>
])
</if>
</otherwise>
</choose>
<if
test=
"dto.beginDate !=null and dto.beginDate !=''"
>
<if
test=
"dto.beginDate !=null and dto.beginDate !=''"
>
and date_ge(CAST(T.notice_date as date),#{dto.beginDate})
and date_ge(CAST(T.notice_date as date),#{dto.beginDate})
</if>
</if>
<if
test=
"dto.endDate !=null and dto.endDate !=''"
>
<if
test=
"dto.endDate !=null and dto.endDate !=''"
>
and date_le(CAST(T.notice_date as date),#{dto.endDate})
and date_le(CAST(T.notice_date as date),#{dto.endDate})
</if>
</if>
GROUP BY T.receive_
company_org
_code
GROUP BY T.receive_
org_credit
_code
union all
union all
SELECT
SELECT
round(avg(T.accept_date::date - T.notice_date::date + 1),1) as strValue,
round(avg(T.accept_date::date - T.notice_date::date + 1),1) as strValue,
T.receive_company_
org_
code AS keyStr
T.receive_company_code AS keyStr
FROM
FROM
tzs_jg_maintain_notice T
tzs_jg_maintain_notice T
WHERE
WHERE
T.notice_status = 6616
T.notice_status = 6616
<choose>
<when
test=
'dto.cityCode != null and dto.cityCode == "610000"'
>
and 1=1
</when>
<otherwise>
<if
test=
"dto.companyCodes != null and dto.companyCodes.size > 0"
>
and T.receive_company_code = ANY(ARRAY[
<foreach
collection=
"dto.companyCodes"
item=
"companyCode"
separator=
","
>
#{companyCode}
</foreach>
])
</if>
</otherwise>
</choose>
<if
test=
"dto.beginDate !=null and dto.beginDate !=''"
>
<if
test=
"dto.beginDate !=null and dto.beginDate !=''"
>
and date_ge(CAST(T.notice_date as date),#{dto.beginDate})
and date_ge(CAST(T.notice_date as date),#{dto.beginDate})
</if>
</if>
<if
test=
"dto.endDate !=null and dto.endDate !=''"
>
<if
test=
"dto.endDate !=null and dto.endDate !=''"
>
and date_le(CAST(T.notice_date as date),#{dto.endDate})
and date_le(CAST(T.notice_date as date),#{dto.endDate})
</if>
</if>
GROUP BY T.receive_company_
org_
code
GROUP BY T.receive_company_code
union all
union all
SELECT
SELECT
round(avg(T.accept_date::date - T.notice_date::date + 1),1) as strValue,
round(avg(T.accept_date::date - T.notice_date::date + 1),1) as strValue,
T.receive_company_
org_
code AS keyStr
T.receive_company_code AS keyStr
FROM
FROM
tzs_jg_reform_notice T
tzs_jg_reform_notice T
WHERE
WHERE
T.notice_status = 6616
T.notice_status = 6616
<choose>
<when
test=
'dto.cityCode != null and dto.cityCode == "610000"'
>
and 1=1
</when>
<otherwise>
<if
test=
"dto.companyCodes != null and dto.companyCodes.size > 0"
>
and T.receive_company_code = ANY(ARRAY[
<foreach
collection=
"dto.companyCodes"
item=
"companyCode"
separator=
","
>
#{companyCode}
</foreach>
])
</if>
</otherwise>
</choose>
<if
test=
"dto.beginDate !=null and dto.beginDate !=''"
>
<if
test=
"dto.beginDate !=null and dto.beginDate !=''"
>
and date_ge(CAST(T.notice_date as date),#{dto.beginDate})
and date_ge(CAST(T.notice_date as date),#{dto.beginDate})
</if>
</if>
<if
test=
"dto.endDate !=null and dto.endDate !=''"
>
<if
test=
"dto.endDate !=null and dto.endDate !=''"
>
and date_le(CAST(T.notice_date as date),#{dto.endDate})
and date_le(CAST(T.notice_date as date),#{dto.endDate})
</if>
</if>
GROUP BY T.receive_company_
org_
code
GROUP BY T.receive_company_code
union all
union all
SELECT
SELECT
round(avg(T.handle_date::date - T.notice_date::date + 1),1) as strValue,
round(avg(T.handle_date::date - T.notice_date::date + 1),1) as strValue,
T.receive_company_
org_
code AS keyStr
T.receive_company_code AS keyStr
FROM
FROM
tzs_jg_transfer_notice T
tzs_jg_transfer_notice T
WHERE
WHERE
T.notice_status = 6616
T.notice_status = 6616
<choose>
<when
test=
'dto.cityCode != null and dto.cityCode == "610000"'
>
and 1=1
</when>
<otherwise>
<if
test=
"dto.companyCodes != null and dto.companyCodes.size > 0"
>
and T.receive_company_code = ANY(ARRAY[
<foreach
collection=
"dto.companyCodes"
item=
"companyCode"
separator=
","
>
#{companyCode}
</foreach>
])
</if>
</otherwise>
</choose>
<if
test=
"dto.beginDate !=null and dto.beginDate !=''"
>
<if
test=
"dto.beginDate !=null and dto.beginDate !=''"
>
and date_ge(CAST(T.notice_date as date),#{dto.beginDate})
and date_ge(CAST(T.notice_date as date),#{dto.beginDate})
</if>
</if>
<if
test=
"dto.endDate !=null and dto.endDate !=''"
>
<if
test=
"dto.endDate !=null and dto.endDate !=''"
>
and date_le(CAST(T.notice_date as date),#{dto.endDate})
and date_le(CAST(T.notice_date as date),#{dto.endDate})
</if>
</if>
GROUP BY T.receive_company_
org_
code
GROUP BY T.receive_company_code
</select>
</select>
<select
id=
"queryUseAvgDayByReceiveCompany"
resultType=
"com.yeejoin.amos.boot.biz.common.dto.CountDto"
>
<select
id=
"queryUseAvgDayByReceiveCompany"
resultType=
"com.yeejoin.amos.boot.biz.common.dto.CountDto"
>
SELECT
SELECT
round(avg(T.audit_pass_date::date - T.reg_date::date + 1),1) as strValue,
round(avg(T.audit_pass_date::date - T.reg_date::date + 1),1) as strValue,
T.receive_company_org
_code AS keyStr
T.receive_company
_code AS keyStr
FROM
FROM
tzs_jg_use_registration T
tzs_jg_use_registration T
WHERE
WHERE
T.audit_status = '已完成' and T.is_delete = 0
T.audit_status = '已完成' and T.is_delete = 0
and T.receive_company_org_code like concat(#{orgCode}, '%')
<choose>
<when
test=
'dto.cityCode != null and dto.cityCode == "610000"'
>
and 1=1
</when>
<otherwise>
<if
test=
"dto.companyCodes != null and dto.companyCodes.size > 0"
>
and T.receive_company_code = ANY(ARRAY[
<foreach
collection=
"dto.companyCodes"
item=
"companyCode"
separator=
","
>
#{companyCode}
</foreach>
])
</if>
</otherwise>
</choose>
<if
test=
"dto.beginDate !=null and dto.beginDate !=''"
>
<if
test=
"dto.beginDate !=null and dto.beginDate !=''"
>
and date_ge(CAST(T.reg_date as date),#{dto.beginDate})
and date_ge(CAST(T.reg_date as date),#{dto.beginDate})
</if>
</if>
<if
test=
"dto.endDate !=null and dto.endDate !=''"
>
<if
test=
"dto.endDate !=null and dto.endDate !=''"
>
and date_le(CAST(T.reg_date as date),#{dto.endDate})
and date_le(CAST(T.reg_date as date),#{dto.endDate})
</if>
</if>
GROUP BY
T.receive_company
_org_code
GROUP BY
bi.supervise
_org_code
union all
union all
SELECT
SELECT
round(avg(T.audit_pass_date::date - T.reg_date::date + 1),1) as strValue,
round(avg(T.audit_pass_date::date - T.reg_date::date + 1),1) as strValue,
pc.org
_code AS keyStr
T.receive_company
_code AS keyStr
FROM
FROM
tzs_jg_vehicle_information T,
tzs_jg_vehicle_information T
privilege_company pc
WHERE
WHERE
T.status = '已完成'
T.status = '已完成'
and t.receive_company_code = pc.company_code
<choose>
and pc.org_code like concat(#{orgCode}, '%')
<when
test=
'dto.cityCode != null and dto.cityCode == "610000"'
>
and 1=1
</when>
<otherwise>
<if
test=
"dto.companyCodes != null and dto.companyCodes.size > 0"
>
and T.receive_company_code = ANY(ARRAY[
<foreach
collection=
"dto.companyCodes"
item=
"companyCode"
separator=
","
>
#{companyCode}
</foreach>
])
</if>
</otherwise>
</choose>
<if
test=
"dto.beginDate !=null and dto.beginDate !=''"
>
<if
test=
"dto.beginDate !=null and dto.beginDate !=''"
>
and date_ge(CAST(T.reg_date as date),#{dto.beginDate})
and date_ge(CAST(T.reg_date as date),#{dto.beginDate})
</if>
</if>
<if
test=
"dto.endDate !=null and dto.endDate !=''"
>
<if
test=
"dto.endDate !=null and dto.endDate !=''"
>
and date_le(CAST(T.reg_date as date),#{dto.endDate})
and date_le(CAST(T.reg_date as date),#{dto.endDate})
</if>
</if>
GROUP BY
pc.
org_code
GROUP BY
bi.supervise_
org_code
</select>
</select>
<select
id=
"queryChangeAvgDayByReceiveCompany"
resultType=
"com.yeejoin.amos.boot.biz.common.dto.CountDto"
>
<select
id=
"queryChangeAvgDayByReceiveCompany"
resultType=
"com.yeejoin.amos.boot.biz.common.dto.CountDto"
>
SELECT
SELECT
round(avg(
T.audit_pass_date::date - T
.apply_date::date + 1),1) as strValue,
round(avg(
crn.audit_pass_date::date - crn
.apply_date::date + 1),1) as strValue,
T.org
_code AS keyStr
crn.receive_company
_code AS keyStr
FROM
FROM
(
tzs_jg_change_registration_name crn
SELECT
WHERE
pc.org_code,
crn.audit_status = '已完成'
crn.apply_date,
<choose>
crn.audit_pass_date
<when
test=
'dto.cityCode != null and dto.cityCode == "610000"'
>
FROM
and 1=1
tzs_jg_change_registration_name crn,
</when>
privilege_company pc
<otherwise>
WHERE
<if
test=
"dto.companyCodes != null and dto.companyCodes.size > 0"
>
crn.receive_org_code = pc.company_code
and crn.receive_company_code = ANY(ARRAY[
AND crn.audit_status = '已完成'
<foreach
collection=
"dto.companyCodes"
item=
"companyCode"
separator=
","
>
and pc.org_code like concat(#{orgCode}, '%')
#{companyCode}
and crn.apply_date is not null
</foreach>
and crn.audit_pass_date is not null
])
<if
test=
"dto.beginDate !=null and dto.beginDate !=''"
>
</if>
and date_ge(CAST(crn.apply_date as date),#{dto.beginDate})
</otherwise>
</if>
</choose>
<if
test=
"dto.endDate !=null and dto.endDate !=''"
>
and crn.apply_date is not null
and date_le(CAST(crn.apply_date as date),#{dto.endDate})
and crn.audit_pass_date is not null
</if>
<if
test=
"dto.beginDate !=null and dto.beginDate !=''"
>
) T
and date_ge(CAST(crn.apply_date as date),#{dto.beginDate})
GROUP BY T.org_code
</if>
<if
test=
"dto.endDate !=null and dto.endDate !=''"
>
and date_le(CAST(crn.apply_date as date),#{dto.endDate})
</if>
GROUP BY crn.receive_company_code
union all
union all
SELECT
SELECT
round(avg(T.audit_pass_date::date - T.reg_date::date + 1),1) as strValue,
round(avg(T.audit_pass_date::date - T.reg_date::date + 1),1) as strValue,
T.receive_company_
org_
code AS keyStr
T.receive_company_code AS keyStr
FROM
FROM
tzs_jg_change_registration_reform T
tzs_jg_change_registration_reform T
WHERE
WHERE
T.audit_status = '已完成'
T.audit_status = '已完成'
and T.receive_company_org_code like concat(#{orgCode},'%')
<choose>
<when
test=
'dto.cityCode != null and dto.cityCode == "610000"'
>
and 1=1
</when>
<otherwise>
<if
test=
"dto.companyCodes != null and dto.companyCodes.size > 0"
>
and T.receive_company_code = ANY(ARRAY[
<foreach
collection=
"dto.companyCodes"
item=
"companyCode"
separator=
","
>
#{companyCode}
</foreach>
])
</if>
</otherwise>
</choose>
<if
test=
"dto.beginDate !=null and dto.beginDate !=''"
>
<if
test=
"dto.beginDate !=null and dto.beginDate !=''"
>
and date_ge(CAST(T.reg_date as date),#{dto.beginDate})
and date_ge(CAST(T.reg_date as date),#{dto.beginDate})
</if>
</if>
<if
test=
"dto.endDate !=null and dto.endDate !=''"
>
<if
test=
"dto.endDate !=null and dto.endDate !=''"
>
and date_le(CAST(T.reg_date as date),#{dto.endDate})
and date_le(CAST(T.reg_date as date),#{dto.endDate})
</if>
</if>
GROUP BY T.receive_company_
org_
code
GROUP BY T.receive_company_code
union all
union all
SELECT
SELECT
round(avg(T.audit_pass_date::date - T.reg_date::date + 1),1) as strValue,
round(avg(T.audit_pass_date::date - T.reg_date::date + 1),1) as strValue,
T.receive_company_
org_
code AS keyStr
T.receive_company_code AS keyStr
FROM
FROM
tzs_jg_change_registration_transfer T
tzs_jg_change_registration_transfer T
WHERE
WHERE
T.audit_status = '已完成'
T.audit_status = '已完成'
and T.receive_company_org_code like concat(#{orgCode},'%')
<choose>
<when
test=
'dto.cityCode != null and dto.cityCode == "610000"'
>
and 1=1
</when>
<otherwise>
<if
test=
"dto.companyCodes != null and dto.companyCodes.size > 0"
>
and T.receive_company_code = ANY(ARRAY[
<foreach
collection=
"dto.companyCodes"
item=
"companyCode"
separator=
","
>
#{companyCode}
</foreach>
])
</if>
</otherwise>
</choose>
<if
test=
"dto.beginDate !=null and dto.beginDate !=''"
>
<if
test=
"dto.beginDate !=null and dto.beginDate !=''"
>
and date_ge(CAST(T.reg_date as date),#{dto.beginDate})
and date_ge(CAST(T.reg_date as date),#{dto.beginDate})
</if>
</if>
<if
test=
"dto.endDate !=null and dto.endDate !=''"
>
<if
test=
"dto.endDate !=null and dto.endDate !=''"
>
and date_le(CAST(T.reg_date as date),#{dto.endDate})
and date_le(CAST(T.reg_date as date),#{dto.endDate})
</if>
</if>
GROUP BY T.receive_company_
org_
code
GROUP BY T.receive_company_code
union all
union all
SELECT
SELECT
round(avg(T.audit_pass_date::date - T.apply_date::date + 1),1) as strValue,
round(avg(T.audit_pass_date::date - T.apply_date::date + 1),1) as strValue,
T.receive_
company_
org_code AS keyStr
T.receive_org_code AS keyStr
FROM
FROM
tzs_jg_change_registration_unit T
tzs_jg_change_registration_unit T
WHERE
WHERE
T.status = '已完成'
T.status = '已完成'
and T.receive_company_org_code like concat(#{orgCode},'%')
<choose>
<when
test=
'dto.cityCode != null and dto.cityCode == "610000"'
>
and 1=1
</when>
<otherwise>
<if
test=
"dto.companyCodes != null and dto.companyCodes.size > 0"
>
and T.receive_org_code = ANY(ARRAY[
<foreach
collection=
"dto.companyCodes"
item=
"companyCode"
separator=
","
>
#{companyCode}
</foreach>
])
</if>
</otherwise>
</choose>
<if
test=
"dto.beginDate !=null and dto.beginDate !=''"
>
<if
test=
"dto.beginDate !=null and dto.beginDate !=''"
>
and date_ge(CAST(T.apply_date as date),#{dto.beginDate})
and date_ge(CAST(T.apply_date as date),#{dto.beginDate})
</if>
</if>
<if
test=
"dto.endDate !=null and dto.endDate !=''"
>
<if
test=
"dto.endDate !=null and dto.endDate !=''"
>
and date_le(CAST(T.apply_date as date),#{dto.endDate})
and date_le(CAST(T.apply_date as date),#{dto.endDate})
</if>
</if>
GROUP BY T.receive_
company_
org_code
GROUP BY T.receive_org_code
union all
union all
SELECT
SELECT
round(avg(T.audit_pass_date::date - T.apply_date::date + 1),1) as strValue,
round(avg(T.audit_pass_date::date - T.apply_date::date + 1),1) as strValue,
T.receive_
company_
org_code AS keyStr
T.receive_org_code AS keyStr
FROM
FROM
tzs_jg_change_vehicle_registration_unit T
tzs_jg_change_vehicle_registration_unit T
WHERE
WHERE
T.status = '已完成'
T.status = '已完成'
and T.receive_company_org_code like concat(#{orgCode},'%')
<choose>
<when
test=
'dto.cityCode != null and dto.cityCode == "610000"'
>
and 1=1
</when>
<otherwise>
<if
test=
"dto.companyCodes != null and dto.companyCodes.size > 0"
>
and T.receive_org_code = ANY(ARRAY[
<foreach
collection=
"dto.companyCodes"
item=
"companyCode"
separator=
","
>
#{companyCode}
</foreach>
])
</if>
</otherwise>
</choose>
<if
test=
"dto.beginDate !=null and dto.beginDate !=''"
>
<if
test=
"dto.beginDate !=null and dto.beginDate !=''"
>
and date_ge(CAST(T.apply_date as date),#{dto.beginDate})
and date_ge(CAST(T.apply_date as date),#{dto.beginDate})
</if>
</if>
<if
test=
"dto.endDate !=null and dto.endDate !=''"
>
<if
test=
"dto.endDate !=null and dto.endDate !=''"
>
and date_le(CAST(T.apply_date as date),#{dto.endDate})
and date_le(CAST(T.apply_date as date),#{dto.endDate})
</if>
</if>
GROUP BY T.receive_
company_
org_code
GROUP BY T.receive_org_code
</select>
</select>
<select
id=
"queryDisableAvgDayByReceiveCompany"
resultType=
"com.yeejoin.amos.boot.biz.common.dto.CountDto"
>
<select
id=
"queryDisableAvgDayByReceiveCompany"
resultType=
"com.yeejoin.amos.boot.biz.common.dto.CountDto"
>
SELECT
SELECT
round(avg(T.audit_pass_date::date - T.apply_date::date + 1),1) as strValue,
round(avg(T.audit_pass_date::date - T.apply_date::date + 1),1) as strValue,
T.
org
_code AS keyStr
T.
receive_company
_code AS keyStr
FROM
FROM
(
(
SELECT
SELECT
crn.sequence_nbr,
crn.sequence_nbr,
pc.org
_code,
crn.receive_company
_code,
crn.audit_pass_date,
crn.audit_pass_date,
crn.apply_date
crn.apply_date
FROM
FROM
tzs_jg_enable_disable crn,
tzs_jg_enable_disable crn
privilege_company pc
WHERE
WHERE
crn.receive_company_code = pc.company_code
crn.audit_status = '已完成'
AND crn.audit_status = '已完成'
<choose>
and pc.org_code like concat(#{orgCode}, '%')
<when
test=
'dto.cityCode != null and dto.cityCode == "610000"'
>
and 1=1
</when>
<otherwise>
<if
test=
"dto.companyCodes != null and dto.companyCodes.size > 0"
>
and crn.receive_company_code = ANY(ARRAY[
<foreach
collection=
"dto.companyCodes"
item=
"companyCode"
separator=
","
>
#{companyCode}
</foreach>
])
</if>
</otherwise>
</choose>
<if
test=
"dto.beginDate !=null and dto.beginDate !=''"
>
<if
test=
"dto.beginDate !=null and dto.beginDate !=''"
>
and date_ge(CAST(T.apply_date as date),#{dto.beginDate})
and date_ge(CAST(T.apply_date as date),#{dto.beginDate})
</if>
</if>
...
@@ -879,26 +1027,37 @@
...
@@ -879,26 +1027,37 @@
</if>
</if>
) T
) T
GROUP BY
GROUP BY
T.
org
_code
T.
receive_company
_code
</select>
</select>
<select
id=
"queryCancelAvgDayByReceiveCompany"
resultType=
"com.yeejoin.amos.boot.biz.common.dto.CountDto"
>
<select
id=
"queryCancelAvgDayByReceiveCompany"
resultType=
"com.yeejoin.amos.boot.biz.common.dto.CountDto"
>
SELECT
SELECT
round(avg(T.audit_pass_date::date - T.create_date::date + 1),1) as strValue,
round(avg(T.audit_pass_date::date - T.create_date::date + 1),1) as strValue,
T.org_code AS keyStr
T.
receive_
org_code AS keyStr
FROM
FROM
(
(
SELECT
SELECT
crn.sequence_nbr,
crn.sequence_nbr,
pc.
org_code,
crn.receive_
org_code,
crn.audit_pass_date,
crn.audit_pass_date,
crn.create_date
crn.create_date
FROM
FROM
tzs_jg_scrap_cancel crn,
tzs_jg_scrap_cancel crn
privilege_company pc
WHERE
WHERE
crn.receive_org_code = pc.company_code
crn.audit_status = '已完成'
AND crn.audit_status = '已完成'
<choose>
and pc.org_code like concat(#{orgCode}, '%')
<when
test=
'dto.cityCode != null and dto.cityCode == "610000"'
>
and 1=1
</when>
<otherwise>
<if
test=
"dto.companyCodes != null and dto.companyCodes.size > 0"
>
and crn.receive_org_code = ANY(ARRAY[
<foreach
collection=
"dto.companyCodes"
item=
"companyCode"
separator=
","
>
#{companyCode}
</foreach>
])
</if>
</otherwise>
</choose>
<if
test=
"dto.beginDate !=null and dto.beginDate !=''"
>
<if
test=
"dto.beginDate !=null and dto.beginDate !=''"
>
and date_ge(CAST(T.create_date as date),#{dto.beginDate})
and date_ge(CAST(T.create_date as date),#{dto.beginDate})
</if>
</if>
...
@@ -906,7 +1065,7 @@
...
@@ -906,7 +1065,7 @@
and date_le(CAST(T.create_date as date),#{dto.endDate})
and date_le(CAST(T.create_date as date),#{dto.endDate})
</if>
</if>
) T
) T
GROUP BY T.org_code
GROUP BY T.
receive_
org_code
</select>
</select>
<select
id=
"selectAZNoticeDetailList"
resultType=
"java.util.Map"
>
<select
id=
"selectAZNoticeDetailList"
resultType=
"java.util.Map"
>
SELECT
SELECT
...
...
amos-boot-system-tzs/amos-boot-module-statistics/amos-boot-module-statistics-biz/src/main/java/com/yeejoin/amos/boot/module/statistcs/biz/service/impl/JGDPStatisticsServiceImpl.java
View file @
5974e866
...
@@ -1313,9 +1313,9 @@ public class JGDPStatisticsServiceImpl {
...
@@ -1313,9 +1313,9 @@ public class JGDPStatisticsServiceImpl {
List
<
String
>
yData
=
new
ArrayList
<>();
List
<
String
>
yData
=
new
ArrayList
<>();
regionModels
.
forEach
(
r
->
{
regionModels
.
forEach
(
r
->
{
xData
.
add
(
r
.
getRegionName
());
xData
.
add
(
r
.
getRegionName
());
String
orgCode
=
stCommonService
.
getAndSetOrgCode
(
r
.
getRegionCode
().
toString
()
);
String
selfAndChildRegion
=
stCommonService
.
getSelfAndChildRegion
(
r
);
if
(!
ValidationUtil
.
isEmpty
(
orgCode
))
{
if
(!
ValidationUtil
.
isEmpty
(
selfAndChildRegion
))
{
yData
.
add
(
this
.
avgAndSumDealDate
(
countDtos
.
stream
().
filter
(
c
->
c
.
getKeyStr
().
contains
(
orgCode
)).
collect
(
Collectors
.
toList
())));
yData
.
add
(
this
.
avgAndSumDealDate
(
countDtos
.
stream
().
filter
(
c
->
selfAndChildRegion
.
contains
(
stCommonService
.
castCompanyCode2RegionCode
(
c
.
getKeyStr
())
)).
collect
(
Collectors
.
toList
())));
}
else
{
}
else
{
yData
.
add
(
"0"
);
yData
.
add
(
"0"
);
}
}
...
...
amos-boot-system-tzs/amos-boot-module-statistics/amos-boot-module-statistics-biz/src/main/java/com/yeejoin/amos/boot/module/statistcs/biz/service/impl/StCommonServiceImpl.java
View file @
5974e866
...
@@ -22,6 +22,7 @@ import com.yeejoin.amos.boot.module.ymt.api.mapper.EquipTechParamPipelineMapper;
...
@@ -22,6 +22,7 @@ import com.yeejoin.amos.boot.module.ymt.api.mapper.EquipTechParamPipelineMapper;
import
com.yeejoin.amos.boot.module.ymt.api.mapper.EquipmentCategoryMapper
;
import
com.yeejoin.amos.boot.module.ymt.api.mapper.EquipmentCategoryMapper
;
import
com.yeejoin.amos.feign.systemctl.Systemctl
;
import
com.yeejoin.amos.feign.systemctl.Systemctl
;
import
com.yeejoin.amos.feign.systemctl.model.RegionModel
;
import
com.yeejoin.amos.feign.systemctl.model.RegionModel
;
import
lombok.Getter
;
import
org.apache.commons.lang3.StringUtils
;
import
org.apache.commons.lang3.StringUtils
;
import
org.apache.lucene.queryparser.classic.QueryParser
;
import
org.apache.lucene.queryparser.classic.QueryParser
;
import
org.apache.lucene.search.join.ScoreMode
;
import
org.apache.lucene.search.join.ScoreMode
;
...
@@ -77,23 +78,24 @@ public class StCommonServiceImpl {
...
@@ -77,23 +78,24 @@ public class StCommonServiceImpl {
*/
*/
public
final
static
String
REGION_LEVEL_THIRD
=
"3"
;
public
final
static
String
REGION_LEVEL_THIRD
=
"3"
;
private
CommonBaseMapper
commonMapper
;
private
final
CommonBaseMapper
commonMapper
;
private
RestHighLevelClient
restHighLevelClient
;
private
final
RestHighLevelClient
restHighLevelClient
;
private
TZSCommonServiceImpl
tzsCommonService
;
private
final
TZSCommonServiceImpl
tzsCommonService
;
private
EquipTechParamPipelineMapper
techParamsPipelineMapper
;
private
final
EquipTechParamPipelineMapper
techParamsPipelineMapper
;
private
EquipmentCategoryMapper
equipmentCategoryMapper
;
private
final
EquipmentCategoryMapper
equipmentCategoryMapper
;
private
ZLStatisticsMapper
zlStatisticsMapper
;
private
final
ZLStatisticsMapper
zlStatisticsMapper
;
private
static
Map
<
String
,
String
>
regionCodeOrgCodeMap
=
new
ConcurrentHashMap
<>();
@Getter
private
static
final
Map
<
String
,
String
>
regionCodeOrgCodeMap
=
new
ConcurrentHashMap
<>();
private
static
Map
<
Integer
,
RegionModel
>
regionCodeRegionMap
=
new
ConcurrentHashMap
<>();
private
static
Map
<
Integer
,
RegionModel
>
regionCodeRegionMap
=
new
ConcurrentHashMap
<>();
private
static
List
<
RegionModel
>
regionModels
=
new
ArrayList
<>();
private
static
final
List
<
RegionModel
>
regionModels
=
new
ArrayList
<>();
private
static
List
<
EquipmentCategoryDto
>
equipmentCategoryDtos
;
private
static
List
<
EquipmentCategoryDto
>
equipmentCategoryDtos
;
...
@@ -111,10 +113,6 @@ public class StCommonServiceImpl {
...
@@ -111,10 +113,6 @@ public class StCommonServiceImpl {
this
.
tzsCommonService
=
tzsCommonService
;
this
.
tzsCommonService
=
tzsCommonService
;
}
}
public
static
Map
<
String
,
String
>
getRegionCodeOrgCodeMap
()
{
return
regionCodeOrgCodeMap
;
}
public
static
List
<
EquipmentCategoryDto
>
getEquipmentCategory
()
{
public
static
List
<
EquipmentCategoryDto
>
getEquipmentCategory
()
{
return
equipmentCategoryDtos
;
return
equipmentCategoryDtos
;
}
}
...
@@ -156,9 +154,18 @@ public class StCommonServiceImpl {
...
@@ -156,9 +154,18 @@ public class StCommonServiceImpl {
public
String
getAndSetOrgCode
(
DPFilterParamDto
dpFilterParamDto
)
{
public
String
getAndSetOrgCode
(
DPFilterParamDto
dpFilterParamDto
)
{
String
cityCode
=
dpFilterParamDto
.
getCityCode
();
String
cityCode
=
dpFilterParamDto
.
getCityCode
();
this
.
setChildCompanyCodeByRegion
(
cityCode
,
dpFilterParamDto
);
return
getAndSetOrgCode
(
cityCode
);
return
getAndSetOrgCode
(
cityCode
);
}
}
/**
* 按照regionCode查询区域下的公司
* @param cityCode 区域
* @param dpFilterParamDto 过滤条件
*/
private
void
setChildCompanyCodeByRegion
(
String
cityCode
,
DPFilterParamDto
dpFilterParamDto
)
{
}
public
String
getAndSetOrgCode
(
String
cityCode
)
{
public
String
getAndSetOrgCode
(
String
cityCode
)
{
String
orgCode
=
regionCodeOrgCodeMap
.
get
(
cityCode
);
String
orgCode
=
regionCodeOrgCodeMap
.
get
(
cityCode
);
if
(
orgCode
==
null
)
{
if
(
orgCode
==
null
)
{
...
@@ -551,4 +558,25 @@ public class StCommonServiceImpl {
...
@@ -551,4 +558,25 @@ public class StCommonServiceImpl {
children
.
forEach
(
child
->
buildSubtree
(
child
,
parentCodeMap
));
children
.
forEach
(
child
->
buildSubtree
(
child
,
parentCodeMap
));
}
}
}
}
/**
* 获取本级及子级区域code
* @param region 区域
* @return 本级及子级区域code
*/
public
String
getSelfAndChildRegion
(
RegionModel
region
)
{
return
null
;
}
/**
* 将单位code转行政区划
* @param companyCode 单位code
* @return 单位所在行政区划
*/
public
CharSequence
castCompanyCode2RegionCode
(
String
companyCode
)
{
String
regionSeq
=
commonMapper
.
selectCompanyRegionSeq
(
companyCode
);
Optional
<
RegionModel
>
optionalRegionModel
=
regionModels
.
stream
().
filter
(
r
->
String
.
valueOf
(
r
.
getSequenceNbr
()).
equals
(
regionSeq
)).
findFirst
();
optionalRegionModel
.
orElseThrow
(()->
new
RuntimeException
(
""
));
return
null
;
}
}
}
amos-boot-system-tzs/amos-boot-module-tcm/amos-boot-module-tcm-biz/src/main/java/com/yeejoin/amos/boot/module/tcm/biz/controller/TzBaseEnterpriseInfoController.java
View file @
5974e866
...
@@ -30,6 +30,7 @@ import org.springframework.beans.factory.annotation.Value;
...
@@ -30,6 +30,7 @@ import org.springframework.beans.factory.annotation.Value;
import
org.springframework.core.io.Resource
;
import
org.springframework.core.io.Resource
;
import
org.springframework.http.MediaType
;
import
org.springframework.http.MediaType
;
import
org.springframework.web.bind.annotation.*
;
import
org.springframework.web.bind.annotation.*
;
import
org.typroject.tyboot.component.event.RestEventTrigger
;
import
org.typroject.tyboot.core.foundation.context.RequestContext
;
import
org.typroject.tyboot.core.foundation.context.RequestContext
;
import
org.typroject.tyboot.core.foundation.enumeration.UserType
;
import
org.typroject.tyboot.core.foundation.enumeration.UserType
;
import
org.typroject.tyboot.core.foundation.utils.ValidationUtil
;
import
org.typroject.tyboot.core.foundation.utils.ValidationUtil
;
...
@@ -383,6 +384,7 @@ public class TzBaseEnterpriseInfoController extends BaseController {
...
@@ -383,6 +384,7 @@ public class TzBaseEnterpriseInfoController extends BaseController {
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@DeleteMapping
(
value
=
"/deleteBatch"
)
@DeleteMapping
(
value
=
"/deleteBatch"
)
@ApiOperation
(
httpMethod
=
"DELETE"
,
value
=
"批量删除企业"
,
notes
=
"批量删除企业"
)
@ApiOperation
(
httpMethod
=
"DELETE"
,
value
=
"批量删除企业"
,
notes
=
"批量删除企业"
)
@RestEventTrigger
(
value
=
"operateLogRestEventHandler"
)
public
ResponseModel
<
Boolean
>
deleteBatch
(
@RequestParam
String
ids
)
{
public
ResponseModel
<
Boolean
>
deleteBatch
(
@RequestParam
String
ids
)
{
return
ResponseHelper
.
buildResponse
(
enterpriseManageService
.
delete
(
Arrays
.
asList
(
ids
.
split
(
","
))));
return
ResponseHelper
.
buildResponse
(
enterpriseManageService
.
delete
(
Arrays
.
asList
(
ids
.
split
(
","
))));
}
}
...
@@ -390,6 +392,7 @@ public class TzBaseEnterpriseInfoController extends BaseController {
...
@@ -390,6 +392,7 @@ public class TzBaseEnterpriseInfoController extends BaseController {
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@PutMapping
(
value
=
"/enableBatch"
)
@PutMapping
(
value
=
"/enableBatch"
)
@ApiOperation
(
httpMethod
=
"PUT"
,
value
=
"企业启用"
,
notes
=
"企业启用"
)
@ApiOperation
(
httpMethod
=
"PUT"
,
value
=
"企业启用"
,
notes
=
"企业启用"
)
@RestEventTrigger
(
value
=
"operateLogRestEventHandler"
)
public
ResponseModel
<
Boolean
>
enableBatch
(
@RequestParam
String
ids
)
{
public
ResponseModel
<
Boolean
>
enableBatch
(
@RequestParam
String
ids
)
{
return
ResponseHelper
.
buildResponse
(
enterpriseManageService
.
enable
(
Arrays
.
asList
(
ids
.
split
(
","
))));
return
ResponseHelper
.
buildResponse
(
enterpriseManageService
.
enable
(
Arrays
.
asList
(
ids
.
split
(
","
))));
}
}
...
@@ -397,6 +400,7 @@ public class TzBaseEnterpriseInfoController extends BaseController {
...
@@ -397,6 +400,7 @@ public class TzBaseEnterpriseInfoController extends BaseController {
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@PutMapping
(
value
=
"/disableBatch"
)
@PutMapping
(
value
=
"/disableBatch"
)
@ApiOperation
(
httpMethod
=
"PUT"
,
value
=
"企业停用"
,
notes
=
"企业停用"
)
@ApiOperation
(
httpMethod
=
"PUT"
,
value
=
"企业停用"
,
notes
=
"企业停用"
)
@RestEventTrigger
(
value
=
"operateLogRestEventHandler"
)
public
ResponseModel
<
Boolean
>
disableBatch
(
@RequestParam
String
ids
)
{
public
ResponseModel
<
Boolean
>
disableBatch
(
@RequestParam
String
ids
)
{
return
ResponseHelper
.
buildResponse
(
enterpriseManageService
.
disable
(
Arrays
.
asList
(
ids
.
split
(
","
))));
return
ResponseHelper
.
buildResponse
(
enterpriseManageService
.
disable
(
Arrays
.
asList
(
ids
.
split
(
","
))));
}
}
...
...
amos-boot-system-tzs/amos-boot-module-tcm/amos-boot-module-tcm-biz/src/main/java/com/yeejoin/amos/boot/module/tcm/biz/listener/PlatformUserTopicMessage.java
View file @
5974e866
...
@@ -117,7 +117,7 @@ public class PlatformUserTopicMessage extends EmqxListener {
...
@@ -117,7 +117,7 @@ public class PlatformUserTopicMessage extends EmqxListener {
}
}
if
(!
ValidationUtil
.
isEmpty
(
dataResult
)
&&
StringUtils
.
isNotEmpty
(
path
))
{
if
(!
ValidationUtil
.
isEmpty
(
dataResult
)
&&
StringUtils
.
isNotEmpty
(
path
))
{
if
(
path
.
contains
(
"company"
))
{
if
(
path
.
contains
(
"company"
))
{
if
(
"监管机构"
.
equals
(
dataResult
.
get
(
"companyType"
)))
{
if
(
"监管机构"
.
equals
(
dataResult
.
get
(
"companyType"
))
||
"行政审批局"
.
equals
(
dataResult
.
get
(
"companyType"
))
)
{
equipmentCategoryService
.
deleteAllRegulatorUnitTree
();
equipmentCategoryService
.
deleteAllRegulatorUnitTree
();
}
}
tzBaseEnterpriseInfoService
.
refreshCompanyInfo
(
dataResult
,
method
);
tzBaseEnterpriseInfoService
.
refreshCompanyInfo
(
dataResult
,
method
);
...
...
amos-boot-system-tzs/amos-boot-module-tcm/amos-boot-module-tcm-biz/src/main/java/com/yeejoin/amos/boot/module/tcm/biz/service/impl/EquipmentCategoryServiceImpl.java
View file @
5974e866
...
@@ -369,7 +369,7 @@ public class EquipmentCategoryServiceImpl extends BaseService<EquipmentCategoryD
...
@@ -369,7 +369,7 @@ public class EquipmentCategoryServiceImpl extends BaseService<EquipmentCategoryD
// 一行数据可能 满足几个remove,所以需要删除后,继续下一循环
// 一行数据可能 满足几个remove,所以需要删除后,继续下一循环
continue
;
continue
;
}
}
if
(
e
.
get
(
"company
Nam
e"
).
toString
().
contains
(
"行政审批局"
))
{
if
(
e
.
get
(
"company
Typ
e"
).
toString
().
contains
(
"行政审批局"
))
{
it
.
remove
();
it
.
remove
();
// 一行数据可能 满足几个remove,所以需要删除后,继续下一循环
// 一行数据可能 满足几个remove,所以需要删除后,继续下一循环
continue
;
continue
;
...
...
amos-boot-system-tzs/amos-boot-module-tcm/amos-boot-module-tcm-biz/src/main/java/com/yeejoin/amos/boot/module/tcm/biz/service/impl/TzBaseEnterpriseInfoServiceImpl.java
View file @
5974e866
...
@@ -1484,10 +1484,10 @@ public class TzBaseEnterpriseInfoServiceImpl
...
@@ -1484,10 +1484,10 @@ public class TzBaseEnterpriseInfoServiceImpl
log
.
error
(
"平台获取子单位失败"
);
log
.
error
(
"平台获取子单位失败"
);
return
;
return
;
}
}
List
<
CompanyModel
>
companyModels
=
result
.
getResult
().
stream
().
filter
(
i
->
!
i
.
getCompanyType
().
equals
(
"监管机构"
)).
collect
(
Collectors
.
toList
());
List
<
CompanyModel
>
companyModels
=
result
.
getResult
().
stream
().
filter
(
i
->
!
i
.
getCompanyType
().
equals
(
"监管机构"
)
&&
!
i
.
getCompanyType
().
equals
(
"行政审批局"
)
).
collect
(
Collectors
.
toList
());
// 如果消息中的单位是企业
// 如果消息中的单位是企业
if
(!
companyBo
.
getCompanyType
().
equals
(
"监管机构"
))
{
if
(!
companyBo
.
getCompanyType
().
equals
(
"监管机构"
)
&&
!
companyBo
.
getCompanyType
().
equals
(
"行政审批局"
)
)
{
switch
(
Objects
.
requireNonNull
(
PlatformOpMethodTypeEnum
.
getEnumByCode
(
method
)))
{
switch
(
Objects
.
requireNonNull
(
PlatformOpMethodTypeEnum
.
getEnumByCode
(
method
)))
{
case
CREATE:
case
CREATE:
case
INSERT:
case
INSERT:
...
...
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