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
dae2ba70
Commit
dae2ba70
authored
Oct 21, 2024
by
韩桐桐
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'origin/develop_tzs_bugfix' into develop_tzs_bugfix
parents
2a179985
0e995ba4
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
107 additions
and
73 deletions
+107
-73
OpenapiBizTokenController.java
...mos/api/openapi/controller/OpenapiBizTokenController.java
+24
-37
JgEquipInsuranceMapper.java
...mos/boot/module/jg/api/mapper/JgEquipInsuranceMapper.java
+4
-2
JgEquipInsuranceMapper.xml
...-api/src/main/resources/mapper/JgEquipInsuranceMapper.xml
+15
-1
JgEquipInsuranceServiceImpl.java
...dule/jg/biz/service/impl/JgEquipInsuranceServiceImpl.java
+60
-32
JgUseRegistrationServiceImpl.java
...ule/jg/biz/service/impl/JgUseRegistrationServiceImpl.java
+1
-0
JgVehicleInformationServiceImpl.java
.../jg/biz/service/impl/JgVehicleInformationServiceImpl.java
+3
-1
No files found.
amos-boot-data/amos-boot-data-openapi/src/main/java/com/yeejoin/amos/api/openapi/controller/OpenapiBizTokenController.java
View file @
dae2ba70
package
com
.
yeejoin
.
amos
.
api
.
openapi
.
controller
;
package
com
.
yeejoin
.
amos
.
api
.
openapi
.
controller
;
import
com.yeejoin.amos.api.common.restful.utils.ResponseHelper
;
import
com.yeejoin.amos.api.common.restful.utils.ResponseModel
;
import
com.yeejoin.amos.api.openapi.face.service.OpenapiBizTokenService
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiOperation
;
import
org.apache.logging.log4j.LogManager
;
import
org.apache.logging.log4j.LogManager
;
import
org.apache.logging.log4j.Logger
;
import
org.apache.logging.log4j.Logger
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.validation.annotation.Validated
;
import
org.springframework.web.bind.annotation.GetMapping
;
import
org.springframework.web.bind.annotation.GetMapping
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.RequestParam
;
import
org.springframework.web.bind.annotation.RequestParam
;
...
@@ -10,15 +16,9 @@ import org.springframework.web.bind.annotation.RestController;
...
@@ -10,15 +16,9 @@ import org.springframework.web.bind.annotation.RestController;
import
org.typroject.tyboot.core.foundation.enumeration.UserType
;
import
org.typroject.tyboot.core.foundation.enumeration.UserType
;
import
org.typroject.tyboot.core.restful.doc.TycloudOperation
;
import
org.typroject.tyboot.core.restful.doc.TycloudOperation
;
import
com.yeejoin.amos.api.common.restful.utils.ResponseHelper
;
import
javax.validation.constraints.NotBlank
;
import
com.yeejoin.amos.api.common.restful.utils.ResponseModel
;
import
com.yeejoin.amos.api.openapi.face.service.OpenapiBizTokenService
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiOperation
;
/**
/**
*
* <pre>
* <pre>
* 企业数据对接票据管理
* 企业数据对接票据管理
* </pre>
* </pre>
...
@@ -29,34 +29,21 @@ import io.swagger.annotations.ApiOperation;
...
@@ -29,34 +29,21 @@ import io.swagger.annotations.ApiOperation;
@RestController
@RestController
@RequestMapping
(
value
=
"/bizToken"
)
@RequestMapping
(
value
=
"/bizToken"
)
@Api
(
tags
=
"bizToken-企业数据对接票据管理"
)
@Api
(
tags
=
"bizToken-企业数据对接票据管理"
)
public
class
OpenapiBizTokenController
@Validated
{
public
class
OpenapiBizTokenController
{
private
static
final
Logger
logger
=
LogManager
.
getLogger
(
OpenapiBizTokenController
.
class
);
private
static
final
Logger
logger
=
LogManager
.
getLogger
(
OpenapiBizTokenController
.
class
);
@Autowired
@Autowired
private
OpenapiBizTokenService
openapiBizTokenService
;
private
OpenapiBizTokenService
openapiBizTokenService
;
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
,
needAuth
=
false
)
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
,
needAuth
=
false
)
@ApiOperation
(
value
=
"申请登录令牌"
)
@ApiOperation
(
value
=
"申请登录令牌"
)
@GetMapping
(
value
=
"/applyToken"
)
@GetMapping
(
value
=
"/applyToken"
)
public
ResponseModel
<
String
>
applyToken
(
public
ResponseModel
<
String
>
applyToken
(
@RequestParam
String
appId
)
throws
Exception
@NotBlank
(
message
=
"appId不能为空"
)
@RequestParam
String
appId
)
{
{
logger
.
info
(
"appId信息:{}"
,
appId
);
logger
.
info
(
"appId信息:"
,
appId
);
String
appToken
=
openapiBizTokenService
.
getByAppId
(
appId
);
String
appToken
=
openapiBizTokenService
.
getByAppId
(
appId
);
logger
.
info
(
"appToken信息:{}"
,
appToken
);
logger
.
info
(
"appToken信息:"
,
appToken
);
return
ResponseHelper
.
buildResponse
(
appToken
);
return
ResponseHelper
.
buildResponse
(
appToken
);
}
}
// @TycloudOperation(ApiLevel = UserType.AGENCY, needAuth = false)
// @ApiOperation(value = "获取APPID")
// @GetMapping(value = "/getAppId")
// public ResponseModel<String> getAppId (
// @RequestParam String companyCode) throws Exception
// {
// String appId = DesUtil.encode(companyCode, Constant.SECRETKEY);
// logger.info("appId信息:",appId);
// return ResponseHelper.buildResponse(appId);
// }
//
}
}
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-api/src/main/java/com/yeejoin/amos/boot/module/jg/api/mapper/JgEquipInsuranceMapper.java
View file @
dae2ba70
...
@@ -2,12 +2,11 @@ package com.yeejoin.amos.boot.module.jg.api.mapper;
...
@@ -2,12 +2,11 @@ package com.yeejoin.amos.boot.module.jg.api.mapper;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
com.yeejoin.amos.boot.module.jg.api.dto.JgEquipInsuranceDto
;
import
com.yeejoin.amos.boot.module.jg.api.dto.JgEquipInsuranceDto
;
import
com.yeejoin.amos.boot.module.jg.api.dto.JgUseRegistrationDto
;
import
com.yeejoin.amos.boot.module.jg.api.entity.JgEquipInsurance
;
import
com.yeejoin.amos.boot.module.jg.api.entity.JgEquipInsurance
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
import
com.yeejoin.amos.boot.module.jg.api.vo.SortVo
;
import
com.yeejoin.amos.boot.module.jg.api.vo.SortVo
;
import
org.apache.ibatis.annotations.MapKey
;
import
org.apache.ibatis.annotations.Param
;
import
org.apache.ibatis.annotations.Param
;
import
java.util.List
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.Map
;
...
@@ -24,4 +23,7 @@ public interface JgEquipInsuranceMapper extends BaseMapper<JgEquipInsurance> {
...
@@ -24,4 +23,7 @@ public interface JgEquipInsuranceMapper extends BaseMapper<JgEquipInsurance> {
@Param
(
"dto"
)
JgEquipInsuranceDto
dto
);
@Param
(
"dto"
)
JgEquipInsuranceDto
dto
);
JgEquipInsuranceDto
getDetailById
(
@Param
(
"sequenceNbr"
)
Long
sequenceNbr
);
JgEquipInsuranceDto
getDetailById
(
@Param
(
"sequenceNbr"
)
Long
sequenceNbr
);
@MapKey
(
"orgCode"
)
List
<
Map
<
String
,
Object
>>
getEquipInsuranceTotal
(
@Param
(
"orgCode"
)
String
orgCode
);
}
}
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-api/src/main/resources/mapper/JgEquipInsuranceMapper.xml
View file @
dae2ba70
...
@@ -14,7 +14,7 @@
...
@@ -14,7 +14,7 @@
tjei.insurance_number as insuranceNumber,
tjei.insurance_number as insuranceNumber,
tjei.insurance_expiration_date as insuranceExpirationDate,
tjei.insurance_expiration_date as insuranceExpirationDate,
date_format(tjei.rec_date,'%Y-%m-%d') as recDate,
date_format(tjei.rec_date,'%Y-%m-%d') as recDate,
jri.ORGANIZATION
_NAME as receiveOrgName,
ibjsi.ORG_BRANCH
_NAME as receiveOrgName,
jri.USE_ORG_CODE as useRegistrationCode,
jri.USE_ORG_CODE as useRegistrationCode,
ibjui.USE_UNIT_NAME as useUnitName,
ibjui.USE_UNIT_NAME as useUnitName,
ibjui.USE_INNER_CODE as useInnerCode,
ibjui.USE_INNER_CODE as useInnerCode,
...
@@ -27,6 +27,7 @@
...
@@ -27,6 +27,7 @@
LEFT JOIN idx_biz_jg_register_info jri on tjei.equ_id = jri.RECORD
LEFT JOIN idx_biz_jg_register_info jri on tjei.equ_id = jri.RECORD
LEFT JOIN idx_biz_jg_use_info ibjui on tjei.equ_id = ibjui.RECORD
LEFT JOIN idx_biz_jg_use_info ibjui on tjei.equ_id = ibjui.RECORD
LEFT JOIN idx_biz_jg_factory_info ibjfi on tjei.equ_id = ibjfi.RECORD
LEFT JOIN idx_biz_jg_factory_info ibjfi on tjei.equ_id = ibjfi.RECORD
LEFT JOIN idx_biz_jg_supervision_info ibjsi ON tjei.equ_id = ibjsi.RECORD
</sql>
</sql>
<select
id=
"getListPage"
resultType=
"com.yeejoin.amos.boot.module.jg.api.dto.JgEquipInsuranceDto"
>
<select
id=
"getListPage"
resultType=
"com.yeejoin.amos.boot.module.jg.api.dto.JgEquipInsuranceDto"
>
...
@@ -61,4 +62,17 @@
...
@@ -61,4 +62,17 @@
<include
refid=
"page-list"
/>
<include
refid=
"page-list"
/>
where tjei.sequence_nbr = #{sequenceNbr} and tjei.is_delete = 0
where tjei.sequence_nbr = #{sequenceNbr} and tjei.is_delete = 0
</select>
</select>
<select
id=
"getEquipInsuranceTotal"
resultType=
"map"
>
SELECT
COALESCE(SUM(CASE WHEN jri.EQU_LIST = '3000' THEN 1 ELSE 0 END), 0) AS elevatorInsuranceCount,
COALESCE(SUM(CASE WHEN jri.EQU_CATEGORY = '2300' THEN 1 ELSE 0 END), 0) AS cylinderInsuranceCount
FROM
tzs_jg_equip_insurance tjei
LEFT JOIN idx_biz_jg_supervision_info ibjsi ON tjei.equ_id = ibjsi.RECORD
LEFT JOIN idx_biz_jg_register_info jri ON tjei.equ_id = jri.RECORD
WHERE
tjei.is_delete = 0
AND ibjsi.ORG_BRANCH_CODE LIKE CONCAT(#{orgCode}, '%');
</select>
</mapper>
</mapper>
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/JgEquipInsuranceServiceImpl.java
View file @
dae2ba70
...
@@ -35,6 +35,8 @@ import org.springframework.stereotype.Service;
...
@@ -35,6 +35,8 @@ import org.springframework.stereotype.Service;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
org.typroject.tyboot.core.restful.exception.instance.BadRequest
;
import
org.typroject.tyboot.core.restful.exception.instance.BadRequest
;
import
java.io.IOException
;
import
java.io.IOException
;
import
java.math.BigDecimal
;
import
java.math.RoundingMode
;
import
java.util.*
;
import
java.util.*
;
import
java.util.concurrent.CompletableFuture
;
import
java.util.concurrent.CompletableFuture
;
import
java.util.concurrent.ConcurrentHashMap
;
import
java.util.concurrent.ConcurrentHashMap
;
...
@@ -63,6 +65,13 @@ public class JgEquipInsuranceServiceImpl extends BaseService<JgEquipInsurance,Jg
...
@@ -63,6 +65,13 @@ public class JgEquipInsuranceServiceImpl extends BaseService<JgEquipInsurance,Jg
private
static
final
String
INDEX_NAME
=
"idx_biz_view_jg_all"
;
private
static
final
String
INDEX_NAME
=
"idx_biz_view_jg_all"
;
public
static
final
String
REGION_CODE
=
"regionCode"
;
public
static
final
String
REGION_CODE
=
"regionCode"
;
public
static
final
String
REGION_NAME
=
"regionName"
;
public
static
final
String
ELEVATOR
=
"elevator"
;
public
static
final
String
CYLINDER
=
"cylinder"
;
public
static
final
String
ELEVATOR_INSURANCE_COUNT
=
"elevatorInsuranceCount"
;
public
static
final
String
CYLINDER_INSURANCE_COUNT
=
"cylinderInsuranceCount"
;
public
static
final
String
ELEVATOR_INSURANCE_RATE
=
"elevatorInsuranceRate"
;
public
static
final
String
CYLINDER_INSURANCE_RATE
=
"cylinderInsuranceRate"
;
private
static
final
Map
<
String
,
String
>
regionCodeOrgCodeMap
=
new
ConcurrentHashMap
<>();
private
static
final
Map
<
String
,
String
>
regionCodeOrgCodeMap
=
new
ConcurrentHashMap
<>();
...
@@ -134,8 +143,7 @@ public class JgEquipInsuranceServiceImpl extends BaseService<JgEquipInsurance,Jg
...
@@ -134,8 +143,7 @@ public class JgEquipInsuranceServiceImpl extends BaseService<JgEquipInsurance,Jg
public
Map
<
String
,
Object
>
countLiabilityInsuranceStatisticsByCity
()
{
public
Map
<
String
,
Object
>
countLiabilityInsuranceStatisticsByCity
()
{
List
<
RegionModel
>
regionModelList
=
Systemctl
.
regionClient
.
queryByLevel
(
"2"
).
getResult
();
List
<
RegionModel
>
regionModelList
=
Systemctl
.
regionClient
.
queryByLevel
(
"2"
).
getResult
();
List
<
Map
<
String
,
Object
>>
esQueryResults
=
processAsync
(
regionModelList
,
this
::
esQuery
);
List
<
Map
<
String
,
Object
>>
esQueryResults
=
processAsync
(
regionModelList
,
this
::
esQuery
);
List
<
Map
<
String
,
Object
>>
insuranceResults
=
processAsync
(
regionModelList
,
this
::
getInsurance
);
return
assemblingHistogramData
(
esQueryResults
);
return
assemblingHistogramData
(
esQueryResults
,
insuranceResults
);
}
}
// 公共方法,用于异步处理逻辑
// 公共方法,用于异步处理逻辑
...
@@ -148,13 +156,6 @@ public class JgEquipInsuranceServiceImpl extends BaseService<JgEquipInsurance,Jg
...
@@ -148,13 +156,6 @@ public class JgEquipInsuranceServiceImpl extends BaseService<JgEquipInsurance,Jg
.
collect
(
Collectors
.
toList
());
.
collect
(
Collectors
.
toList
());
}
}
private
Map
<
String
,
Object
>
getInsurance
(
RegionModel
regionModel
)
{
Map
<
String
,
Object
>
resultMap
=
new
HashMap
<>();
resultMap
.
put
(
"ELEVATOR_INSURANCE"
,
""
);
resultMap
.
put
(
"CYLINDER_INSURANCE"
,
""
);
return
resultMap
;
}
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
)
{
...
@@ -194,67 +195,93 @@ public class JgEquipInsuranceServiceImpl extends BaseService<JgEquipInsurance,Jg
...
@@ -194,67 +195,93 @@ public class JgEquipInsuranceServiceImpl extends BaseService<JgEquipInsurance,Jg
SearchResponse
searchResponse
=
restHighLevelClient
.
search
(
searchRequest
,
RequestOptions
.
DEFAULT
);
SearchResponse
searchResponse
=
restHighLevelClient
.
search
(
searchRequest
,
RequestOptions
.
DEFAULT
);
// 获取所有聚合结果
// 获取所有聚合结果
Filters
aggregation
=
searchResponse
.
getAggregations
().
get
(
"equipmentCount"
);
Filters
aggregation
=
searchResponse
.
getAggregations
().
get
(
"equipmentCount"
);
return
getStringObjectMap
(
regionModel
,
aggregation
);
List
<
Map
<
String
,
Object
>>
equipInsuranceMap
=
this
.
baseMapper
.
getEquipInsuranceTotal
(
orgCode
);
return
getStringObjectMap
(
regionModel
,
aggregation
,
equipInsuranceMap
);
}
catch
(
IOException
e
)
{
}
catch
(
IOException
e
)
{
e
.
printStackTrace
();
e
.
printStackTrace
();
}
}
return
Collections
.
emptyMap
();
return
Collections
.
emptyMap
();
}
}
private
static
Map
<
String
,
Object
>
getStringObjectMap
(
RegionModel
regionModel
,
Filters
aggregation
)
{
private
static
Map
<
String
,
Object
>
getStringObjectMap
(
RegionModel
regionModel
,
Filters
aggregation
,
List
<
Map
<
String
,
Object
>>
equipInsuranceMap
)
{
long
elevatorCount
=
0
;
long
elevatorCount
=
0
;
long
gasCylinderCount
=
0
;
long
cylinderCount
=
0
;
BigDecimal
elevatorInsuranceRate
;
BigDecimal
cylinderInsuranceRate
;
// 遍历 bucket 获取电梯和气瓶的总数
for
(
Filters
.
Bucket
bucket
:
aggregation
.
getBuckets
())
{
for
(
Filters
.
Bucket
bucket
:
aggregation
.
getBuckets
())
{
String
key
=
bucket
.
getKeyAsString
();
String
key
=
bucket
.
getKeyAsString
();
long
docCount
=
bucket
.
getDocCount
();
long
docCount
=
bucket
.
getDocCount
();
if
(
"电梯"
.
equals
(
key
))
{
if
(
"电梯"
.
equals
(
key
))
{
elevatorCount
=
docCount
;
elevatorCount
=
docCount
;
}
else
if
(
"气瓶"
.
equals
(
key
))
{
}
else
if
(
"气瓶"
.
equals
(
key
))
{
gasC
ylinderCount
=
docCount
;
c
ylinderCount
=
docCount
;
}
}
}
}
// 将Long类型的值转换为BigDecimal
BigDecimal
cylinderInsuranceCount
=
BigDecimal
.
valueOf
((
Long
)
equipInsuranceMap
.
get
(
0
).
get
(
CYLINDER_INSURANCE_COUNT
));
BigDecimal
elevatorInsuranceCount
=
BigDecimal
.
valueOf
((
Long
)
equipInsuranceMap
.
get
(
0
).
get
(
ELEVATOR_INSURANCE_COUNT
));
// 计算保险覆盖率,避免除以零的情况
elevatorInsuranceRate
=
elevatorCount
==
0
?
BigDecimal
.
ZERO
:
elevatorInsuranceCount
.
divide
(
BigDecimal
.
valueOf
(
elevatorCount
),
2
,
RoundingMode
.
HALF_UP
);
cylinderInsuranceRate
=
cylinderCount
==
0
?
BigDecimal
.
ZERO
:
cylinderInsuranceCount
.
divide
(
BigDecimal
.
valueOf
(
cylinderCount
),
2
,
RoundingMode
.
HALF_UP
);
// 构建结果Map
Map
<
String
,
Object
>
resultMap
=
new
HashMap
<>();
Map
<
String
,
Object
>
resultMap
=
new
HashMap
<>();
resultMap
.
put
(
REGION_CODE
,
regionModel
.
getRegionCode
());
resultMap
.
put
(
REGION_CODE
,
regionModel
.
getRegionCode
());
resultMap
.
put
(
"REGION_NAME"
,
regionModel
.
getRegionName
());
resultMap
.
put
(
REGION_NAME
,
regionModel
.
getRegionName
());
resultMap
.
put
(
"ELEVATOR"
,
elevatorCount
);
resultMap
.
put
(
ELEVATOR
,
elevatorCount
);
resultMap
.
put
(
"CYLINDER"
,
gasCylinderCount
);
resultMap
.
put
(
CYLINDER
,
cylinderCount
);
resultMap
.
put
(
ELEVATOR_INSURANCE_RATE
,
elevatorInsuranceRate
);
resultMap
.
put
(
CYLINDER_INSURANCE_RATE
,
cylinderInsuranceRate
);
return
resultMap
;
return
resultMap
;
}
}
private
static
Map
<
String
,
Object
>
assemblingHistogramData
(
List
<
Map
<
String
,
Object
>>
esQueryResults
,
List
<
Map
<
String
,
Object
>>
insuranceResults
)
{
private
static
Map
<
String
,
Object
>
assemblingHistogramData
(
List
<
Map
<
String
,
Object
>>
esQueryResults
)
{
// 组装数据
// 组装数据
Map
<
String
,
Object
>
result
=
new
HashMap
<>();
Map
<
String
,
Object
>
result
=
new
HashMap
<>();
List
<
Map
<
String
,
Object
>>
seriesData
=
new
ArrayList
<>();
List
<
Map
<
String
,
Object
>>
barSeriesData
=
new
ArrayList
<>();
List
<
Map
<
String
,
Object
>>
lineSeriesData
=
new
ArrayList
<>();
List
<
String
>
axisData
=
new
ArrayList
<>();
List
<
String
>
axisData
=
new
ArrayList
<>();
List
<
String
>
cylinderDataList
=
new
ArrayList
<>();
List
<
String
>
cylinderDataList
=
new
ArrayList
<>();
List
<
String
>
elevatorDataList
=
new
ArrayList
<>();
List
<
String
>
elevatorDataList
=
new
ArrayList
<>();
List
<
String
>
cylinderDataListRate
=
new
ArrayList
<>();
List
<
String
>
cylinderDataListRate
=
new
ArrayList
<>();
List
<
String
>
elevatorDataListRate
=
new
ArrayList
<>();
List
<
String
>
elevatorDataListRate
=
new
ArrayList
<>();
esQueryResults
.
forEach
(
x
->
{
esQueryResults
.
forEach
(
x
->
{
axisData
.
add
(
String
.
valueOf
(
x
.
get
(
"regionName"
)));
axisData
.
add
(
String
.
valueOf
(
x
.
get
(
REGION_NAME
)));
cylinderDataList
.
add
(
String
.
valueOf
(
x
.
get
(
"CYLINDER"
)));
cylinderDataList
.
add
(
String
.
valueOf
(
x
.
get
(
CYLINDER
)));
elevatorDataList
.
add
(
String
.
valueOf
(
x
.
get
(
"ELEVATOR"
)));
elevatorDataList
.
add
(
String
.
valueOf
(
x
.
get
(
ELEVATOR
)));
elevatorDataListRate
.
add
(
String
.
valueOf
(
x
.
get
(
ELEVATOR_INSURANCE_RATE
)));
cylinderDataListRate
.
add
(
String
.
valueOf
(
x
.
get
(
CYLINDER_INSURANCE_RATE
)));
});
});
HashMap
<
String
,
Object
>
temMap1
=
new
HashMap
<>();
HashMap
<
String
,
Object
>
temMap1
=
new
HashMap
<>();
temMap1
.
put
(
"data"
,
elevatorDataList
);
temMap1
.
put
(
"data"
,
elevatorDataList
);
temMap1
.
put
(
"name"
,
"电梯"
);
temMap1
.
put
(
"name"
,
"电梯"
);
temMap1
.
put
(
"type"
,
"bar"
);
HashMap
<
String
,
Object
>
temMap2
=
new
HashMap
<>();
HashMap
<
String
,
Object
>
temMap2
=
new
HashMap
<>();
temMap1
.
put
(
"data"
,
cylinderDataList
);
temMap2
.
put
(
"data"
,
cylinderDataList
);
temMap1
.
put
(
"name"
,
"气瓶"
);
temMap2
.
put
(
"name"
,
"气瓶"
);
temMap2
.
put
(
"type"
,
"bar"
);
HashMap
<
String
,
Object
>
temMap3
=
new
HashMap
<>();
HashMap
<
String
,
Object
>
temMap3
=
new
HashMap
<>();
temMap1
.
put
(
"data"
,
elevatorDataListRate
);
temMap3
.
put
(
"data"
,
elevatorDataListRate
);
temMap1
.
put
(
"name"
,
"电梯覆盖率"
);
temMap3
.
put
(
"name"
,
"电梯覆盖率"
);
temMap3
.
put
(
"type"
,
"line"
);
HashMap
<
String
,
Object
>
temMap4
=
new
HashMap
<>();
HashMap
<
String
,
Object
>
temMap4
=
new
HashMap
<>();
temMap
2
.
put
(
"data"
,
cylinderDataListRate
);
temMap
4
.
put
(
"data"
,
cylinderDataListRate
);
temMap
2
.
put
(
"name"
,
"气瓶覆盖率"
);
temMap
4
.
put
(
"name"
,
"气瓶覆盖率"
);
seriesData
.
add
(
temMap1
);
temMap4
.
put
(
"type"
,
"line"
);
seriesData
.
add
(
temMap2
);
barSeriesData
.
add
(
temMap1
);
seriesData
.
add
(
temMap3
);
barSeriesData
.
add
(
temMap2
);
seriesData
.
add
(
temMap4
);
lineSeriesData
.
add
(
temMap3
);
result
.
put
(
"seriesData"
,
seriesData
);
lineSeriesData
.
add
(
temMap4
);
result
.
put
(
"axisData"
,
axisData
);
result
.
put
(
"axisData"
,
axisData
);
result
.
put
(
"barSeriesData"
,
barSeriesData
);
result
.
put
(
"lineSeriesData"
,
lineSeriesData
);
return
result
;
return
result
;
}
}
}
}
\ No newline at end of file
amos-boot-system-tzs/amos-boot-module-jg/amos-boot-module-jg-biz/src/main/java/com/yeejoin/amos/boot/module/jg/biz/service/impl/JgUseRegistrationServiceImpl.java
View file @
dae2ba70
...
@@ -2586,6 +2586,7 @@ public class JgUseRegistrationServiceImpl extends BaseService<JgUseRegistrationD
...
@@ -2586,6 +2586,7 @@ public class JgUseRegistrationServiceImpl extends BaseService<JgUseRegistrationD
private
void
invalidUseRegistrationCertificate
(
JgUseRegistration
jgUseRegistration
)
{
private
void
invalidUseRegistrationCertificate
(
JgUseRegistration
jgUseRegistration
)
{
Integer
count
=
jgUseRegistrationMapper
.
selectCount
(
new
LambdaQueryWrapper
<
JgUseRegistration
>()
Integer
count
=
jgUseRegistrationMapper
.
selectCount
(
new
LambdaQueryWrapper
<
JgUseRegistration
>()
.
eq
(
JgUseRegistration:
:
getUseRegistrationCode
,
jgUseRegistration
.
getUseRegistrationCode
())
.
eq
(
JgUseRegistration:
:
getUseRegistrationCode
,
jgUseRegistration
.
getUseRegistrationCode
())
.
ne
(
JgUseRegistration:
:
getStatus
,
"已作废"
)
.
eq
(
JgUseRegistration:
:
getIsDelete
,
false
));
.
eq
(
JgUseRegistration:
:
getIsDelete
,
false
));
// 一证对应多条使用登记单时,不作废证
// 一证对应多条使用登记单时,不作废证
if
(
count
>
1
)
{
if
(
count
>
1
)
{
...
...
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/JgVehicleInformationServiceImpl.java
View file @
dae2ba70
...
@@ -1414,7 +1414,9 @@ public class JgVehicleInformationServiceImpl extends BaseService<JgVehicleInform
...
@@ -1414,7 +1414,9 @@ public class JgVehicleInformationServiceImpl extends BaseService<JgVehicleInform
*/
*/
private
void
invalidUseRegistrationCertificate
(
JgVehicleInformation
jgVehicleInformation
)
{
private
void
invalidUseRegistrationCertificate
(
JgVehicleInformation
jgVehicleInformation
)
{
Integer
count
=
this
.
baseMapper
.
selectCount
(
new
LambdaQueryWrapper
<
JgVehicleInformation
>()
Integer
count
=
this
.
baseMapper
.
selectCount
(
new
LambdaQueryWrapper
<
JgVehicleInformation
>()
.
eq
(
JgVehicleInformation:
:
getUseRegistrationCode
,
jgVehicleInformation
.
getUseRegistrationCode
()));
.
eq
(
JgVehicleInformation:
:
getUseRegistrationCode
,
jgVehicleInformation
.
getUseRegistrationCode
())
.
ne
(
JgVehicleInformation:
:
getStatus
,
"已作废"
)
.
eq
(
JgVehicleInformation:
:
getIsDelete
,
false
));
// 一证对应多条使用登记单时,不作废证
// 一证对应多条使用登记单时,不作废证
if
(
count
>
1
)
{
if
(
count
>
1
)
{
return
;
return
;
...
...
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