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
e87d9c9d
Commit
e87d9c9d
authored
Aug 16, 2023
by
hkl
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat: 1.车站bug提交
parent
6c121853
Changes
7
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
200 additions
and
75 deletions
+200
-75
MovementRecordsMasterController.java
...CheckData/controller/MovementRecordsMasterController.java
+21
-18
AnalysisAlgorithm.java
...es/dynamicStaticAnalysis/algorithm/AnalysisAlgorithm.java
+108
-35
ConfigGradeLimit.java
...odules/dynamicStaticAnalysis/entity/ConfigGradeLimit.java
+10
-3
AnalysisBatchUnitDeviceMapper.xml
...aticAnalysis/mapper/xml/AnalysisBatchUnitDeviceMapper.xml
+25
-0
ConfigGradeLimitServiceImpl.java
...ticAnalysis/service/impl/ConfigGradeLimitServiceImpl.java
+20
-8
TrainStationQueryDTO.java
...jeecg/modules/subwayNetwork/dto/TrainStationQueryDTO.java
+4
-0
TrainStationMapper.xml
...g/modules/subwayNetwork/mapper/xml/TrainStationMapper.xml
+12
-11
No files found.
jeecg-module-system/src/main/java/org/jeecg/modules/checkData/equipmentCheckData/controller/MovementRecordsMasterController.java
View file @
e87d9c9d
...
...
@@ -588,6 +588,8 @@ public class MovementRecordsMasterController extends JeecgController<MovementRec
if
(
measurePoint
%
8
==
0
)
{
measurePoint
=
1
;
trackCode
=
String
.
valueOf
(
Integer
.
valueOf
(
trackCode
)
+
1
);
}
else
{
measurePoint
++;
}
movementCourseInfos
.
add
(
movementCourseInfo
);
}
...
...
@@ -784,7 +786,7 @@ public class MovementRecordsMasterController extends JeecgController<MovementRec
@AutoLog
(
value
=
"轨检车详情查询"
)
@ApiOperation
(
value
=
"轨检车详情查询"
,
notes
=
"轨检车详情查询"
)
@GetMapping
(
value
=
"/getTrackInfo"
)
public
Result
<
Map
<
String
,
Object
>>
getTrackInfo
(
@ApiParam
(
name
=
"动静态几何尺寸数据id"
)
String
id
,
@ApiParam
(
name
=
"查询类型"
)
String
type
,
@ApiParam
(
name
=
"轨检车->超限查询子类型"
)
String
overType
)
{
public
Result
<
Map
<
String
,
Object
>>
getTrackInfo
(
@ApiParam
(
name
=
"动静态几何尺寸数据id"
)
String
id
,
@ApiParam
(
name
=
"查询类型"
)
String
type
,
@ApiParam
(
name
=
"轨检车->超限查询子类型"
)
String
overType
)
{
Map
<
String
,
Object
>
map
=
new
HashMap
<>();
if
(
"1"
.
equals
(
type
))
{
//轨检车-》轨道动态几何尺寸容许值差管理值
...
...
@@ -907,11 +909,11 @@ public class MovementRecordsMasterController extends JeecgController<MovementRec
//处理200m区段轨道不平顺质量指数TQI管理标准(单位:mm)解析封装逻辑
int
dataOne
=
this
.
uploadMovementTqiStandardManager
(
movementTqiStandardManagerList
,
i
,
sort
,
realname
,
rowRecords
,
id
);
i
=
i
+
dataOne
;
}
else
if
(
str
.
equals
(
"TQI公里状态评定标准"
))
{
}
else
if
(
str
.
equals
(
"TQI公里状态评定标准"
))
{
//处理TQI公里状态评定标准解析封装逻辑
int
dataOne
=
this
.
uploadMovementTqiKilometerStandardManager
(
movementTqiKilometerStandardManagerList
,
i
,
sort
,
realname
,
rowRecords
,
id
);
i
=
i
+
dataOne
;
}
else
if
(
str
.
equals
(
"四级缺陷记录报告表"
)
||
str
.
equals
(
"三级缺陷记录报告表"
)
||
str
.
equals
(
"二级缺陷记录报告表"
)
||
str
.
equals
(
"一级缺陷记录报告表"
))
{
}
else
if
(
str
.
equals
(
"四级缺陷记录报告表"
)
||
str
.
equals
(
"三级缺陷记录报告表"
)
||
str
.
equals
(
"二级缺陷记录报告表"
)
||
str
.
equals
(
"一级缺陷记录报告表"
))
{
//处理超限记录报告解析封装逻辑
int
dataOne
=
this
.
uploadMovementOverReport
(
movementOverReportList
,
i
,
sort
,
realname
,
rowRecords
,
id
);
i
=
i
+
dataOne
;
...
...
@@ -985,14 +987,14 @@ public class MovementRecordsMasterController extends JeecgController<MovementRec
/**
* @param movementTqiStandardManagerList 最终的TQI公里状态评定标准集合
* @param i 当前行坐标
* @param sort 顺序
* @param realname 当前登录人姓名
* @param rowRecords 总行列数据集合
* @param id 主表id
* @param i
当前行坐标
* @param sort
顺序
* @param realname
当前登录人姓名
* @param rowRecords
总行列数据集合
* @param id
主表id
*/
public
int
uploadMovementTqiKilometerStandardManager
(
List
<
MovementTqiKilometerStandardManager
>
movementTqiStandardManagerList
,
int
i
,
int
sort
,
String
realname
,
List
<
List
<
Object
>>
rowRecords
,
String
id
)
{
String
regEx
=
"[^0-9 .]"
;
String
regEx
=
"[^0-9 .]"
;
Pattern
p
=
Pattern
.
compile
(
regEx
);
int
dataOne
=
0
;
for
(
int
j
=
i
+
2
;
j
<
rowRecords
.
size
();
j
++)
{
...
...
@@ -1061,16 +1063,17 @@ public class MovementRecordsMasterController extends JeecgController<MovementRec
}
return
dataOne
;
}
/**
* @param movementTqiStandardManagerList 最终的200m区段轨道不平顺质量指数TQI管理标准(单位:mm)集合
* @param i 当前行坐标
* @param sort 顺序
* @param realname 当前登录人姓名
* @param rowRecords 总行列数据集合
* @param id 主表id
* @param i
当前行坐标
* @param sort
顺序
* @param realname
当前登录人姓名
* @param rowRecords
总行列数据集合
* @param id
主表id
*/
public
int
uploadMovementTqiStandardManager
(
List
<
MovementTqiStandardManager
>
movementTqiStandardManagerList
,
int
i
,
int
sort
,
String
realname
,
List
<
List
<
Object
>>
rowRecords
,
String
id
)
{
String
regEx
=
"[^0-9 .]"
;
String
regEx
=
"[^0-9 .]"
;
Pattern
p
=
Pattern
.
compile
(
regEx
);
int
dataOne
=
0
;
for
(
int
j
=
i
+
3
;
j
<
rowRecords
.
size
();
j
++)
{
...
...
@@ -1323,7 +1326,7 @@ public class MovementRecordsMasterController extends JeecgController<MovementRec
gaugeChange
=
rowRecords
.
get
(
j
).
get
(
98
).
toString
().
trim
();
if
(
ObjectUtil
.
isNotEmpty
(
gaugeChange
))
{
model
.
setGaugeChange
(
gaugeChange
);
}
else
{
}
else
{
model
.
setGaugeChange
(
""
);
}
//曲率变化率
...
...
@@ -1331,7 +1334,7 @@ public class MovementRecordsMasterController extends JeecgController<MovementRec
curvatureChange
=
rowRecords
.
get
(
j
).
get
(
111
).
toString
().
trim
();
if
(
ObjectUtil
.
isNotEmpty
(
curvatureChange
))
{
model
.
setCurvatureChange
(
curvatureChange
);
}
else
{
}
else
{
model
.
setCurvatureChange
(
""
);
}
//扣分标准
...
...
@@ -1339,7 +1342,7 @@ public class MovementRecordsMasterController extends JeecgController<MovementRec
deductStandard
=
rowRecords
.
get
(
j
).
get
(
122
).
toString
().
trim
();
if
(
ObjectUtil
.
isNotEmpty
(
deductStandard
))
{
model
.
setDeductStandard
(
deductStandard
);
}
else
{
}
else
{
model
.
setDeductStandard
(
""
);
}
movementDiferenceManagerList
.
add
(
model
);
...
...
jeecg-module-system/src/main/java/org/jeecg/modules/dynamicStaticAnalysis/algorithm/AnalysisAlgorithm.java
View file @
e87d9c9d
...
...
@@ -4,6 +4,7 @@ import cn.hutool.core.convert.Convert;
import
cn.hutool.core.util.ObjectUtil
;
import
com.alibaba.fastjson.JSONArray
;
import
com.alibaba.fastjson.JSONObject
;
import
lombok.extern.slf4j.Slf4j
;
import
org.jeecg.common.util.UUIDGenerator
;
import
org.jeecg.modules.checkData.dynamicStaticGeometricData.entity.RailInspectionEquipmentItem
;
import
org.jeecg.modules.checkData.dynamicStaticGeometricData.entity.RailInspectionEquipmentItemDetail
;
...
...
@@ -33,6 +34,7 @@ import java.util.stream.Collectors;
* 分析算法
*/
@Service
@Slf4j
public
class
AnalysisAlgorithm
{
@Resource
private
AnalysisAlgorithmMapper
analysisAlgorithmMapper
;
...
...
@@ -62,6 +64,8 @@ public class AnalysisAlgorithm {
private
IConfigRailDeviceCheckService
configRailDeviceCheckService
;
@Resource
private
IMovementOverReportService
movementOverReportService
;
@Resource
private
IConfigGradeLimitService
iConfigGradeLimitService
;
public
void
analysis
(
String
analysisBatchId
)
{
Map
<
String
,
Map
<
String
,
Object
>>
unitDeviceTable
=
new
TreeMap
<>();
...
...
@@ -125,7 +129,15 @@ public class AnalysisAlgorithm {
// 3.1 保存分析批次-单元设备
List
<
ConfigGradeLimit
>
configGradeLimitList
=
iConfigGradeLimitService
.
lambdaQuery
()
.
eq
(
ConfigGradeLimit:
:
getSpeedMax
,
analysisBatch
.
getSpeedMax
())
.
eq
(
ConfigGradeLimit:
:
getSpeedMin
,
analysisBatch
.
getSpeedMin
())
.
eq
(
ConfigGradeLimit:
:
getDelFlag
,
'0'
)
.
list
();
List
<
AnalysisBatchUnitDevice
>
analysisBatchUnitDevices
=
new
ArrayList
<>();
List
<
AnalysisBatchUnitDeviceTransfinite
>
transfiniteList
=
new
ArrayList
<>();
List
<
AnalysisBatchUnitDevicePointScore
>
scoreList
=
new
ArrayList
<>();
for
(
Map
.
Entry
<
String
,
Map
<
String
,
Object
>>
entry
:
unitDeviceTable
.
entrySet
())
{
Map
<
String
,
Object
>
unitDevice
=
entry
.
getValue
();
AnalysisBatchUnitDevice
analysisBatchUnitDevice
=
new
AnalysisBatchUnitDevice
();
...
...
@@ -140,54 +152,110 @@ public class AnalysisAlgorithm {
analysisBatchUnitDevice
.
setUnitStartMileage
(
Convert
.
toBigDecimal
(
unitDevice
.
get
(
"startMileage"
)));
analysisBatchUnitDevice
.
setUnitCenterMileage
(
Convert
.
toBigDecimal
(
unitDevice
.
get
(
"centerMileage"
)));
analysisBatchUnitDevice
.
setUnitEndMileage
(
Convert
.
toBigDecimal
(
unitDevice
.
get
(
"endMileage"
)));
Object
labourCheckData
=
unitDevice
.
get
(
"labourCheck"
);
if
(
ObjectUtil
.
isNotEmpty
(
labourCheckData
))
{
analysisBatchUnitDevice
.
setLabourCheck
(
1
);
}
else
{
analysisBatchUnitDevice
.
setLabourCheck
(
0
);
}
analysisBatchUnitDevices
.
add
(
analysisBatchUnitDevice
);
// 计算总得分
BigDecimal
unitScore
=
null
;
// 人工检查得分
BigDecimal
labourCheckScore
=
(
BigDecimal
)
unitDevice
.
get
(
"labourCheckScore"
);
// -1代表未评分
if
(
labourCheckScore
==
null
)
{
analysisBatchUnitDevice
.
setLabourCheck
(
0
);
analysisBatchUnitDevice
.
setLabourCheckScore
(
new
BigDecimal
(
"-1"
));
}
else
{
analysisBatchUnitDevice
.
setLabourCheck
(
1
);
analysisBatchUnitDevice
.
setLabourCheckScore
(
labourCheckScore
);
// 先写死
analysisBatchUnitDevice
.
setUnitScore
(
labourCheckScore
);
analysisBatchUnitDevice
.
setUnitScoreLevel
(
3
);
analysisBatchUnitDevice
.
setUnitScoreLevelStr
(
"失格"
);
unitScore
=
labourCheckScore
;
}
Object
railDeviceData
=
unitDevice
.
get
(
"railDevice"
);
if
(
ObjectUtil
.
isNotEmpty
(
railDeviceData
))
{
// 轨检仪检查得分
BigDecimal
railDeviceCheckScore
=
(
BigDecimal
)
unitDevice
.
get
(
"railDeviceCheckScore"
);
if
(
null
==
railDeviceCheckScore
)
{
analysisBatchUnitDevice
.
setRailDeviceCheck
(
0
);
analysisBatchUnitDevice
.
setAddDeviceCheckScore
(
new
BigDecimal
(
"-1"
));
}
else
{
analysisBatchUnitDevice
.
setRailDeviceCheck
(
1
);
analysisBatchUnitDevice
.
setAddDeviceCheckScore
(
railDeviceCheckScore
);
if
(
unitScore
==
null
)
{
unitScore
=
railDeviceCheckScore
;
}
else
{
unitScore
=
unitScore
.
add
(
railDeviceCheckScore
);
}
}
// 计算总分
Integer
unitScoreLevel
=
null
;
String
unitScoreLevelStr
=
"结果为空"
;
if
(
unitScore
!=
null
)
{
for
(
ConfigGradeLimit
configGradeLimit
:
configGradeLimitList
)
{
// 匹配单元设备类型
if
(
analysisBatchUnitDevice
.
getUnitType
()
==
configGradeLimit
.
getDeviceType
())
{
// 匹配等级
if
(
configGradeLimit
.
getGradeMin
().
compareTo
(
unitScore
)
<=
0
&&
configGradeLimit
.
getGradeMax
().
compareTo
(
unitScore
)
>
0
)
{
unitScoreLevel
=
configGradeLimit
.
getGradeLevel
();
unitScoreLevelStr
=
configGradeLimit
.
getGradeLevelStr
();
break
;
}
}
}
}
else
{
analysisBatchUnitDevice
.
setRailDeviceCheck
(
0
);
unitScore
=
new
BigDecimal
(
"-1"
);
unitScoreLevelStr
=
"暂无数据记录"
;
unitScoreLevel
=
4
;
}
// -1代表未评分
analysisBatchUnitDevice
.
setUnitScore
(
unitScore
);
analysisBatchUnitDevice
.
setUnitScoreLevel
(
unitScoreLevel
);
analysisBatchUnitDevice
.
setUnitScoreLevelStr
(
unitScoreLevelStr
);
// 保存人工检查数据超限
AnalysisBatchUnitDeviceTransfinite
labourCheckTransfinite
=
(
AnalysisBatchUnitDeviceTransfinite
)
unitDevice
.
get
(
"labourCheckTransfinite"
);
if
(
ObjectUtil
.
isNotEmpty
(
labourCheckTransfinite
))
{
labourCheckTransfinite
.
setAnalysisBatchUnitDeviceId
(
analysisBatchUnitDevice
.
getId
());
labourCheckTransfinite
.
setAnalysisBatchId
(
analysisBatchUnitDevice
.
getAnalysisBatchId
());
labourCheckTransfinite
.
setAnalysisBatchCode
(
analysisBatchUnitDevice
.
getAnalysisBatchCode
());
labourCheckTransfinite
.
setUnitId
(
analysisBatchUnitDevice
.
getUnitId
());
labourCheckTransfinite
.
setUnitCode
(
analysisBatchUnitDevice
.
getUnitCode
());
labourCheckTransfinite
.
setUnitType
(
analysisBatchUnitDevice
.
getUnitType
());
labourCheckTransfinite
.
setUnitTypeName
(
analysisBatchUnitDevice
.
getUnitTypeName
());
transfiniteList
.
add
(
labourCheckTransfinite
);
}
// 保存人工检查数据计算得分
List
<
AnalysisBatchUnitDevicePointScore
>
labourCheckScoreList
=
(
List
<
AnalysisBatchUnitDevicePointScore
>)
unitDevice
.
get
(
"labourCheckScoreList"
);
if
(
ObjectUtil
.
isNotEmpty
(
labourCheckScoreList
))
{
for
(
AnalysisBatchUnitDevicePointScore
score
:
labourCheckScoreList
)
{
score
.
setAnalysisBatchUnitDeviceId
(
analysisBatchUnitDevice
.
getId
());
score
.
setAnalysisBatchId
(
analysisBatchUnitDevice
.
getAnalysisBatchId
());
score
.
setAnalysisBatchCode
(
analysisBatchUnitDevice
.
getAnalysisBatchCode
());
score
.
setUnitId
(
analysisBatchUnitDevice
.
getUnitId
());
score
.
setUnitCode
(
analysisBatchUnitDevice
.
getUnitCode
());
score
.
setUnitType
(
analysisBatchUnitDevice
.
getUnitType
());
score
.
setUnitTypeName
(
analysisBatchUnitDevice
.
getUnitTypeName
());
}
scoreList
.
addAll
(
labourCheckScoreList
);
}
analysisBatchUnitDevices
.
add
(
analysisBatchUnitDevice
);
// 保存超限
Object
transfiniteData
=
unitDevice
.
get
(
"labourCheckTransfinite"
);
if
(
ObjectUtil
.
isNotEmpty
(
transfiniteData
))
{
AnalysisBatchUnitDeviceTransfinite
transfinite
=
(
AnalysisBatchUnitDeviceTransfinite
)
transfiniteData
;
transfinite
.
setAnalysisBatchUnitDeviceId
(
analysisBatchUnitDevice
.
getId
());
transfinite
.
setAnalysisBatchId
(
analysisBatchUnitDevice
.
getAnalysisBatchId
());
transfinite
.
setAnalysisBatchCode
(
analysisBatchUnitDevice
.
getAnalysisBatchCode
());
transfinite
.
setUnitId
(
analysisBatchUnitDevice
.
getUnitId
());
transfinite
.
setUnitCode
(
analysisBatchUnitDevice
.
getUnitCode
());
transfinite
.
setUnitType
(
analysisBatchUnitDevice
.
getUnitType
());
transfinite
.
setUnitTypeName
(
analysisBatchUnitDevice
.
getUnitTypeName
());
analysisBatchUnitDeviceTransfiniteService
.
save
(
transfinite
);
// 保存轨检仪检查数据超限
AnalysisBatchUnitDeviceTransfinite
railDeviceTransfinite
=
(
AnalysisBatchUnitDeviceTransfinite
)
unitDevice
.
get
(
"railDeviceTransfinite"
);
if
(
ObjectUtil
.
isNotEmpty
(
railDeviceTransfinite
))
{
railDeviceTransfinite
.
setAnalysisBatchUnitDeviceId
(
analysisBatchUnitDevice
.
getId
());
railDeviceTransfinite
.
setAnalysisBatchId
(
analysisBatchUnitDevice
.
getAnalysisBatchId
());
railDeviceTransfinite
.
setAnalysisBatchCode
(
analysisBatchUnitDevice
.
getAnalysisBatchCode
());
railDeviceTransfinite
.
setUnitId
(
analysisBatchUnitDevice
.
getUnitId
());
railDeviceTransfinite
.
setUnitCode
(
analysisBatchUnitDevice
.
getUnitCode
());
railDeviceTransfinite
.
setUnitType
(
analysisBatchUnitDevice
.
getUnitType
());
railDeviceTransfinite
.
setUnitTypeName
(
analysisBatchUnitDevice
.
getUnitTypeName
());
transfiniteList
.
add
(
railDeviceTransfinite
);
}
// 保存人工计算得分
List
<
AnalysisBatchUnitDevicePointScore
>
scoreList
=
(
List
<
AnalysisBatchUnitDevicePointScore
>)
unitDevice
.
get
(
"labourCheckScoreList"
);
if
(
ObjectUtil
.
isNotEmpty
(
scoreList
))
{
for
(
AnalysisBatchUnitDevicePointScore
score
:
scoreList
)
{
// 保存轨检仪检检查数据计算得分
List
<
AnalysisBatchUnitDevicePointScore
>
railDeviceCheckScoreList
=
(
List
<
AnalysisBatchUnitDevicePointScore
>)
unitDevice
.
get
(
"railDeviceCheckScoreList"
);
if
(
ObjectUtil
.
isNotEmpty
(
railDeviceCheckScoreList
))
{
for
(
AnalysisBatchUnitDevicePointScore
score
:
railDeviceCheckScoreList
)
{
score
.
setAnalysisBatchUnitDeviceId
(
analysisBatchUnitDevice
.
getId
());
score
.
setAnalysisBatchId
(
analysisBatchUnitDevice
.
getAnalysisBatchId
());
score
.
setAnalysisBatchCode
(
analysisBatchUnitDevice
.
getAnalysisBatchCode
());
...
...
@@ -196,16 +264,21 @@ public class AnalysisAlgorithm {
score
.
setUnitType
(
analysisBatchUnitDevice
.
getUnitType
());
score
.
setUnitTypeName
(
analysisBatchUnitDevice
.
getUnitTypeName
());
}
analysisBatchUnitDevicePointScoreService
.
saveBatch
(
s
coreList
);
scoreList
.
addAll
(
railDeviceCheckS
coreList
);
}
}
analysisBatchUnitDeviceService
.
saveBatch
(
analysisBatchUnitDevices
);
analysisBatchUnitDeviceTransfiniteService
.
saveBatch
(
transfiniteList
);
analysisBatchUnitDevicePointScoreService
.
saveBatch
(
scoreList
);
}
// 分析完成
analysisBatchService
.
lambdaUpdate
().
set
(
AnalysisBatch:
:
getAnalysisStatus
,
99
)
.
eq
(
AnalysisBatch:
:
getId
,
analysisBatchId
)
.
update
();
log
.
info
(
"[分析完成]|线程id:【"
+
Thread
.
currentThread
().
getId
()
+
"】=============分析批次ID:【"
+
analysisBatchId
+
"】"
);
}
/**
...
...
@@ -323,7 +396,7 @@ public class AnalysisAlgorithm {
if
(
null
==
transfinite
)
{
transfinite
=
this
.
railDeviceCheckTransfinite
(
analysisBatch
,
movementCourseInfo
);
}
else
{
unitDevice
.
put
(
"
labourCheck
Transfinite"
,
transfinite
);
unitDevice
.
put
(
"
railDevice
Transfinite"
,
transfinite
);
}
}
...
...
jeecg-module-system/src/main/java/org/jeecg/modules/dynamicStaticAnalysis/entity/ConfigGradeLimit.java
View file @
e87d9c9d
...
...
@@ -3,8 +3,11 @@ 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
;
...
...
@@ -62,17 +65,21 @@ public class ConfigGradeLimit implements Serializable {
@TableField
(
"dict_label"
)
private
String
dictLabel
;
@ApiModelProperty
(
"评价等级 1-优良 2-合格 3-失格
"
)
@ApiModelProperty
(
"评价等级 1-优良 2-合格 3-失格"
)
@TableField
(
"grade_level"
)
private
Integer
gradeLevel
;
@ApiModelProperty
(
"评价等级中文说明"
)
@TableField
(
"grade_level_str"
)
private
String
gradeLevelStr
;
@ApiModelProperty
(
"最小评分"
)
@TableField
(
"grade_min"
)
private
Integer
gradeMin
;
private
BigDecimal
gradeMin
;
@ApiModelProperty
(
"最大评分"
)
@TableField
(
"grade_max"
)
private
Integer
gradeMax
;
private
BigDecimal
gradeMax
;
@ApiModelProperty
(
"设备类型 1-钢轨 2-道岔 3-曲线 4-竖曲线"
)
@TableField
(
"device_type"
)
...
...
jeecg-module-system/src/main/java/org/jeecg/modules/dynamicStaticAnalysis/mapper/xml/AnalysisBatchUnitDeviceMapper.xml
View file @
e87d9c9d
...
...
@@ -47,8 +47,33 @@
#{item}
</foreach>
</if>
<if
test=
"dto.gradeJudgeList!=null and dto.gradeJudgeList.size()>0"
>
AND analysis.unit_score_level in
<foreach
collection=
"dto.gradeJudgeList"
index=
"index"
item=
"item"
open=
"("
separator=
","
close=
")"
>
#{item}
</foreach>
</if>
<if
test=
"dto.unitTypeList!=null and dto.unitTypeList.size()>0"
>
AND analysis.unit_type in
<foreach
collection=
"dto.unitTypeList"
index=
"index"
item=
"item"
open=
"("
separator=
","
close=
")"
>
#{item}
</foreach>
</if>
<if
test=
"dto.isTransfinite != null"
>
AND analysis.is_transfinite = 1
</if>
<if
test=
"dto.unitStartingMileage != null"
>
AND analysis.unit_starting_mileage >= #{dto.unitStartingMileage }
</if>
<if
test=
"dto.unitEndMileage != null"
>
AND analysis.unit_end_mileage
<![CDATA[ <= ]]>
#{dto.unitEndMileage}
</if>
<if
test=
"dto.unitCode != null and dto.unitCode != ''"
>
AND analysis.unit_code like concat('%',#{dto.unitCode},'%')
</if>
<if
test=
"dto.unitDeviceCode != null and dto.unitDeviceCode != ''"
>
AND analysis.unit_device_code like concat('%',#{dto.unitDeviceCode},'%')
</if>
order by unit_starting_mileage
</select>
</mapper>
jeecg-module-system/src/main/java/org/jeecg/modules/dynamicStaticAnalysis/service/impl/ConfigGradeLimitServiceImpl.java
View file @
e87d9c9d
...
...
@@ -2,14 +2,14 @@ package org.jeecg.modules.dynamicStaticAnalysis.service.impl;
import
cn.hutool.core.util.ObjectUtil
;
import
com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper
;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
com.baomidou.mybatisplus.core.toolkit.Wrappers
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
org.jeecg.common.util.UUIDGenerator
;
import
org.jeecg.modules.constant.DictConstant
;
import
org.jeecg.modules.dynamicStaticAnalysis.entity.ConfigGradeLimit
;
import
org.jeecg.modules.dynamicStaticAnalysis.mapper.ConfigGradeLimitMapper
;
import
org.jeecg.modules.dynamicStaticAnalysis.service.IConfigGradeLimitService
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImp
l
;
import
org.jeecg.modules.dynamicStaticAnalysis.util.StrUti
l
;
import
org.jeecg.modules.system.entity.SysDict
;
import
org.jeecg.modules.system.entity.SysDictItem
;
import
org.jeecg.modules.system.mapper.SysDictItemMapper
;
...
...
@@ -17,6 +17,7 @@ import org.jeecg.modules.system.mapper.SysDictMapper;
import
org.springframework.stereotype.Service
;
import
javax.annotation.Resource
;
import
java.math.BigDecimal
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.stream.Collectors
;
...
...
@@ -73,15 +74,20 @@ public class ConfigGradeLimitServiceImpl extends ServiceImpl<ConfigGradeLimitMap
List
<
Integer
>
deviceTypeList
=
IntStream
.
range
(
1
,
5
).
boxed
().
collect
(
Collectors
.
toList
());
for
(
Integer
deviceType
:
deviceTypeList
)
{
for
(
SysDictItem
sysDictItem
:
sysDictItems
)
{
Integer
[]
speedLevels
=
StrUtil
.
getSpeedLevel
(
sysDictItem
.
getItemText
());
// 优良
ConfigGradeLimit
a
=
new
ConfigGradeLimit
();
a
.
setId
(
UUIDGenerator
.
generate
());
a
.
setDictLabel
(
sysDictItem
.
getItemText
());
a
.
setDictValue
(
sysDictItem
.
getItemValue
());
a
.
setSpeedMin
(
speedLevels
[
0
]);
a
.
setSpeedMax
(
speedLevels
[
1
]);
a
.
setDeviceType
(
deviceType
);
a
.
setGradeLevel
(
1
);
//1-优良
a
.
setGradeMin
(
0
);
a
.
setGradeMax
(
100
);
a
.
setGradeLevelStr
(
"优良"
);
a
.
setGradeMin
(
new
BigDecimal
(
"0"
));
a
.
setGradeMax
(
new
BigDecimal
(
"15"
));
result
.
add
(
a
);
// 合格
...
...
@@ -89,10 +95,13 @@ public class ConfigGradeLimitServiceImpl extends ServiceImpl<ConfigGradeLimitMap
b
.
setId
(
UUIDGenerator
.
generate
());
b
.
setDictLabel
(
sysDictItem
.
getItemText
());
b
.
setDictValue
(
sysDictItem
.
getItemValue
());
b
.
setSpeedMin
(
speedLevels
[
0
]);
b
.
setSpeedMax
(
speedLevels
[
1
]);
b
.
setDeviceType
(
deviceType
);
b
.
setGradeLevel
(
2
);
//2-合格
b
.
setGradeMin
(
100
);
b
.
setGradeMax
(
200
);
b
.
setGradeLevelStr
(
"合格"
);
b
.
setGradeMin
(
new
BigDecimal
(
"15"
));
b
.
setGradeMax
(
new
BigDecimal
(
"20"
));
result
.
add
(
b
);
// 失格
...
...
@@ -100,10 +109,13 @@ public class ConfigGradeLimitServiceImpl extends ServiceImpl<ConfigGradeLimitMap
c
.
setId
(
UUIDGenerator
.
generate
());
c
.
setDictLabel
(
sysDictItem
.
getItemText
());
c
.
setDictValue
(
sysDictItem
.
getItemValue
());
c
.
setSpeedMin
(
speedLevels
[
0
]);
c
.
setSpeedMax
(
speedLevels
[
1
]);
c
.
setDeviceType
(
deviceType
);
c
.
setGradeLevel
(
3
);
//3-失格
c
.
setGradeMin
(
200
);
c
.
setGradeMax
(
99999
);
c
.
setGradeLevelStr
(
"失格"
);
c
.
setGradeMin
(
new
BigDecimal
(
"20"
));
c
.
setGradeMax
(
new
BigDecimal
(
"99999"
));
result
.
add
(
c
);
}
...
...
jeecg-module-system/src/main/java/org/jeecg/modules/subwayNetwork/dto/TrainStationQueryDTO.java
View file @
e87d9c9d
...
...
@@ -21,4 +21,8 @@ public class TrainStationQueryDTO {
@ApiModelProperty
(
value
=
"线别id"
)
private
String
lineAliasId
;
@ApiModelProperty
(
value
=
"线路Id"
)
private
String
railLine
;
}
jeecg-module-system/src/main/java/org/jeecg/modules/subwayNetwork/mapper/xml/TrainStationMapper.xml
View file @
e87d9c9d
...
...
@@ -9,7 +9,7 @@
t1.light_rail_id,
t2.rail_line_name light_rail_name,
t1.line_alias_id,
(SELECT line_alias_name FROM t_sn_line_alias WHERE id =
t1.line_alias_id
limit 1) line_alias_name,
(SELECT line_alias_name FROM t_sn_line_alias WHERE id =
t1.line_alias_id
limit 1) line_alias_name,
t1.starting_mileage,
t1.center_mileage,
t1.end_mileage,
...
...
@@ -19,18 +19,19 @@
t1.update_time,
t1.length,
t1.seq,
t1.remark
t1.remark
FROM t_sn_train_station t1
LEFT JOIN t_sn_light_rail t2 ON t1.light_rail_id = t2.id
<where>
<if
test=
"query.stationName !=null and query.stationName!=''"
>
AND t1.station_name like concat('%',#{query.stationName},'%')
</if>
<if
test=
"query.lineAliasId !=null and query.lineAliasId!=''"
>
AND t1.line_alias_id = #{query.lineAliasId}
</if>
AND t2.status = 1
</where>
WHERE t2.status = 1
<if
test=
"query.stationName !=null and query.stationName!=''"
>
AND t1.station_name like concat('%',#{query.stationName},'%')
</if>
<if
test=
"query.lineAliasId !=null and query.lineAliasId!=''"
>
AND t1.line_alias_id = #{query.lineAliasId}
</if>
<if
test=
"query.railLine !=null and query.railLine!=''"
>
AND t1.light_rail_id = #{query.railLine}
</if>
</select>
<select
id=
"getTreeTrainStationList"
resultType=
"org.jeecg.modules.subwayNetwork.vo.SectionStationNode"
>
SELECT
...
...
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