Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Sign in / Register
Toggle navigation
H
hzsomms
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
ZTGK
hzsomms
Commits
fe473b97
Commit
fe473b97
authored
Sep 20, 2023
by
hkl
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat:1.pc端维修记录调整
parent
06942fdb
Changes
14
Show whitespace changes
Inline
Side-by-side
Showing
14 changed files
with
583 additions
and
958 deletions
+583
-958
CodeGenerate.java
...em/src/main/java/org/jeecg/codegenerate/CodeGenerate.java
+2
-2
RailWearRecordMapper.xml
...ecg/modules/checkData/mapper/xml/RailWearRecordMapper.xml
+0
-2
AnalysisAlgorithm.java
...es/dynamicStaticAnalysis/algorithm/AnalysisAlgorithm.java
+348
-436
ConfigTqiLimitController.java
...icStaticAnalysis/controller/ConfigTqiLimitController.java
+52
-0
ConfigTqiLimit.java
.../modules/dynamicStaticAnalysis/entity/ConfigTqiLimit.java
+91
-0
ConfigTqiLimitMapper.java
...es/dynamicStaticAnalysis/mapper/ConfigTqiLimitMapper.java
+16
-0
ConfigTqiLimitMapper.xml
...dynamicStaticAnalysis/mapper/xml/ConfigTqiLimitMapper.xml
+5
-0
AnalysisBatchUnitDeviceTqiScoreDTO.java
...ticAnalysis/other/AnalysisBatchUnitDeviceTqiScoreDTO.java
+0
-158
AnalysisBatchUnitDeviceTqiScoreVO.java
...aticAnalysis/other/AnalysisBatchUnitDeviceTqiScoreVO.java
+0
-200
AnalysisBatchUnitDeviceWorkDTO.java
...cStaticAnalysis/other/AnalysisBatchUnitDeviceWorkDTO.java
+0
-73
AnalysisBatchUnitDeviceWorkVO.java
...icStaticAnalysis/other/AnalysisBatchUnitDeviceWorkVO.java
+0
-87
IConfigTqiLimitService.java
...dynamicStaticAnalysis/service/IConfigTqiLimitService.java
+16
-0
ConfigTqiLimitServiceImpl.java
...taticAnalysis/service/impl/ConfigTqiLimitServiceImpl.java
+26
-0
ConfigTqiLimitVO.java
...cg/modules/dynamicStaticAnalysis/vo/ConfigTqiLimitVO.java
+27
-0
No files found.
jeecg-module-system/src/main/java/org/jeecg/codegenerate/CodeGenerate.java
View file @
fe473b97
...
...
@@ -25,11 +25,11 @@ public class CodeGenerate {
String
outputDir
=
projectPath
+
"\\jeecg-module-system\\src\\main\\java\\"
;
// 模块名
String
moduleName
=
"
maintenanceWork
"
;
String
moduleName
=
"
dynamicStaticAnalysis
"
;
// 表名
String
[]
tables
=
{
"t_
mw_work_batch_detail_modify
"
,
"t_
dsa_config_tqi_limit
"
,
};
...
...
jeecg-module-system/src/main/java/org/jeecg/modules/checkData/mapper/xml/RailWearRecordMapper.xml
View file @
fe473b97
...
...
@@ -25,7 +25,6 @@
FROM
t_ek_rail_wear_record t1
LEFT JOIN t_ek_records_master_check t2 ON t1.records_master_check_id = t2.id and t2.del_flag = '0'
left join t_sn_light_rail t3 on t2.light_rail_id = t3.id
WHERE t1.del_flag = '0'
<if
test=
"dto.ekCode != null and dto.ekCode != ''"
>
AND t2.ek_code like concat('%',#{dto.ekCode},'%')
...
...
@@ -36,7 +35,6 @@
<if
test=
"dto.endTime != null"
>
AND t2.check_time
<![CDATA[ <= ]]>
#{dto.endTime}
</if>
AND t3.status = 1
</select>
<select
id=
"getDetail"
resultType=
"org.jeecg.modules.checkData.vo.RailWearRecordDetailVO"
>
...
...
jeecg-module-system/src/main/java/org/jeecg/modules/dynamicStaticAnalysis/algorithm/AnalysisAlgorithm.java
View file @
fe473b97
...
...
@@ -81,6 +81,9 @@ public class AnalysisAlgorithm {
@Resource
private
IMovementAdditiveInfoUnitDeviceMapService
movementAdditiveInfoUnitDeviceMapService
;
public
AnalysisAlgorithm
()
{
}
public
void
analysis
(
String
analysisBatchId
)
{
Map
<
String
,
Map
<
String
,
Object
>>
unitDeviceTable
=
new
LinkedHashMap
<>();
...
...
@@ -699,92 +702,21 @@ public class AnalysisAlgorithm {
}
}
/**
* 轨检车检查数据解析
*/
private
void
railVehicleCheckDataAnalysis
(
AnalysisBatch
analysisBatch
,
AnalysisBatchCheckDataMap
checkDataMap
,
List
<
Map
<
String
,
Object
>>
unitDeviceList
)
{
// 1.获取轨检车相关数据
// 1.1 获取缺陷报告
List
<
MovementOverReport
>
movementOverReports
=
movementOverReportService
.
lambdaQuery
().
eq
(
MovementOverReport:
:
getMovementMasterId
,
checkDataMap
.
getEkId
()).
ge
(
MovementOverReport:
:
getMileage
,
analysisBatch
.
getStartingMileage
()).
le
(
MovementOverReport:
:
getMileage
,
analysisBatch
.
getEndMileage
()).
orderByAsc
(
MovementOverReport:
:
getMileage
).
list
();
Map
<
BigDecimal
,
List
<
MovementOverReport
>>
movementOverReportMap
=
new
HashMap
<>();
for
(
MovementOverReport
movementOverReport
:
movementOverReports
)
{
List
<
MovementOverReport
>
list
=
movementOverReportMap
.
get
(
movementOverReport
.
getMileage
());
if
(
ObjectUtil
.
isEmpty
(
list
))
{
list
=
new
ArrayList
<>();
movementOverReportMap
.
put
(
movementOverReport
.
getMileage
(),
list
);
}
list
.
add
(
movementOverReport
);
}
// 1.2 获取tqi数据
List
<
MovementTqiReport
>
tqiReports
=
movementTqiReportService
.
lambdaQuery
().
eq
(
MovementTqiReport:
:
getMovementMasterId
,
checkDataMap
.
getEkId
()).
ge
(
MovementTqiReport:
:
getStartMileage
,
analysisBatch
.
getStartingMileage
()).
le
(
MovementTqiReport:
:
getEndMileage
,
analysisBatch
.
getEndMileage
()).
orderByAsc
(
MovementTqiReport:
:
getStartMileage
).
list
();
// 1.3 获取是否派工配置
// 轨检车动态检查数据-1级超限
Integer
isWorkRailVehicleOver1
=
1
;
String
reasonLabelRailVehicleOver1
=
""
;
// 轨检车动态检查数据-2级超限
Integer
isWorkRailVehicleOver2
=
1
;
String
reasonLabelRailVehicleOver2
=
""
;
// 轨检车动态检查数据-3级超限
Integer
isWorkRailVehicleOver3
=
1
;
String
reasonLabelRailVehicleOver3
=
""
;
// 轨检车动态检查数据-4级超限
Integer
isWorkRailVehicleOver4
=
1
;
String
reasonLabelRailVehicleOver4
=
""
;
// 1.3 派工设置
JSONArray
dispatchingList
=
JSONArray
.
parseArray
(
analysisBatch
.
getDispatching
());
for
(
Object
obj
:
dispatchingList
)
{
JSONObject
dispatching
=
(
JSONObject
)
obj
;
String
reasonValue
=
String
.
valueOf
(
dispatching
.
get
(
"reasonValue"
));
String
reasonLabel
=
String
.
valueOf
(
dispatching
.
get
(
"reasonLabel"
));
if
(
"rail_vehicle_over_1"
.
equals
(
reasonValue
))
{
Boolean
isWorkTemp
=
Boolean
.
valueOf
(
dispatching
.
get
(
"isWork"
).
toString
());
if
(
isWorkTemp
)
{
isWorkRailVehicleOver1
=
1
;
reasonLabelRailVehicleOver1
=
reasonLabel
;
}
else
{
isWorkRailVehicleOver1
=
0
;
}
}
if
(
"rail_vehicle_over_2"
.
equals
(
reasonValue
))
{
Boolean
isWorkTemp
=
Boolean
.
valueOf
(
dispatching
.
get
(
"isWork"
).
toString
());
if
(
isWorkTemp
)
{
isWorkRailVehicleOver2
=
1
;
reasonLabelRailVehicleOver2
=
reasonLabel
;
}
else
{
isWorkRailVehicleOver2
=
0
;
}
}
if
(
"rail_vehicle_over_3"
.
equals
(
reasonValue
))
{
Boolean
isWorkTemp
=
Boolean
.
valueOf
(
dispatching
.
get
(
"isWork"
).
toString
());
if
(
isWorkTemp
)
{
isWorkRailVehicleOver3
=
1
;
reasonLabelRailVehicleOver3
=
reasonLabel
;
}
else
{
isWorkRailVehicleOver3
=
0
;
}
}
if
(
"rail_vehicle_over_4"
.
equals
(
reasonValue
))
{
Boolean
isWorkTemp
=
Boolean
.
valueOf
(
dispatching
.
get
(
"isWork"
).
toString
());
if
(
isWorkTemp
)
{
isWorkRailVehicleOver4
=
1
;
reasonLabelRailVehicleOver4
=
reasonLabel
;
}
else
{
isWorkRailVehicleOver4
=
0
;
}
}
}
// 1.4 获取轨检车检查超限权值
ConfigRailVehicleCheck
configRailVehicle
=
configRailVehicleCheckService
.
lambdaQuery
().
eq
(
ConfigRailVehicleCheck:
:
getSpeedMax
,
analysisBatch
.
getSpeedMax
()).
eq
(
ConfigRailVehicleCheck:
:
getSpeedMin
,
analysisBatch
.
getSpeedMin
()).
eq
(
ConfigRailVehicleCheck:
:
getDelFlag
,
"0"
).
last
(
"limit 1"
).
one
();
// 1-钢轨,2-曲线,3-竖曲线,4-道岔
...
...
@@ -793,10 +725,8 @@ public class AnalysisAlgorithm {
JSONObject
verticalCurveWeightValueJsonObject
=
JSONObject
.
parseObject
(
configRailVehicle
.
getVerticalCurve
());
JSONObject
switchWeightValueJsonObject
=
JSONObject
.
parseObject
(
configRailVehicle
.
getRailSwitch
());
// 1.5 获取轨检车TQI超限权值
// 1.5 获取轨检车TQI权值
ConfigRailVehicleTqi
configRailVehicleTqi
=
configRailVehicleTqlService
.
lambdaQuery
().
eq
(
ConfigRailVehicleTqi:
:
getSpeedMax
,
analysisBatch
.
getSpeedMax
()).
eq
(
ConfigRailVehicleTqi:
:
getSpeedMin
,
analysisBatch
.
getSpeedMin
()).
eq
(
ConfigRailVehicleTqi:
:
getDelFlag
,
"0"
).
last
(
"limit 1"
).
one
();
// 1-钢轨,2-曲线,3-竖曲线,4-道岔
JSONObject
railTqiJsonObject
=
JSONObject
.
parseObject
(
configRailVehicleTqi
.
getRail
());
JSONObject
curveTqiJsonObject
=
JSONObject
.
parseObject
(
configRailVehicleTqi
.
getCurve
());
...
...
@@ -804,84 +734,34 @@ public class AnalysisAlgorithm {
JSONObject
switchTqiJsonObject
=
JSONObject
.
parseObject
(
configRailVehicleTqi
.
getRailSwitch
());
// 2. 根据分析批次的里程查询出映射单元
// 1.6 获取轨检车TQI阀值
// config
// 2.根据分析批次的里程查询出映射单元
List
<
MovementOverReportUnitDeviceMap
>
overReportUnitDeviceMaps
=
new
ArrayList
<>();
List
<
MovementTqiReportUnitDeviceMap
>
movementTqiReportUnitDeviceMaps
=
new
ArrayList
<>();
for
(
Map
<
String
,
Object
>
unitDevice
:
unitDeviceList
)
{
// 1-钢轨,2-曲线,3-竖曲线,4-道岔
Integer
type
=
Convert
.
toInt
(
unitDevice
.
get
(
"type"
));
JSONObject
weightValuesjsonObject
=
null
;
if
(
type
==
1
)
{
weightValuesjsonObject
=
railWeightValueJsonObject
;
}
else
if
(
type
==
2
)
{
weightValuesjsonObject
=
curveWeightValueJsonObject
;
}
else
if
(
type
==
3
)
{
weightValuesjsonObject
=
verticalCurveWeightValueJsonObject
;
}
else
if
(
type
==
4
)
{
weightValuesjsonObject
=
switchWeightValueJsonObject
;
}
BigDecimal
trackGaugeWeightValues
=
weightValuesjsonObject
.
getBigDecimal
(
"trackGauge"
);
BigDecimal
directionWeightValues
=
weightValuesjsonObject
.
getBigDecimal
(
"direction"
);
BigDecimal
triangularPitWeightValues
=
weightValuesjsonObject
.
getBigDecimal
(
"triangularPit"
);
BigDecimal
heightWeightValues
=
weightValuesjsonObject
.
getBigDecimal
(
"height"
);
BigDecimal
levelWeightValues
=
weightValuesjsonObject
.
getBigDecimal
(
"level"
);
JSONObject
tqiJsonObject
=
null
;
if
(
type
==
1
)
{
tqiJsonObject
=
railTqiJsonObject
;
}
else
if
(
type
==
2
)
{
tqiJsonObject
=
curveTqiJsonObject
;
}
else
if
(
type
==
3
)
{
tqiJsonObject
=
verticalCurveTqiJsonObject
;
}
else
if
(
type
==
4
)
{
tqiJsonObject
=
switchTqiJsonObject
;
}
BigDecimal
trackGaugeTqi
=
tqiJsonObject
.
getBigDecimal
(
"trackGauge"
);
BigDecimal
directionTqi
=
tqiJsonObject
.
getBigDecimal
(
"direction"
);
BigDecimal
triangularPitTqi
=
tqiJsonObject
.
getBigDecimal
(
"triangularPit"
);
BigDecimal
heightTqi
=
tqiJsonObject
.
getBigDecimal
(
"height"
);
BigDecimal
levelTqi
=
tqiJsonObject
.
getBigDecimal
(
"level"
);
BigDecimal
tqiComeUponTqi
=
tqiJsonObject
.
getBigDecimal
(
"tqi"
);
List
<
AnalysisBatchUnitDeviceTransfinite
>
railVehicleTransfiniteList
=
new
ArrayList
<>();
BigDecimal
startMileage
=
Convert
.
toBigDecimal
(
unitDevice
.
get
(
"startMileage"
));
BigDecimal
centerMileage
=
Convert
.
toBigDecimal
(
unitDevice
.
get
(
"centerMileage"
));
BigDecimal
endMileage
=
Convert
.
toBigDecimal
(
unitDevice
.
get
(
"endMileage"
));
BigDecimal
sumUnitScore
=
null
;
List
<
AnalysisBatchUnitDevicePointScore
>
scoreList
=
new
ArrayList
<>();
List
<
MovementOverReport
>
currentUnitDeviceOverReportList
=
new
ArrayList
<>();
// 2.1 缺陷记录报告表里程落在单元设备【开始-结束】这个设备上面,视为这个区间的超限记录
List
<
AnalysisBatchUnitDeviceTransfinite
>
railVehicleTransfiniteList
=
new
ArrayList
<>();
for
(
MovementOverReport
movementOverReport
:
movementOverReports
)
{
// 说明超限
if
(
startMileage
.
compareTo
(
movementOverReport
.
getMileage
())
<=
0
&&
endMileage
.
compareTo
(
movementOverReport
.
getMileage
())
>
0
)
{
Integer
transfiniteGrade
=
Convert
.
toInt
(
movementOverReport
.
getOverrunLevel
());
// 超限
AnalysisBatchUnitDeviceTransfinite
transfinite
=
new
AnalysisBatchUnitDeviceTransfinite
();
transfinite
.
setId
(
UUIDGenerator
.
generate
());
transfinite
.
setTransfiniteGrade
(
transfiniteGrade
);
transfinite
.
setTransfiniteType
(
movementOverReport
.
getOverrunType
());
if
(
1
==
transfiniteGrade
)
{
transfinite
.
setTransfiniteGradeName
(
reasonLabelRailVehicleOver1
);
transfinite
.
setIsWork
(
isWorkRailVehicleOver1
);
}
else
if
(
2
==
transfiniteGrade
)
{
transfinite
.
setTransfiniteGradeName
(
reasonLabelRailVehicleOver2
);
transfinite
.
setIsWork
(
isWorkRailVehicleOver2
);
}
else
if
(
3
==
transfiniteGrade
)
{
transfinite
.
setTransfiniteGradeName
(
reasonLabelRailVehicleOver3
);
transfinite
.
setIsWork
(
isWorkRailVehicleOver3
);
}
else
{
transfinite
.
setTransfiniteGradeName
(
reasonLabelRailVehicleOver4
);
transfinite
.
setIsWork
(
isWorkRailVehicleOver4
);
}
String
allowValue
=
Convert
.
toBigDecimal
(
movementOverReport
.
getPeakValue
()).
subtract
(
Convert
.
toBigDecimal
(
movementOverReport
.
getDataDifference
())).
toString
();
transfinite
.
setAllowValue
(
allowValue
);
transfinite
.
setEkId
(
movementOverReport
.
getMovementMasterId
());
transfinite
.
setEkType
(
3
);
transfinite
.
setEkItemId
(
movementOverReport
.
getId
());
transfinite
.
setMeasurePointValue
(
movementOverReport
.
getPeakValue
());
// 轨检车超限等级
AnalysisBatchUnitDeviceTransfinite
transfinite
=
this
.
createRailVehicleCheckTransfinite
(
dispatchingList
,
movementOverReport
);
if
(
ObjectUtil
.
isNotEmpty
(
transfinite
))
{
railVehicleTransfiniteList
.
add
(
transfinite
);
}
// 保存超限和设备关联关系
...
...
@@ -907,17 +787,129 @@ public class AnalysisAlgorithm {
overReportUnitDeviceMap
.
setStandard
(
movementOverReport
.
getStandard
());
overReportUnitDeviceMap
.
setSpend
(
movementOverReport
.
getSpend
());
overReportUnitDeviceMaps
.
add
(
overReportUnitDeviceMap
);
currentUnitDeviceOverReportList
.
add
(
movementOverReport
);
}
}
unitDevice
.
put
(
"railVehicleTransfiniteList"
,
railVehicleTransfiniteList
);
// 2.2 单元设备中心里程落在tqi【开始-结束】这个区间视为这个区间的单元设备
// 统计单元得分
// 统计tqi得分
BigDecimal
sumUnitScore
=
BigDecimal
.
ZERO
;
List
<
AnalysisBatchUnitDevicePointScore
>
scoreList
=
new
ArrayList
<>();
int
analysisType
=
analysisBatch
.
getAnalysisType
();
// 2.2 计算单元超限得分
Integer
type
=
Convert
.
toInt
(
unitDevice
.
get
(
"type"
));
JSONObject
weightValuejsonObject
=
null
;
if
(
type
==
1
)
{
weightValuejsonObject
=
railWeightValueJsonObject
;
}
else
if
(
type
==
2
)
{
weightValuejsonObject
=
curveWeightValueJsonObject
;
}
else
if
(
type
==
3
)
{
weightValuejsonObject
=
verticalCurveWeightValueJsonObject
;
}
else
if
(
type
==
4
)
{
weightValuejsonObject
=
switchWeightValueJsonObject
;
}
BigDecimal
heightWeightValue
=
weightValuejsonObject
.
getBigDecimal
(
"height"
);
BigDecimal
directionWeightValue
=
weightValuejsonObject
.
getBigDecimal
(
"direction"
);
BigDecimal
levelWeightValue
=
weightValuejsonObject
.
getBigDecimal
(
"level"
);
BigDecimal
trackGaugeWeightValue
=
weightValuejsonObject
.
getBigDecimal
(
"trackGauge"
);
BigDecimal
triangularPitWeightValue
=
weightValuejsonObject
.
getBigDecimal
(
"triangularPit"
);
BigDecimal
gaugeChangeWeightValue
=
weightValuejsonObject
.
getBigDecimal
(
"gaugeChange"
);
// 高低得分
AnalysisBatchUnitDevicePointScore
heightPointScore
=
this
.
createRailVehicleCheckTransfinitePointScore
(
analysisBatch
,
currentUnitDeviceOverReportList
,
"高低"
,
heightWeightValue
);
if
(
ObjectUtil
.
isNotEmpty
(
heightPointScore
))
{
sumUnitScore
=
sumUnitScore
!=
null
?
sumUnitScore
.
add
(
heightPointScore
.
getPointScore
())
:
heightPointScore
.
getPointScore
();
scoreList
.
add
(
heightPointScore
);
}
// 轨向得分
AnalysisBatchUnitDevicePointScore
directionPointScore
=
this
.
createRailVehicleCheckTransfinitePointScore
(
analysisBatch
,
currentUnitDeviceOverReportList
,
"轨向"
,
directionWeightValue
);
if
(
ObjectUtil
.
isNotEmpty
(
directionPointScore
))
{
sumUnitScore
=
sumUnitScore
!=
null
?
sumUnitScore
.
add
(
directionPointScore
.
getPointScore
())
:
directionPointScore
.
getPointScore
();
scoreList
.
add
(
directionPointScore
);
}
// 水平得分
AnalysisBatchUnitDevicePointScore
levelPointScore
=
this
.
createRailVehicleCheckTransfinitePointScore
(
analysisBatch
,
currentUnitDeviceOverReportList
,
"水平"
,
levelWeightValue
);
if
(
ObjectUtil
.
isNotEmpty
(
levelPointScore
))
{
sumUnitScore
=
sumUnitScore
!=
null
?
sumUnitScore
.
add
(
levelPointScore
.
getPointScore
())
:
levelPointScore
.
getPointScore
();
scoreList
.
add
(
levelPointScore
);
}
// 轨距得分
AnalysisBatchUnitDevicePointScore
trackGaugePointScore
=
this
.
createRailVehicleCheckTransfinitePointScore
(
analysisBatch
,
currentUnitDeviceOverReportList
,
"轨距"
,
trackGaugeWeightValue
);
if
(
ObjectUtil
.
isNotEmpty
(
trackGaugePointScore
))
{
sumUnitScore
=
sumUnitScore
!=
null
?
sumUnitScore
.
add
(
trackGaugePointScore
.
getPointScore
())
:
trackGaugePointScore
.
getPointScore
();
scoreList
.
add
(
trackGaugePointScore
);
}
// 三角坑得分
AnalysisBatchUnitDevicePointScore
triangularPitPointScore
=
this
.
createRailVehicleCheckTransfinitePointScore
(
analysisBatch
,
currentUnitDeviceOverReportList
,
"三角坑"
,
triangularPitWeightValue
);
if
(
ObjectUtil
.
isNotEmpty
(
triangularPitPointScore
))
{
sumUnitScore
=
sumUnitScore
!=
null
?
sumUnitScore
.
add
(
triangularPitPointScore
.
getPointScore
())
:
triangularPitPointScore
.
getPointScore
();
scoreList
.
add
(
triangularPitPointScore
);
}
// 轨距变化率得分
AnalysisBatchUnitDevicePointScore
gaugeChangePitPointScore
=
this
.
createRailVehicleCheckTransfinitePointScore
(
analysisBatch
,
currentUnitDeviceOverReportList
,
"轨距变化率"
,
gaugeChangeWeightValue
);
if
(
ObjectUtil
.
isNotEmpty
(
gaugeChangePitPointScore
))
{
sumUnitScore
=
sumUnitScore
!=
null
?
sumUnitScore
.
add
(
gaugeChangePitPointScore
.
getPointScore
())
:
gaugeChangePitPointScore
.
getPointScore
();
scoreList
.
add
(
gaugeChangePitPointScore
);
}
// 2.3 处理tqi数
// 2.3.1 tqi权值
// 1-钢轨,2-曲线,3-竖曲线,4-道岔
JSONObject
tqiJsonObject
=
null
;
if
(
type
==
1
)
{
tqiJsonObject
=
railTqiJsonObject
;
}
else
if
(
type
==
2
)
{
tqiJsonObject
=
curveTqiJsonObject
;
}
else
if
(
type
==
3
)
{
tqiJsonObject
=
verticalCurveTqiJsonObject
;
}
else
if
(
type
==
4
)
{
tqiJsonObject
=
switchTqiJsonObject
;
}
BigDecimal
heightTqi
=
tqiJsonObject
.
getBigDecimal
(
"height"
);
BigDecimal
directionTqi
=
tqiJsonObject
.
getBigDecimal
(
"direction"
);
BigDecimal
trackGaugeTqi
=
tqiJsonObject
.
getBigDecimal
(
"trackGauge"
);
BigDecimal
triangularPitTqi
=
tqiJsonObject
.
getBigDecimal
(
"triangularPit"
);
BigDecimal
levelTqi
=
tqiJsonObject
.
getBigDecimal
(
"level"
);
BigDecimal
tqiComeUponTqi
=
tqiJsonObject
.
getBigDecimal
(
"tqi"
);
// 2.3.2 单元设备中心里程落在tqi【开始-结束】这个区间视为这个区间的单元设备
for
(
MovementTqiReport
tqiReport
:
tqiReports
)
{
// 如果命中处理测点映射关系
if
(
tqiReport
.
getStartMileage
().
compareTo
(
centerMileage
)
<=
0
&&
tqiReport
.
getEndMileage
().
compareTo
(
centerMileage
)
>
0
)
{
...
...
@@ -952,334 +944,256 @@ public class AnalysisAlgorithm {
movementTqiReportUnitDeviceMaps
.
add
(
movementTqiReportUnitDeviceMap
);
// 计算轨距得分
BigDecimal
finalTrackGauge
=
Convert
.
toBigDecimal
(
tqiReport
.
getTrackGauge
()).
abs
();
if
(
ObjectUtil
.
isNotEmpty
(
railVehicleTransfiniteList
))
{
int
trackGaugeSize
=
1
;
BigDecimal
sumTrackGauge
=
finalTrackGauge
;
for
(
AnalysisBatchUnitDeviceTransfinite
record
:
railVehicleTransfiniteList
)
{
if
(
"轨距"
.
equals
(
record
.
getTransfiniteType
()))
{
BigDecimal
trackGauge
=
Convert
.
toBigDecimal
(
record
.
getMeasurePointValue
()).
abs
();
if
(
1
==
analysisType
)
{
// 均值
sumTrackGauge
=
sumTrackGauge
.
add
(
trackGauge
);
trackGaugeSize
++;
finalTrackGauge
=
sumTrackGauge
.
divide
(
new
BigDecimal
(
trackGaugeSize
),
3
,
BigDecimal
.
ROUND_HALF_UP
);
}
else
{
// 峰值
if
(
finalTrackGauge
.
compareTo
(
trackGauge
)
<
0
)
{
finalTrackGauge
=
trackGauge
;
}
}
}
}
}
BigDecimal
trackGaugeUnitScore
=
trackGaugeWeightValues
.
multiply
(
finalTrackGauge
);
sumUnitScore
=
sumUnitScore
.
add
(
trackGaugeUnitScore
);
AnalysisBatchUnitDevicePointScore
trackGaugePointScore
=
new
AnalysisBatchUnitDevicePointScore
();
trackGaugePointScore
.
setId
(
UUIDGenerator
.
generate
());
trackGaugePointScore
.
setAnalysisType
(
analysisType
);
trackGaugePointScore
.
setSpeedMax
(
analysisBatch
.
getSpeedMax
());
trackGaugePointScore
.
setSpeedMin
(
analysisBatch
.
getSpeedMin
());
trackGaugePointScore
.
setAnalysisBatchId
(
analysisBatch
.
getId
());
trackGaugePointScore
.
setAnalysisBatchCode
(
analysisBatch
.
getAnalysisBatchCode
());
trackGaugePointScore
.
setPointTypeName
(
"轨距"
);
trackGaugePointScore
.
setCheckType
(
3
);
trackGaugePointScore
.
setPointValue
(
finalTrackGauge
);
trackGaugePointScore
.
setWeightValues
(
trackGaugeWeightValues
);
trackGaugePointScore
.
setPointScore
(
trackGaugeUnitScore
);
scoreList
.
add
(
trackGaugePointScore
);
// 计算水平得分
BigDecimal
finalLevel
=
Convert
.
toBigDecimal
(
tqiReport
.
getLevel
()).
abs
();
if
(
ObjectUtil
.
isNotEmpty
(
railVehicleTransfiniteList
))
{
int
levelSize
=
1
;
BigDecimal
sumLevel
=
finalLevel
;
for
(
AnalysisBatchUnitDeviceTransfinite
record
:
railVehicleTransfiniteList
)
{
if
(
record
.
getTransfiniteType
().
contains
(
"水平"
))
{
BigDecimal
level
=
Convert
.
toBigDecimal
(
record
.
getMeasurePointValue
()).
abs
();
if
(
1
==
analysisType
)
{
// 均值
sumLevel
=
sumLevel
.
add
(
level
);
levelSize
++;
finalLevel
=
sumLevel
.
divide
(
new
BigDecimal
(
levelSize
),
3
,
BigDecimal
.
ROUND_HALF_UP
);
}
else
{
// 峰值
if
(
finalLevel
.
compareTo
(
level
)
<
0
)
{
finalLevel
=
level
;
}
}
}
}
}
BigDecimal
levelUnitScore
=
levelWeightValues
.
multiply
(
finalLevel
);
sumUnitScore
=
sumUnitScore
.
add
(
levelUnitScore
);
AnalysisBatchUnitDevicePointScore
levelPointScore
=
new
AnalysisBatchUnitDevicePointScore
();
levelPointScore
.
setId
(
UUIDGenerator
.
generate
());
levelPointScore
.
setAnalysisType
(
analysisType
);
levelPointScore
.
setSpeedMax
(
analysisBatch
.
getSpeedMax
());
levelPointScore
.
setSpeedMin
(
analysisBatch
.
getSpeedMin
());
levelPointScore
.
setAnalysisBatchId
(
analysisBatch
.
getId
());
levelPointScore
.
setAnalysisBatchCode
(
analysisBatch
.
getAnalysisBatchCode
());
levelPointScore
.
setPointTypeName
(
"水平"
);
levelPointScore
.
setCheckType
(
3
);
levelPointScore
.
setPointValue
(
finalLevel
);
levelPointScore
.
setWeightValues
(
levelWeightValues
);
levelPointScore
.
setPointScore
(
levelUnitScore
);
scoreList
.
add
(
levelPointScore
);
// 计算三角坑得分
BigDecimal
finalTriangularPit
=
Convert
.
toBigDecimal
(
tqiReport
.
getLevel
()).
abs
();
if
(
ObjectUtil
.
isNotEmpty
(
railVehicleTransfiniteList
))
{
int
triangularPitSize
=
1
;
BigDecimal
sumTriangularPit
=
finalTriangularPit
;
for
(
AnalysisBatchUnitDeviceTransfinite
record
:
railVehicleTransfiniteList
)
{
if
(
record
.
getTransfiniteType
().
contains
(
"三角坑"
))
{
BigDecimal
level
=
Convert
.
toBigDecimal
(
record
.
getMeasurePointValue
()).
abs
();
if
(
1
==
analysisBatch
.
getAnalysisType
())
{
// 均值
sumTriangularPit
=
sumTriangularPit
.
add
(
level
);
triangularPitSize
++;
finalTriangularPit
=
sumTriangularPit
.
divide
(
new
BigDecimal
(
triangularPitSize
),
3
,
BigDecimal
.
ROUND_HALF_UP
);
}
else
{
// 峰值
if
(
finalTriangularPit
.
compareTo
(
level
)
<
0
)
{
finalTriangularPit
=
level
;
}
}
}
}
}
BigDecimal
triangularPitUnitScore
=
triangularPitWeightValues
.
multiply
(
finalTriangularPit
);
sumUnitScore
=
sumUnitScore
.
add
(
triangularPitUnitScore
);
AnalysisBatchUnitDevicePointScore
triangularPitPointScore
=
new
AnalysisBatchUnitDevicePointScore
();
triangularPitPointScore
.
setId
(
UUIDGenerator
.
generate
());
triangularPitPointScore
.
setAnalysisType
(
analysisType
);
triangularPitPointScore
.
setSpeedMax
(
analysisBatch
.
getSpeedMax
());
triangularPitPointScore
.
setSpeedMin
(
analysisBatch
.
getSpeedMin
());
triangularPitPointScore
.
setAnalysisBatchId
(
analysisBatch
.
getId
());
triangularPitPointScore
.
setAnalysisBatchCode
(
analysisBatch
.
getAnalysisBatchCode
());
triangularPitPointScore
.
setPointTypeName
(
"三角坑"
);
triangularPitPointScore
.
setCheckType
(
3
);
triangularPitPointScore
.
setPointValue
(
finalTriangularPit
);
triangularPitPointScore
.
setWeightValues
(
triangularPitWeightValues
);
triangularPitPointScore
.
setPointScore
(
triangularPitUnitScore
);
scoreList
.
add
(
triangularPitPointScore
);
// 计算分数
// 计算高低得分
BigDecimal
final
Height
=
null
;
BigDecimal
finalH
eightLowLeft
=
Convert
.
toBigDecimal
(
tqiReport
.
getHighLowLeft
()).
abs
();
BigDecimal
finalH
eightLowRight
=
Convert
.
toBigDecimal
(
tqiReport
.
getHighLowRight
()).
abs
();
BigDecimal
final
TqiHeight
;
BigDecimal
h
eightLowLeft
=
Convert
.
toBigDecimal
(
tqiReport
.
getHighLowLeft
()).
abs
();
BigDecimal
h
eightLowRight
=
Convert
.
toBigDecimal
(
tqiReport
.
getHighLowRight
()).
abs
();
if
(
1
==
analysisBatch
.
getAnalysisType
())
{
finalHeight
=
finalHeightLowLeft
.
add
(
finalHeightLowRight
).
divide
(
new
BigDecimal
(
"2"
),
3
,
BigDecimal
.
ROUND_HALF_UP
);
// 均值
finalTqiHeight
=
heightLowLeft
.
add
(
heightLowRight
).
divide
(
new
BigDecimal
(
"2"
),
3
,
BigDecimal
.
ROUND_HALF_UP
);
}
else
{
if
(
finalHeightLowLeft
.
compareTo
(
finalHeightLowRight
)
>
0
)
{
finalHeight
=
finalHeightLowLeft
;
// 峰值
if
(
heightLowLeft
.
compareTo
(
heightLowRight
)
>
0
)
{
finalTqiHeight
=
heightLowLeft
;
}
else
{
finalHeight
=
finalHeightLowRight
;
}
}
if
(
ObjectUtil
.
isNotEmpty
(
railVehicleTransfiniteList
))
{
int
heightSize
=
1
;
BigDecimal
sumHeight
=
finalHeight
;
for
(
AnalysisBatchUnitDeviceTransfinite
record
:
railVehicleTransfiniteList
)
{
if
(
record
.
getTransfiniteType
().
contains
(
"高低"
))
{
BigDecimal
level
=
Convert
.
toBigDecimal
(
record
.
getMeasurePointValue
()).
abs
();
if
(
1
==
analysisBatch
.
getAnalysisType
())
{
// 均值
sumHeight
=
sumHeight
.
add
(
level
);
heightSize
++;
finalHeight
=
sumHeight
.
divide
(
new
BigDecimal
(
heightSize
),
3
,
BigDecimal
.
ROUND_HALF_UP
);
}
else
{
// 峰值
if
(
finalHeight
.
compareTo
(
level
)
<
0
)
{
finalHeight
=
level
;
}
finalTqiHeight
=
heightLowRight
;
}
}
AnalysisBatchUnitDevicePointScore
tqiHeightPointScore
=
this
.
createRailVehicleCheckTqiPointScore
(
analysisBatch
,
finalTqiHeight
,
"高低"
,
heightTqi
);
if
(
sumUnitScore
==
null
)
{
sumUnitScore
=
tqiHeightPointScore
.
getPointScore
();
}
else
{
sumUnitScore
=
sumUnitScore
.
add
(
tqiHeightPointScore
.
getPointScore
());
}
}
BigDecimal
heightUnitScore
=
heightWeightValues
.
multiply
(
finalHeight
);
sumUnitScore
=
sumUnitScore
.
add
(
heightUnitScore
);
AnalysisBatchUnitDevicePointScore
heightPointScore
=
new
AnalysisBatchUnitDevicePointScore
();
heightPointScore
.
setId
(
UUIDGenerator
.
generate
());
heightPointScore
.
setAnalysisType
(
analysisType
);
heightPointScore
.
setSpeedMax
(
analysisBatch
.
getSpeedMax
());
heightPointScore
.
setSpeedMin
(
analysisBatch
.
getSpeedMin
());
heightPointScore
.
setAnalysisBatchId
(
analysisBatch
.
getId
());
heightPointScore
.
setAnalysisBatchCode
(
analysisBatch
.
getAnalysisBatchCode
());
heightPointScore
.
setPointTypeName
(
"高低"
);
heightPointScore
.
setCheckType
(
3
);
heightPointScore
.
setPointValue
(
finalHeight
);
heightPointScore
.
setWeightValues
(
heightWeightValues
);
heightPointScore
.
setPointScore
(
heightUnitScore
);
scoreList
.
add
(
heightPointScore
);
scoreList
.
add
(
tqiHeightPointScore
);
// 计算轨向得分
BigDecimal
finalDirection
=
null
;
BigDecimal
finalDirectionLeft
=
Convert
.
toBigDecimal
(
tqiReport
.
getTrackLeft
()).
abs
();
BigDecimal
finalDirectionRight
=
Convert
.
toBigDecimal
(
tqiReport
.
getTrackRight
()).
abs
();
if
(
1
==
analysisType
)
{
finalDirection
=
finalDirectionLeft
.
add
(
finalDirectionRight
).
divide
(
new
BigDecimal
(
"2"
),
3
,
BigDecimal
.
ROUND_HALF_UP
);
BigDecimal
finalTqiDirection
;
BigDecimal
directionLeft
=
Convert
.
toBigDecimal
(
tqiReport
.
getTrackLeft
()).
abs
();
BigDecimal
directionRight
=
Convert
.
toBigDecimal
(
tqiReport
.
getTrackRight
()).
abs
();
if
(
1
==
analysisBatch
.
getAnalysisType
())
{
// 均值
finalTqiDirection
=
directionLeft
.
add
(
directionRight
).
divide
(
new
BigDecimal
(
"2"
),
3
,
BigDecimal
.
ROUND_HALF_UP
);
}
else
{
if
(
finalDirectionLeft
.
compareTo
(
finalDirectionRight
)
>
0
)
{
finalDirection
=
finalDirectionLeft
;
// 峰值
if
(
directionLeft
.
compareTo
(
directionRight
)
>
0
)
{
finalTqiDirection
=
directionLeft
;
}
else
{
finalDirection
=
finalDirectionRight
;
}
}
if
(
ObjectUtil
.
isNotEmpty
(
railVehicleTransfiniteList
))
{
int
heightSize
=
1
;
BigDecimal
sumDirection
=
finalDirection
;
for
(
AnalysisBatchUnitDeviceTransfinite
record
:
railVehicleTransfiniteList
)
{
if
(
record
.
getTransfiniteType
().
contains
(
"轨向"
))
{
BigDecimal
level
=
Convert
.
toBigDecimal
(
record
.
getMeasurePointValue
()).
abs
();
if
(
1
==
analysisType
)
{
// 均值
sumDirection
=
sumDirection
.
add
(
level
);
heightSize
++;
finalDirection
=
sumDirection
.
divide
(
new
BigDecimal
(
heightSize
),
3
,
BigDecimal
.
ROUND_HALF_UP
);
}
else
{
// 峰值
if
(
finalDirection
.
compareTo
(
level
)
<
0
)
{
finalDirection
=
level
;
}
}
finalTqiDirection
=
directionRight
;
}
}
AnalysisBatchUnitDevicePointScore
tqiDirectionPointScore
=
this
.
createRailVehicleCheckTqiPointScore
(
analysisBatch
,
finalTqiDirection
,
"轨向"
,
directionTqi
);
if
(
sumUnitScore
==
null
)
{
sumUnitScore
=
tqiDirectionPointScore
.
getPointScore
();
}
else
{
sumUnitScore
=
sumUnitScore
.
add
(
tqiDirectionPointScore
.
getPointScore
());
}
BigDecimal
directionUnitScore
=
directionWeightValues
.
multiply
(
finalDirection
);
sumUnitScore
=
sumUnitScore
.
add
(
directionUnitScore
);
scoreList
.
add
(
tqiDirectionPointScore
);
AnalysisBatchUnitDevicePointScore
directionPointScore
=
new
AnalysisBatchUnitDevicePointScore
();
directionPointScore
.
setId
(
UUIDGenerator
.
generate
());
directionPointScore
.
setAnalysisType
(
analysisType
);
directionPointScore
.
setSpeedMax
(
analysisBatch
.
getSpeedMax
());
directionPointScore
.
setSpeedMin
(
analysisBatch
.
getSpeedMin
());
directionPointScore
.
setAnalysisBatchId
(
analysisBatch
.
getId
());
directionPointScore
.
setAnalysisBatchCode
(
analysisBatch
.
getAnalysisBatchCode
());
directionPointScore
.
setPointTypeName
(
"轨向"
);
directionPointScore
.
setCheckType
(
3
);
directionPointScore
.
setPointValue
(
finalDirection
);
directionPointScore
.
setWeightValues
(
directionWeightValues
);
directionPointScore
.
setPointScore
(
directionUnitScore
);
scoreList
.
add
(
directionPointScore
);
// 计算水平得分
BigDecimal
finalTqiLevel
=
Convert
.
toBigDecimal
(
tqiReport
.
getLevel
()).
abs
();
AnalysisBatchUnitDevicePointScore
tqiLevelPointScore
=
this
.
createRailVehicleCheckTqiPointScore
(
analysisBatch
,
finalTqiLevel
,
"水平"
,
levelTqi
);
if
(
sumUnitScore
==
null
)
{
sumUnitScore
=
tqiLevelPointScore
.
getPointScore
();
}
else
{
sumUnitScore
=
sumUnitScore
.
add
(
tqiLevelPointScore
.
getPointScore
());
}
scoreList
.
add
(
tqiLevelPointScore
);
// 计算tqi的分数
// 左高低
BigDecimal
highLowLeft
=
Convert
.
toBigDecimal
(
tqiReport
.
getHighLowLeft
());
BigDecimal
highLowLeftScore
=
highLowLeft
.
multiply
(
heightTqi
);
// 右高低
BigDecimal
highLowRight
=
Convert
.
toBigDecimal
(
tqiReport
.
getHighLowRight
());
BigDecimal
highLowRightScore
=
highLowRight
.
multiply
(
heightTqi
);
// 计算轨距得分
BigDecimal
finalTqiTrackGauge
=
Convert
.
toBigDecimal
(
tqiReport
.
getTrackGauge
()).
abs
();
AnalysisBatchUnitDevicePointScore
tqiTrackGaugePointScore
=
this
.
createRailVehicleCheckTqiPointScore
(
analysisBatch
,
finalTqiTrackGauge
,
"轨距"
,
trackGaugeTqi
);
if
(
sumUnitScore
==
null
)
{
sumUnitScore
=
tqiTrackGaugePointScore
.
getPointScore
();
}
else
{
sumUnitScore
=
sumUnitScore
.
add
(
tqiTrackGaugePointScore
.
getPointScore
());
}
scoreList
.
add
(
tqiTrackGaugePointScore
);
// 轨向左
BigDecimal
trackLeft
=
Convert
.
toBigDecimal
(
tqiReport
.
getTrackLeft
());
BigDecimal
trackLeftScore
=
trackLeft
.
multiply
(
directionTqi
);
// 计算三角坑得分
BigDecimal
finalTqiTriangularPit
=
Convert
.
toBigDecimal
(
tqiReport
.
getTriangularPit
()).
abs
();
AnalysisBatchUnitDevicePointScore
tqiTriangularPitScore
=
this
.
createRailVehicleCheckTqiPointScore
(
analysisBatch
,
finalTqiTriangularPit
,
"三角坑"
,
triangularPitTqi
);
if
(
sumUnitScore
==
null
)
{
sumUnitScore
=
tqiTriangularPitScore
.
getPointScore
();
}
else
{
sumUnitScore
=
sumUnitScore
.
add
(
tqiTriangularPitScore
.
getPointScore
());
}
scoreList
.
add
(
tqiTriangularPitScore
);
// 轨向右
BigDecimal
trackRight
=
Convert
.
toBigDecimal
(
tqiReport
.
getTrackRight
());
BigDecimal
trackRightScore
=
trackRight
.
multiply
(
directionTqi
);
// 水平
BigDecimal
level
=
Convert
.
toBigDecimal
(
tqiReport
.
getLevel
());
BigDecimal
levelScore
=
level
.
multiply
(
levelTqi
);
// 计算tqi得分
BigDecimal
finalTqi
=
Convert
.
toBigDecimal
(
tqiReport
.
getTqiComeUpon
()).
abs
();
AnalysisBatchUnitDevicePointScore
tqiScore
=
this
.
createRailVehicleCheckTqiPointScore
(
analysisBatch
,
finalTqi
,
"tqi"
,
tqiComeUponTqi
);
if
(
sumUnitScore
==
null
)
{
sumUnitScore
=
tqiScore
.
getPointScore
();
}
else
{
sumUnitScore
=
sumUnitScore
.
add
(
tqiScore
.
getPointScore
());
}
scoreList
.
add
(
tqiScore
);
// 轨距
BigDecimal
trackGauge
=
Convert
.
toBigDecimal
(
tqiReport
.
getTrackGauge
());
BigDecimal
trackGaugeScore
=
trackGauge
.
multiply
(
trackGaugeTqi
);
// 三角坑
BigDecimal
triangularPit
=
Convert
.
toBigDecimal
(
tqiReport
.
getTriangularPit
());
BigDecimal
triangularPitScore
=
triangularPit
.
multiply
(
triangularPitTqi
);
// 判断tqi是否超限
// 超标≤10% | 15 ≤ TQI < 16.5(0 < V ≤ 80)
// if(tqiReport.getTqiComeUpon())
// // 轨检车超限等级
// AnalysisBatchUnitDeviceTransfinite tqiTransfinite = this.createRailVehicleCheckTqiTransfinite(dispatchingList, tqiReport);
// railVehicleTransfiniteList.add(tqiTransfinite);
// System.out.printf(analysisBatch.getDispatching());
// 只映射一个tqi区间,映射到了就直接结束区间循环
break
;
}
}
// tqi
BigDecimal
tqiComeUpon
=
Convert
.
toBigDecimal
(
tqiReport
.
getTqiComeUpon
());
BigDecimal
tqiComeUponScore
=
tqiComeUpon
.
multiply
(
tqiComeUponTqi
);
unitDevice
.
put
(
"railVehicleTransfiniteList"
,
railVehicleTransfiniteList
);
unitDevice
.
put
(
"railVehicleCheckScore"
,
sumUnitScore
);
unitDevice
.
put
(
"railVehicleCheckScoreList"
,
scoreList
);
}
BigDecimal
sumScore
=
highLowLeftScore
.
add
(
highLowRightScore
).
add
(
trackLeftScore
).
add
(
trackRightScore
).
add
(
levelScore
).
add
(
trackGaugeScore
).
add
(
triangularPitScore
).
add
(
tqiComeUponScore
);
}
AnalysisBatchUnitDeviceTqiScore
tqiScore
=
new
AnalysisBatchUnitDeviceTqiScore
();
tqiScore
.
setId
(
UUIDGenerator
.
generate
());
tqiScore
.
setAnalysisType
(
analysisType
);
tqiScore
.
setAnalysisBatchId
(
analysisBatch
.
getId
());
tqiScore
.
setAnalysisBatchCode
(
analysisBatch
.
getAnalysisBatchCode
());
tqiScore
.
setUnitId
(
Convert
.
toStr
(
unitDevice
.
get
(
"id"
)));
tqiScore
.
setUnitCode
(
Convert
.
toStr
(
unitDevice
.
get
(
"unitCode"
)));
tqiScore
.
setUnitType
(
Convert
.
toInt
(
unitDevice
.
get
(
"type"
)));
tqiScore
.
setUnitTypeName
(
Convert
.
toStr
(
unitDevice
.
get
(
"typeName"
)));
/**
* 创建轨检车检查数据tqi测点分数
*
* @param analysisBatch 分析批次
* @param finalPointValue 测点值
* @param pointType 测点类型
* @param weightValue 测点权值
* @return
*/
private
AnalysisBatchUnitDevicePointScore
createRailVehicleCheckTqiPointScore
(
AnalysisBatch
analysisBatch
,
BigDecimal
finalPointValue
,
String
pointType
,
BigDecimal
weightValue
)
{
BigDecimal
unitScore
=
finalPointValue
.
multiply
(
weightValue
);
AnalysisBatchUnitDevicePointScore
pointScore
=
new
AnalysisBatchUnitDevicePointScore
();
pointScore
.
setId
(
UUIDGenerator
.
generate
());
pointScore
.
setAnalysisType
(
analysisBatch
.
getAnalysisType
());
pointScore
.
setSpeedMax
(
analysisBatch
.
getSpeedMax
());
pointScore
.
setSpeedMin
(
analysisBatch
.
getSpeedMin
());
pointScore
.
setAnalysisBatchId
(
analysisBatch
.
getId
());
pointScore
.
setAnalysisBatchCode
(
analysisBatch
.
getAnalysisBatchCode
());
pointScore
.
setPointTypeName
(
"轨检车TQI-"
+
pointType
);
pointScore
.
setCheckType
(
3
);
pointScore
.
setPointValue
(
finalPointValue
);
pointScore
.
setWeightValues
(
weightValue
);
pointScore
.
setPointScore
(
unitScore
);
return
pointScore
;
}
tqiScore
.
setHighLowLeft
(
highLowLeft
);
tqiScore
.
setHighLowLeftWeightValues
(
heightTqi
);
tqiScore
.
setHighLowLeftScore
(
highLowLeftScore
);
tqiScore
.
setHighLowRight
(
highLowRight
);
tqiScore
.
setHighLowRightWeightValues
(
heightTqi
);
tqiScore
.
setHighLowRightScore
(
highLowRightScore
);
/**
* 创建轨检车测点得分
*/
private
AnalysisBatchUnitDevicePointScore
createRailVehicleCheckTransfinitePointScore
(
AnalysisBatch
analysisBatch
,
List
<
MovementOverReport
>
currentUnitDeviceOverReportList
,
String
overrunType
,
BigDecimal
weightValue
)
{
if
(
ObjectUtil
.
isEmpty
(
currentUnitDeviceOverReportList
))
{
return
null
;
}
tqiScore
.
setTrackLeft
(
trackLeft
)
;
tqiScore
.
setTrackLeftWeightValues
(
directionTqi
)
;
tqiScore
.
setTrackLeftScore
(
trackLeftScore
)
;
int
currentPointSize
=
0
;
BigDecimal
finalPointValue
=
null
;
BigDecimal
sumPointValue
=
BigDecimal
.
ZERO
;
tqiScore
.
setTrackRight
(
trackRight
);
tqiScore
.
setTrackRightWeightValues
(
directionTqi
);
tqiScore
.
setTrackRightScore
(
trackRightScore
);
Iterator
<
MovementOverReport
>
iterator
=
currentUnitDeviceOverReportList
.
iterator
();
while
(
iterator
.
hasNext
())
{
MovementOverReport
currentUnitDeviceOverReport
=
iterator
.
next
();
if
(
currentUnitDeviceOverReport
.
getOverrunType
().
contains
(
overrunType
))
{
BigDecimal
currentPointValue
=
Convert
.
toBigDecimal
(
currentUnitDeviceOverReport
.
getPeakValue
()).
abs
();
sumPointValue
=
sumPointValue
.
add
(
currentPointValue
);
currentPointSize
++;
tqiScore
.
setLevel
(
level
);
tqiScore
.
setLevelWeightValues
(
levelTqi
);
tqiScore
.
setLevelScore
(
levelScore
);
if
(
1
==
analysisBatch
.
getAnalysisType
())
{
// 均值
finalPointValue
=
sumPointValue
.
divide
(
new
BigDecimal
(
currentPointSize
),
3
,
BigDecimal
.
ROUND_HALF_UP
);
}
else
{
// 峰值
if
(
finalPointValue
==
null
)
{
finalPointValue
=
currentPointValue
;
}
else
if
(
finalPointValue
.
compareTo
(
currentPointValue
)
<
0
)
{
finalPointValue
=
currentPointValue
;
}
}
tqiScore
.
setTrackGauge
(
trackGauge
);
tqiScore
.
setTrackGaugeWeightValues
(
trackGaugeTqi
);
tqiScore
.
setTrackGaugeScore
(
trackGaugeScore
);
// 处理过的直接移除
iterator
.
remove
();
}
}
tqiScore
.
setTriangularPit
(
triangularPit
)
;
tqiScore
.
setTriangularPitWeightValues
(
triangularPitTqi
);
tqiScore
.
setTriangularPitScore
(
triangularPitScor
e
);
AnalysisBatchUnitDevicePointScore
pointScore
=
null
;
if
(
ObjectUtil
.
isNotEmpty
(
finalPointValue
))
{
BigDecimal
unitScore
=
finalPointValue
.
multiply
(
weightValu
e
);
tqiScore
.
setTqiComeUpon
(
tqiComeUpon
);
tqiScore
.
setTqiComeUponWeightValues
(
tqiComeUponTqi
);
tqiScore
.
setTqiComeUponScore
(
tqiComeUponScore
);
pointScore
=
new
AnalysisBatchUnitDevicePointScore
();
pointScore
.
setId
(
UUIDGenerator
.
generate
());
pointScore
.
setAnalysisType
(
analysisBatch
.
getAnalysisType
());
pointScore
.
setSpeedMax
(
analysisBatch
.
getSpeedMax
());
pointScore
.
setSpeedMin
(
analysisBatch
.
getSpeedMin
());
pointScore
.
setAnalysisBatchId
(
analysisBatch
.
getId
());
pointScore
.
setAnalysisBatchCode
(
analysisBatch
.
getAnalysisBatchCode
());
pointScore
.
setPointTypeName
(
"轨检车超限-"
+
overrunType
);
pointScore
.
setCheckType
(
3
);
pointScore
.
setPointValue
(
finalPointValue
);
pointScore
.
setWeightValues
(
weightValue
);
pointScore
.
setPointScore
(
unitScore
);
}
tqiScore
.
setSumScore
(
sumScore
);
unitDevice
.
put
(
"railVehicleTqiScore"
,
tqiScore
);
return
pointScore
;
}
// 判断tqi是否超限没写
/**
* @param dispatchingList
* @param movementOverReport
* @return
*/
private
AnalysisBatchUnitDeviceTransfinite
createRailVehicleCheckTransfinite
(
JSONArray
dispatchingList
,
MovementOverReport
movementOverReport
)
{
boolean
isDisplay
=
false
;
int
isWork
=
1
;
String
reasonLabel
=
null
;
Integer
transfiniteGrade
=
Convert
.
toInt
(
movementOverReport
.
getOverrunLevel
());
String
railVehicleOverGrade
=
"rail_vehicle_over_"
+
transfiniteGrade
;
for
(
Object
obj
:
dispatchingList
)
{
JSONObject
dispatching
=
(
JSONObject
)
obj
;
String
reasonValue
=
String
.
valueOf
(
dispatching
.
get
(
"reasonValue"
));
if
(
reasonValue
.
equals
(
railVehicleOverGrade
))
{
Boolean
isWorkTemp
=
Boolean
.
valueOf
(
dispatching
.
get
(
"isWork"
).
toString
());
reasonLabel
=
String
.
valueOf
(
dispatching
.
get
(
"reasonLabel"
));
if
(
isWorkTemp
)
{
isWork
=
1
;
}
else
{
isWork
=
0
;
}
isDisplay
=
true
;
break
;
}
}
unitDevice
.
put
(
"railVehicleCheckScore"
,
sumUnitScore
);
unitDevice
.
put
(
"railVehicleCheckScoreList"
,
scoreList
);
// 如果没有读取到相应得配置表示不用
if
(!
isDisplay
)
{
return
null
;
}
if
(
ObjectUtil
.
isNotEmpty
(
overReportUnitDeviceMaps
))
{
movementOverReportUnitDeviceMapService
.
lambdaUpdate
().
eq
(
MovementOverReportUnitDeviceMap:
:
getCheckId
,
checkDataMap
.
getEkId
()).
remove
();
movementOverReportUnitDeviceMapService
.
saveBatch
(
overReportUnitDeviceMaps
);
}
if
(
ObjectUtil
.
isNotEmpty
(
movementTqiReportUnitDeviceMaps
))
{
movementTqiReportUnitDeviceMapService
.
lambdaUpdate
().
eq
(
MovementTqiReportUnitDeviceMap:
:
getCheckId
,
checkDataMap
.
getEkId
()).
remove
();
movementTqiReportUnitDeviceMapService
.
saveBatch
(
movementTqiReportUnitDeviceMaps
);
}
AnalysisBatchUnitDeviceTransfinite
transfinite
=
new
AnalysisBatchUnitDeviceTransfinite
();
transfinite
.
setId
(
UUIDGenerator
.
generate
());
transfinite
.
setTransfiniteGrade
(
transfiniteGrade
);
transfinite
.
setTransfiniteType
(
movementOverReport
.
getOverrunType
());
String
allowValue
=
Convert
.
toBigDecimal
(
movementOverReport
.
getPeakValue
()).
subtract
(
Convert
.
toBigDecimal
(
movementOverReport
.
getDataDifference
())).
toString
();
transfinite
.
setAllowValue
(
allowValue
);
transfinite
.
setEkId
(
movementOverReport
.
getMovementMasterId
());
transfinite
.
setEkType
(
3
);
transfinite
.
setEkItemId
(
movementOverReport
.
getId
());
transfinite
.
setMeasurePointValue
(
movementOverReport
.
getPeakValue
());
transfinite
.
setIsWork
(
isWork
);
transfinite
.
setTransfiniteGradeName
(
reasonLabel
);
return
transfinite
;
}
/**
...
...
@@ -1318,14 +1232,14 @@ public class AnalysisAlgorithm {
for
(
Map
<
String
,
Object
>
unitDevice
:
unitDeviceList
)
{
BigDecimal
centerMileage
=
Convert
.
toBigDecimal
(
unitDevice
.
get
(
"centerMileage"
));
System
.
out
.
println
(
"单元设备code:"
+
unitDevice
.
get
(
"unitCode"
)
+
"单元中心里程:"
+
centerMileage
);
//
System.out.println("单元设备code:" + unitDevice.get("unitCode") + "单元中心里程:" + centerMileage);
// 2.1 循环遍历检查项目比较【开始-结束】来映射关联关系
for
(
RailInspectionEquipmentItem
checkItem
:
checkItemList
)
{
BigDecimal
checkItemStartingMileage
=
checkItem
.
getCourseStartingMileage
();
BigDecimal
checkItemEndMileage
=
checkItem
.
getCourseEndMileage
();
System
.
out
.
printf
(
"【"
+
checkItemStartingMileage
+
"-"
+
checkItemEndMileage
+
"]"
);
//
System.out.printf("【" + checkItemStartingMileage + "-" + checkItemEndMileage + "]");
// 2.2.1 命中检查项目
if
(
checkItemStartingMileage
.
compareTo
(
centerMileage
)
<=
0
&&
checkItemEndMileage
.
compareTo
(
centerMileage
)
>
0
)
{
...
...
@@ -1375,8 +1289,6 @@ public class AnalysisAlgorithm {
break
;
}
}
System
.
out
.
printf
(
"\n\r"
);
}
...
...
jeecg-module-system/src/main/java/org/jeecg/modules/dynamicStaticAnalysis/controller/ConfigTqiLimitController.java
0 → 100644
View file @
fe473b97
package
org
.
jeecg
.
modules
.
dynamicStaticAnalysis
.
controller
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiOperation
;
import
org.jeecg.common.api.vo.Result
;
import
org.jeecg.common.aspect.annotation.AutoLog
;
import
org.jeecg.common.util.UUIDGenerator
;
import
org.jeecg.modules.dynamicStaticAnalysis.entity.ConfigDispatching
;
import
org.jeecg.modules.dynamicStaticAnalysis.entity.ConfigTqiLimit
;
import
org.jeecg.modules.dynamicStaticAnalysis.service.IConfigTqiLimitService
;
import
org.jeecg.modules.dynamicStaticAnalysis.vo.ConfigTqiLimitVO
;
import
org.springframework.web.bind.annotation.*
;
import
org.jeecg.common.system.base.controller.JeecgController
;
import
java.util.List
;
/**
* <p>
* 动静态分析-配置参数-TQI管理标准顺质量指数 前端控制器
* </p>
*
* @author hkl
* @since 2023-09-15
*/
@RestController
@RequestMapping
(
"/dynamicStaticAnalysis/configTqiLimit"
)
@Api
(
tags
=
"动静态分析-配置参数-TQI管理标准顺质量指数"
)
public
class
ConfigTqiLimitController
extends
JeecgController
<
ConfigTqiLimit
,
IConfigTqiLimitService
>
{
@AutoLog
(
value
=
"动静态分析-配置参数-TQI管理标准顺质量指数-查询所有参数"
)
@ApiOperation
(
value
=
"动静态分析-配置参数-TQI管理标准顺质量指数-查询所有参数"
,
notes
=
"动静态分析-配置参数-TQI管理标准顺质量指数-查询所有参数"
)
@GetMapping
(
value
=
"/listRecord"
)
public
Result
<
List
<
ConfigTqiLimit
>>
listRecord
()
{
List
<
ConfigTqiLimit
>
list
=
this
.
service
.
list
();
return
Result
.
OK
(
list
);
}
@AutoLog
(
value
=
"动静态分析-配置参数-TQI管理标准顺质量指数-批量更新"
)
@ApiOperation
(
value
=
"动静态分析-配置参数-TQI管理标准顺质量指数-批量更新"
,
notes
=
"动静态分析-配置参数-TQI管理标准顺质量指数-批量更新"
)
@PostMapping
(
value
=
"/batchUpdateRecord"
)
public
Result
<
String
>
batchUpdateRecord
(
@RequestBody
List
<
ConfigTqiLimit
>
records
)
{
this
.
service
.
updateBatchById
(
records
);
return
Result
.
OK
(
"操作成功"
);
}
}
jeecg-module-system/src/main/java/org/jeecg/modules/dynamicStaticAnalysis/entity/ConfigTqiLimit.java
0 → 100644
View file @
fe473b97
package
org
.
jeecg
.
modules
.
dynamicStaticAnalysis
.
entity
;
import
com.baomidou.mybatisplus.annotation.TableField
;
import
com.baomidou.mybatisplus.annotation.TableId
;
import
com.baomidou.mybatisplus.annotation.TableName
;
import
java.io.Serializable
;
import
java.math.BigDecimal
;
import
java.util.Date
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Getter
;
import
lombok.Setter
;
/**
* <p>
* 动静态分析-配置-TQI管理标准顺质量指数
* </p>
*
* @author hkl
* @since 2023-09-15
*/
@Getter
@Setter
@TableName
(
"t_dsa_config_tqi_limit"
)
@ApiModel
(
value
=
"ConfigTqiLimit对象"
,
description
=
"动静态分析-配置-TQI管理标准顺质量指数"
)
public
class
ConfigTqiLimit
implements
Serializable
{
private
static
final
long
serialVersionUID
=
1L
;
@ApiModelProperty
(
"主键"
)
@TableId
(
"id"
)
private
String
id
;
@ApiModelProperty
(
"创建人"
)
@TableField
(
"create_by"
)
private
String
createBy
;
@ApiModelProperty
(
"创建日期"
)
@TableField
(
"create_time"
)
private
Date
createTime
;
@ApiModelProperty
(
"更新人"
)
@TableField
(
"update_by"
)
private
String
updateBy
;
@ApiModelProperty
(
"更新时间"
)
@TableField
(
"update_time"
)
private
Date
updateTime
;
@ApiModelProperty
(
"速度下限"
)
@TableField
(
"speed_min"
)
private
Integer
speedMin
;
@ApiModelProperty
(
"速度上限"
)
@TableField
(
"speed_max"
)
private
Integer
speedMax
;
@ApiModelProperty
(
"数据字典标签"
)
@TableField
(
"dict_label"
)
private
String
dictLabel
;
@ApiModelProperty
(
"数据字典值"
)
@TableField
(
"dict_value"
)
private
String
dictValue
;
@ApiModelProperty
(
"超标类型 1-超标≤10% 2-超标≤20% 3-超标>20%"
)
@TableField
(
"over_standard_type"
)
private
Integer
overStandardType
;
@ApiModelProperty
(
"评价等级中文说明"
)
@TableField
(
"over_standard_type_str"
)
private
String
overStandardTypeStr
;
@ApiModelProperty
(
"tqi下限"
)
@TableField
(
"tqi_min"
)
private
BigDecimal
tqiMin
;
@ApiModelProperty
(
"tqi上限"
)
@TableField
(
"tqi_max"
)
private
BigDecimal
tqiMax
;
@ApiModelProperty
(
"是否删除(0:未删除; 1:已删除)"
)
@TableField
(
"del_flag"
)
private
String
delFlag
;
@ApiModelProperty
(
"备注"
)
@TableField
(
"remark"
)
private
String
remark
;
}
jeecg-module-system/src/main/java/org/jeecg/modules/dynamicStaticAnalysis/mapper/ConfigTqiLimitMapper.java
0 → 100644
View file @
fe473b97
package
org
.
jeecg
.
modules
.
dynamicStaticAnalysis
.
mapper
;
import
org.jeecg.modules.dynamicStaticAnalysis.entity.ConfigTqiLimit
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
/**
* <p>
* 动静态分析-配置-TQI管理标准顺质量指数 Mapper 接口
* </p>
*
* @author hkl
* @since 2023-09-15
*/
public
interface
ConfigTqiLimitMapper
extends
BaseMapper
<
ConfigTqiLimit
>
{
}
jeecg-module-system/src/main/java/org/jeecg/modules/dynamicStaticAnalysis/mapper/xml/ConfigTqiLimitMapper.xml
0 → 100644
View file @
fe473b97
<?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">
<mapper
namespace=
"org.jeecg.modules.dynamicStaticAnalysis.mapper.ConfigTqiLimitMapper"
>
</mapper>
jeecg-module-system/src/main/java/org/jeecg/modules/dynamicStaticAnalysis/other/AnalysisBatchUnitDeviceTqiScoreDTO.java
deleted
100644 → 0
View file @
06942fdb
package
org
.
jeecg
.
modules
.
dynamicStaticAnalysis
.
entity
;
import
com.baomidou.mybatisplus.annotation.TableField
;
import
com.baomidou.mybatisplus.annotation.TableId
;
import
com.baomidou.mybatisplus.annotation.TableName
;
import
java.io.Serializable
;
import
java.math.BigDecimal
;
import
java.util.Date
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Getter
;
import
lombok.Setter
;
/**
* <p>
* 动静态分析-分析批次-单元设备测点得分
* </p>
*
* @author hkl
* @since 2023-08-28
*/
@Getter
@Setter
@ApiModel
(
value
=
"AnalysisBatchUnitDeviceTqiScore对象"
,
description
=
"动静态分析-分析批次-单元设备测点得分"
)
public
class
AnalysisBatchUnitDeviceTqiScoreDTO
{
private
static
final
long
serialVersionUID
=
1L
;
@ApiModelProperty
(
"主键"
)
private
String
id
;
@ApiModelProperty
(
"创建人"
)
private
String
createBy
;
@ApiModelProperty
(
"创建日期"
)
private
Date
createTime
;
@ApiModelProperty
(
"更新人"
)
private
String
updateBy
;
@ApiModelProperty
(
"更新时间"
)
private
Date
updateTime
;
@ApiModelProperty
(
"速度下限"
)
private
Integer
speedMin
;
@ApiModelProperty
(
"速度上限"
)
private
Integer
speedMax
;
@ApiModelProperty
(
"分析类型 1-均值分析 2-峰值分析"
)
private
Integer
analysisType
;
@ApiModelProperty
(
"分析批次单元设备id"
)
private
String
analysisBatchUnitDeviceId
;
@ApiModelProperty
(
"分析批次号"
)
private
String
analysisBatchCode
;
@ApiModelProperty
(
"分析批id"
)
private
String
analysisBatchId
;
@ApiModelProperty
(
"单元设备id"
)
private
String
unitId
;
@ApiModelProperty
(
"单元设备code"
)
private
String
unitCode
;
@ApiModelProperty
(
"设备单元类型1-钢轨,2-曲线,3-竖曲线,4-道岔"
)
private
Integer
unitType
;
@ApiModelProperty
(
"设备单元类型名称"
)
private
String
unitTypeName
;
@ApiModelProperty
(
"测点类型"
)
private
String
pointTypeName
;
@ApiModelProperty
(
"高低左"
)
private
BigDecimal
highLowLeft
;
@ApiModelProperty
(
"高低左分数"
)
private
BigDecimal
highLowLeftScore
;
@ApiModelProperty
(
"高低左权值"
)
private
BigDecimal
highLowLeftWeightValues
;
@ApiModelProperty
(
"高低右"
)
private
BigDecimal
highLowRight
;
@ApiModelProperty
(
"高低右分数"
)
private
BigDecimal
highLowRightScore
;
@ApiModelProperty
(
"高低右权值"
)
private
BigDecimal
highLowRightWeightValues
;
@ApiModelProperty
(
"轨向左"
)
private
BigDecimal
trackLeft
;
@ApiModelProperty
(
"轨向左分数"
)
private
BigDecimal
trackLeftScore
;
@ApiModelProperty
(
"轨向左权值"
)
private
BigDecimal
trackLeftWeightValues
;
@ApiModelProperty
(
"轨向右"
)
private
BigDecimal
trackRight
;
@ApiModelProperty
(
"轨向右分数"
)
private
BigDecimal
trackRightScore
;
@ApiModelProperty
(
"轨向右权值"
)
private
BigDecimal
trackRightWeightValues
;
@ApiModelProperty
(
"水平(mm)"
)
private
BigDecimal
level
;
@ApiModelProperty
(
"水平(mm)分数"
)
private
BigDecimal
levelScore
;
@ApiModelProperty
(
"水平(mm)权值"
)
private
BigDecimal
levelWeightValues
;
@ApiModelProperty
(
"轨距(mm)"
)
private
BigDecimal
trackGauge
;
@ApiModelProperty
(
"轨距(mm)分数"
)
private
BigDecimal
trackGaugeScore
;
@ApiModelProperty
(
"轨距(mm)权值"
)
private
BigDecimal
trackGaugeWeightValues
;
@ApiModelProperty
(
"三角坑(mm)"
)
private
BigDecimal
triangularPit
;
@ApiModelProperty
(
"三角坑(mm)分数"
)
private
BigDecimal
triangularPitScore
;
@ApiModelProperty
(
"三角坑(mm)权值"
)
private
BigDecimal
triangularPitWeightValues
;
@ApiModelProperty
(
"TQI数值"
)
private
BigDecimal
tqiComeUpon
;
@ApiModelProperty
(
"TQI数值分数"
)
private
BigDecimal
tqiComeUponScore
;
@ApiModelProperty
(
"TQI数值权值"
)
private
BigDecimal
tqiComeUponWeightValues
;
@ApiModelProperty
(
"总得分"
)
private
BigDecimal
sumScore
;
@ApiModelProperty
(
"备注"
)
private
String
remark
;
}
jeecg-module-system/src/main/java/org/jeecg/modules/dynamicStaticAnalysis/other/AnalysisBatchUnitDeviceTqiScoreVO.java
deleted
100644 → 0
View file @
06942fdb
package
org
.
jeecg
.
modules
.
dynamicStaticAnalysis
.
entity
;
import
com.baomidou.mybatisplus.annotation.TableField
;
import
com.baomidou.mybatisplus.annotation.TableId
;
import
com.baomidou.mybatisplus.annotation.TableName
;
import
java.io.Serializable
;
import
java.math.BigDecimal
;
import
java.util.Date
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Getter
;
import
lombok.Setter
;
/**
* <p>
* 动静态分析-分析批次-单元设备测点得分
* </p>
*
* @author hkl
* @since 2023-08-28
*/
@Getter
@Setter
@ApiModel
(
value
=
"AnalysisBatchUnitDeviceTqiScore对象"
,
description
=
"动静态分析-分析批次-单元设备测点得分"
)
public
class
AnalysisBatchUnitDeviceTqiScoreVO
{
private
static
final
long
serialVersionUID
=
1L
;
@ApiModelProperty
(
"主键"
)
@TableId
(
"id"
)
private
String
id
;
@ApiModelProperty
(
"创建人"
)
@TableField
(
"create_by"
)
private
String
createBy
;
@ApiModelProperty
(
"创建日期"
)
@TableField
(
"create_time"
)
private
Date
createTime
;
@ApiModelProperty
(
"更新人"
)
@TableField
(
"update_by"
)
private
String
updateBy
;
@ApiModelProperty
(
"更新时间"
)
@TableField
(
"update_time"
)
private
Date
updateTime
;
@ApiModelProperty
(
"速度下限"
)
@TableField
(
"speed_min"
)
private
Integer
speedMin
;
@ApiModelProperty
(
"速度上限"
)
@TableField
(
"speed_max"
)
private
Integer
speedMax
;
@ApiModelProperty
(
"分析类型 1-均值分析 2-峰值分析"
)
@TableField
(
"analysis_type"
)
private
Integer
analysisType
;
@ApiModelProperty
(
"分析批次单元设备id"
)
@TableField
(
"analysis_batch_unit_device_id"
)
private
String
analysisBatchUnitDeviceId
;
@ApiModelProperty
(
"分析批次号"
)
@TableField
(
"analysis_batch_code"
)
private
String
analysisBatchCode
;
@ApiModelProperty
(
"分析批id"
)
@TableField
(
"analysis_batch_id"
)
private
String
analysisBatchId
;
@ApiModelProperty
(
"单元设备id"
)
@TableField
(
"unit_id"
)
private
String
unitId
;
@ApiModelProperty
(
"单元设备code"
)
@TableField
(
"unit_code"
)
private
String
unitCode
;
@ApiModelProperty
(
"设备单元类型1-钢轨,2-曲线,3-竖曲线,4-道岔"
)
@TableField
(
"unit_type"
)
private
Integer
unitType
;
@ApiModelProperty
(
"设备单元类型名称"
)
@TableField
(
"unit_type_name"
)
private
String
unitTypeName
;
@ApiModelProperty
(
"测点类型"
)
@TableField
(
"point_type_name"
)
private
String
pointTypeName
;
@ApiModelProperty
(
"高低左"
)
@TableField
(
"high_low_left"
)
private
BigDecimal
highLowLeft
;
@ApiModelProperty
(
"高低左分数"
)
@TableField
(
"high_low_left_score"
)
private
BigDecimal
highLowLeftScore
;
@ApiModelProperty
(
"高低左权值"
)
@TableField
(
"high_low_left_weight_values"
)
private
BigDecimal
highLowLeftWeightValues
;
@ApiModelProperty
(
"高低右"
)
@TableField
(
"high_low_right"
)
private
BigDecimal
highLowRight
;
@ApiModelProperty
(
"高低右分数"
)
@TableField
(
"high_low_right_score"
)
private
BigDecimal
highLowRightScore
;
@ApiModelProperty
(
"高低右权值"
)
@TableField
(
"high_low_right_weight_values"
)
private
BigDecimal
highLowRightWeightValues
;
@ApiModelProperty
(
"轨向左"
)
@TableField
(
"track_left"
)
private
BigDecimal
trackLeft
;
@ApiModelProperty
(
"轨向左分数"
)
@TableField
(
"track_left_score"
)
private
BigDecimal
trackLeftScore
;
@ApiModelProperty
(
"轨向左权值"
)
@TableField
(
"track_left_weight_values"
)
private
BigDecimal
trackLeftWeightValues
;
@ApiModelProperty
(
"轨向右"
)
@TableField
(
"track_right"
)
private
BigDecimal
trackRight
;
@ApiModelProperty
(
"轨向右分数"
)
@TableField
(
"track_right_score"
)
private
BigDecimal
trackRightScore
;
@ApiModelProperty
(
"轨向右权值"
)
@TableField
(
"track_right_weight_values"
)
private
BigDecimal
trackRightWeightValues
;
@ApiModelProperty
(
"水平(mm)"
)
@TableField
(
"level"
)
private
BigDecimal
level
;
@ApiModelProperty
(
"水平(mm)分数"
)
@TableField
(
"level_score"
)
private
BigDecimal
levelScore
;
@ApiModelProperty
(
"水平(mm)权值"
)
@TableField
(
"level_weight_values"
)
private
BigDecimal
levelWeightValues
;
@ApiModelProperty
(
"轨距(mm)"
)
@TableField
(
"track_gauge"
)
private
BigDecimal
trackGauge
;
@ApiModelProperty
(
"轨距(mm)分数"
)
@TableField
(
"track_gauge_score"
)
private
BigDecimal
trackGaugeScore
;
@ApiModelProperty
(
"轨距(mm)权值"
)
@TableField
(
"track_gauge_weight_values"
)
private
BigDecimal
trackGaugeWeightValues
;
@ApiModelProperty
(
"三角坑(mm)"
)
@TableField
(
"triangular_pit"
)
private
BigDecimal
triangularPit
;
@ApiModelProperty
(
"三角坑(mm)分数"
)
@TableField
(
"triangular_pit_score"
)
private
BigDecimal
triangularPitScore
;
@ApiModelProperty
(
"三角坑(mm)权值"
)
@TableField
(
"triangular_pit_weight_values"
)
private
BigDecimal
triangularPitWeightValues
;
@ApiModelProperty
(
"TQI数值"
)
@TableField
(
"tqi_come_upon"
)
private
BigDecimal
tqiComeUpon
;
@ApiModelProperty
(
"TQI数值分数"
)
@TableField
(
"tqi_come_upon_score"
)
private
BigDecimal
tqiComeUponScore
;
@ApiModelProperty
(
"TQI数值权值"
)
@TableField
(
"tqi_come_upon_weight_values"
)
private
BigDecimal
tqiComeUponWeightValues
;
@ApiModelProperty
(
"总得分"
)
@TableField
(
"sum_score"
)
private
BigDecimal
sumScore
;
@ApiModelProperty
(
"备注"
)
@TableField
(
"remark"
)
private
String
remark
;
}
jeecg-module-system/src/main/java/org/jeecg/modules/dynamicStaticAnalysis/other/AnalysisBatchUnitDeviceWorkDTO.java
deleted
100644 → 0
View file @
06942fdb
package
org
.
jeecg
.
modules
.
dynamicStaticAnalysis
.
entity
;
import
com.baomidou.mybatisplus.annotation.TableField
;
import
com.baomidou.mybatisplus.annotation.TableId
;
import
com.baomidou.mybatisplus.annotation.TableName
;
import
java.io.Serializable
;
import
java.util.Date
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Getter
;
import
lombok.Setter
;
/**
* <p>
* 动静态分析-分析批次-单元设备派工表
* </p>
*
* @author hkl
* @since 2023-08-30
*/
@Getter
@Setter
@ApiModel
(
value
=
"AnalysisBatchUnitDeviceWork对象"
,
description
=
"动静态分析-分析批次-单元设备派工表"
)
public
class
AnalysisBatchUnitDeviceWorkDTO
{
private
static
final
long
serialVersionUID
=
1L
;
@ApiModelProperty
(
"主键"
)
private
String
id
;
@ApiModelProperty
(
"创建人"
)
private
String
createBy
;
@ApiModelProperty
(
"创建日期"
)
private
Date
createTime
;
@ApiModelProperty
(
"更新人"
)
private
String
updateBy
;
@ApiModelProperty
(
"更新时间"
)
private
Date
updateTime
;
@ApiModelProperty
(
"分析批次单元设备id"
)
private
String
analysisBatchUnitDeviceId
;
@ApiModelProperty
(
"分析批次号"
)
private
String
analysisBatchCode
;
@ApiModelProperty
(
"分析批id"
)
private
String
analysisBatchId
;
@ApiModelProperty
(
"单元设备id"
)
private
String
unitId
;
@ApiModelProperty
(
"单元设备code"
)
private
String
unitCode
;
@ApiModelProperty
(
"设备单元类型1-钢轨,2-曲线,3-竖曲线,4-道岔"
)
private
Integer
unitType
;
@ApiModelProperty
(
"设备单元类型名称"
)
private
String
unitTypeName
;
@ApiModelProperty
(
"派工原因"
)
private
Integer
workReason
;
@ApiModelProperty
(
"备注"
)
private
String
remark
;
}
jeecg-module-system/src/main/java/org/jeecg/modules/dynamicStaticAnalysis/other/AnalysisBatchUnitDeviceWorkVO.java
deleted
100644 → 0
View file @
06942fdb
package
org
.
jeecg
.
modules
.
dynamicStaticAnalysis
.
entity
;
import
com.baomidou.mybatisplus.annotation.TableField
;
import
com.baomidou.mybatisplus.annotation.TableId
;
import
com.baomidou.mybatisplus.annotation.TableName
;
import
java.io.Serializable
;
import
java.util.Date
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Getter
;
import
lombok.Setter
;
/**
* <p>
* 动静态分析-分析批次-单元设备派工表
* </p>
*
* @author hkl
* @since 2023-08-30
*/
@Getter
@Setter
@ApiModel
(
value
=
"AnalysisBatchUnitDeviceWork对象"
,
description
=
"动静态分析-分析批次-单元设备派工表"
)
public
class
AnalysisBatchUnitDeviceWorkVO
{
private
static
final
long
serialVersionUID
=
1L
;
@ApiModelProperty
(
"主键"
)
@TableId
(
"id"
)
private
String
id
;
@ApiModelProperty
(
"创建人"
)
@TableField
(
"create_by"
)
private
String
createBy
;
@ApiModelProperty
(
"创建日期"
)
@TableField
(
"create_time"
)
private
Date
createTime
;
@ApiModelProperty
(
"更新人"
)
@TableField
(
"update_by"
)
private
String
updateBy
;
@ApiModelProperty
(
"更新时间"
)
@TableField
(
"update_time"
)
private
Date
updateTime
;
@ApiModelProperty
(
"分析批次单元设备id"
)
@TableField
(
"analysis_batch_unit_device_id"
)
private
String
analysisBatchUnitDeviceId
;
@ApiModelProperty
(
"分析批次号"
)
@TableField
(
"analysis_batch_code"
)
private
String
analysisBatchCode
;
@ApiModelProperty
(
"分析批id"
)
@TableField
(
"analysis_batch_id"
)
private
String
analysisBatchId
;
@ApiModelProperty
(
"单元设备id"
)
@TableField
(
"unit_id"
)
private
String
unitId
;
@ApiModelProperty
(
"单元设备code"
)
@TableField
(
"unit_code"
)
private
String
unitCode
;
@ApiModelProperty
(
"设备单元类型1-钢轨,2-曲线,3-竖曲线,4-道岔"
)
@TableField
(
"unit_type"
)
private
Integer
unitType
;
@ApiModelProperty
(
"设备单元类型名称"
)
@TableField
(
"unit_type_name"
)
private
String
unitTypeName
;
@ApiModelProperty
(
"派工原因"
)
@TableField
(
"work_reason"
)
private
Integer
workReason
;
@ApiModelProperty
(
"备注"
)
@TableField
(
"remark"
)
private
String
remark
;
}
jeecg-module-system/src/main/java/org/jeecg/modules/dynamicStaticAnalysis/service/IConfigTqiLimitService.java
0 → 100644
View file @
fe473b97
package
org
.
jeecg
.
modules
.
dynamicStaticAnalysis
.
service
;
import
com.baomidou.mybatisplus.extension.service.IService
;
import
org.jeecg.modules.dynamicStaticAnalysis.entity.ConfigTqiLimit
;
/**
* <p>
* 动静态分析-配置-TQI管理标准顺质量指数 服务类
* </p>
*
* @author hkl
* @since 2023-09-15
*/
public
interface
IConfigTqiLimitService
extends
IService
<
ConfigTqiLimit
>
{
}
jeecg-module-system/src/main/java/org/jeecg/modules/dynamicStaticAnalysis/service/impl/ConfigTqiLimitServiceImpl.java
0 → 100644
View file @
fe473b97
package
org
.
jeecg
.
modules
.
dynamicStaticAnalysis
.
service
.
impl
;
import
org.jeecg.modules.dynamicStaticAnalysis.entity.ConfigTqiLimit
;
import
org.jeecg.modules.dynamicStaticAnalysis.mapper.ConfigTqiLimitMapper
;
import
org.jeecg.modules.dynamicStaticAnalysis.service.IConfigTqiLimitService
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
org.jeecg.modules.dynamicStaticAnalysis.vo.ConfigTqiLimitVO
;
import
org.springframework.stereotype.Service
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.stream.Collectors
;
/**
* <p>
* 动静态分析-配置-TQI管理标准顺质量指数 服务实现类
* </p>
*
* @author hkl
* @since 2023-09-15
*/
@Service
public
class
ConfigTqiLimitServiceImpl
extends
ServiceImpl
<
ConfigTqiLimitMapper
,
ConfigTqiLimit
>
implements
IConfigTqiLimitService
{
}
jeecg-module-system/src/main/java/org/jeecg/modules/dynamicStaticAnalysis/vo/ConfigTqiLimitVO.java
0 → 100644
View file @
fe473b97
package
org
.
jeecg
.
modules
.
dynamicStaticAnalysis
.
vo
;
import
com.baomidou.mybatisplus.annotation.TableField
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
import
org.jeecg.modules.dynamicStaticAnalysis.entity.ConfigTqiLimit
;
import
java.util.List
;
@Data
@ApiModel
(
value
=
"ConfigTqiLimitVO对象"
,
description
=
"动静态分析-检查批次VO"
)
public
class
ConfigTqiLimitVO
{
@ApiModelProperty
(
"超标类型 1-超标≤10% 2-超标≤20% 3-超标>20%"
)
@TableField
(
"over_standard_type"
)
private
Integer
overStandardType
;
@ApiModelProperty
(
"评价等级中文说明"
)
@TableField
(
"over_standard_type_str"
)
private
String
overStandardTypeStr
;
@ApiModelProperty
(
"对应权值"
)
private
List
<
ConfigTqiLimit
>
configTqiLimits
;
}
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