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
fc1b3bc8
Commit
fc1b3bc8
authored
Mar 07, 2023
by
chenzhao
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改代码
parent
16ef8398
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
18 additions
and
64 deletions
+18
-64
AlertCalledFeedbackServiceImpl.java
.../jcs/biz/service/impl/AlertCalledFeedbackServiceImpl.java
+0
-1
AlertCalledServiceImpl.java
...t/module/jcs/biz/service/impl/AlertCalledServiceImpl.java
+18
-63
AlertSubmittedServiceImpl.java
...odule/jcs/biz/service/impl/AlertSubmittedServiceImpl.java
+0
-0
No files found.
amos-boot-module/amos-boot-module-biz/amos-boot-module-jcs-biz/src/main/java/com/yeejoin/amos/boot/module/jcs/biz/service/impl/AlertCalledFeedbackServiceImpl.java
View file @
fc1b3bc8
...
...
@@ -44,7 +44,6 @@ public class AlertCalledFeedbackServiceImpl extends BaseService<AlertCalledFeedb
@Override
public
boolean
handleFeedback
(
AlertCalledFeedbackDto
model
)
{
Long
alertCalledId
=
model
.
getAlertCalledId
();
// 更新警情调派任务状态
// 保存警情反馈
...
...
amos-boot-module/amos-boot-module-biz/amos-boot-module-jcs-biz/src/main/java/com/yeejoin/amos/boot/module/jcs/biz/service/impl/AlertCalledServiceImpl.java
View file @
fc1b3bc8
...
...
@@ -231,13 +231,11 @@ public class AlertCalledServiceImpl extends BaseService<AlertCalledDto, AlertCal
split
[
0
]
=
"alertStatus"
;
}
}
if
(
split
[
1
]
!=
null
)
{
if
(
split
[
1
].
equals
(
"ascend"
))
{
if
(
split
[
1
]
!=
null
&&
split
[
1
].
equals
(
"ascend"
)
){
split
[
1
]
=
"ASC"
;
}
if
(
split
[
1
].
equals
(
"descend"
))
{
split
[
1
]
=
"DESC"
;
}
}
else
(
split
[
1
]
!=
null
&&
split
[
1
].
equals
(
"descend"
)
)
{
split
[
1
]
=
"DESC"
;
}
}
}
...
...
@@ -590,7 +588,7 @@ public class AlertCalledServiceImpl extends BaseService<AlertCalledDto, AlertCal
map
.
put
(
"sequenceNbr"
,
ll
.
getSequenceNbr
()+
""
);
map
.
put
(
"callTime"
,
ll
.
getCallTime
()!=
null
?
sdf
.
format
(
ll
.
getCallTime
()):
""
);
map
.
put
(
"updateTime"
,
ll
.
getUpdateTime
()!=
null
?
sdf
.
format
(
ll
.
getUpdateTime
()):
""
);
json
=
list
!=
null
&&
list
.
size
()>
0
?
JSON
Object
.
toJSONString
(
map
,
SerializerFeature
.
PrettyFormat
,
json
=
list
!=
null
&&
list
.
size
()>
0
?
JSON
.
toJSONString
(
map
,
SerializerFeature
.
PrettyFormat
,
SerializerFeature
.
WriteMapNullValue
):
""
;
}
...
...
@@ -603,7 +601,7 @@ public class AlertCalledServiceImpl extends BaseService<AlertCalledDto, AlertCal
// 航空报警器报警通知
if
(
AlertStageEnums
.
HKJY
.
getCode
().
equals
(
alertCalled
.
getAlertTypeCode
()))
{
List
<
String
>
flightNumber
=
powerTransferMapper
.
selectFlightNumber
(
AlertStageEnums
.
HKJY
.
getCode
());
String
flightNumIds
=
JSON
Object
.
toJSONString
(
flightNumber
);
String
flightNumIds
=
JSON
.
toJSONString
(
flightNumber
);
emqKeeper
.
getMqttClient
().
publish
(
noticeAviation
,
flightNumIds
.
getBytes
(),
RuleConfig
.
DEFAULT_QOS
,
false
);
}
...
...
@@ -1113,6 +1111,7 @@ public class AlertCalledServiceImpl extends BaseService<AlertCalledDto, AlertCal
case
LYXC:
case
ZJBZ:
resultList
=
queryDisposalObjectAircraft
(
alertCalled
);
break
;
default
:
break
;
}
...
...
@@ -1193,22 +1192,6 @@ public class AlertCalledServiceImpl extends BaseService<AlertCalledDto, AlertCal
/* 2304 地址 联系人模糊查询缺失 陈召 2021-09-23 开始 */
public
List
<
Map
<
String
,
String
>>
getContactName
()
{
// List<Map<String,String>> firefightersName =
// firefightersService.getFirefightersName();
// firefightersName.forEach(r->{
// String phone = r.get("phone");
// phone = QRCodeUtil.generateQRCode()+"@"+phone;
// r.put("phone",phone);
// }
// );
// List<Map<String,String>> contactNames = alertCalledMapper.getContactName();
// contactNames.forEach(r->{
// String phone = r.get("phone");
// phone = QRCodeUtil.generateQRCode()+"@"+phone;
// r.put("phone",phone);
// }
// );
// firefightersName.addAll(contactNames);
List
<
Map
<
String
,
String
>>
list
=
orgUsrServiceImpl
.
getPersonSimpleDetail
();
list
.
stream
().
forEach
(
i
->
{
String
phone
=
""
;
...
...
@@ -1369,13 +1352,13 @@ public class AlertCalledServiceImpl extends BaseService<AlertCalledDto, AlertCal
int
priority
=
1
;
boolean
flag2
=
false
;
boolean
flag3
=
false
;
JSONObject
listForcondition1Nameobj
=
JSON
Object
.
parseObject
(
JSONObject
.
toJSONString
(
i
));
JSONObject
listForcondition1Nameobj
=
JSON
.
parseObject
(
JSON
.
toJSONString
(
i
));
ResponseModel
<
Object
>
responseForInstanceId
=
knowledgebaseFeignClient
.
queryByInstance
(
Long
.
parseLong
(
listForcondition1Nameobj
.
getString
(
"sequenceNbr"
)));
List
responseForInstanceIdList
=
(
List
)
responseForInstanceId
.
getResult
();
Object
responseForInstanceIdDetail
=
responseForInstanceIdList
.
get
(
0
);
JSONObject
responseForInstanceIdJsonDetail
=
JSONObject
.
parseObject
(
JSON
Object
.
toJSONString
(
responseForInstanceIdDetail
));
.
parseObject
(
JSON
.
toJSONString
(
responseForInstanceIdDetail
));
if
(!(
condition1
.
split
(
","
)[
1
]).
equals
(
responseForInstanceIdJsonDetail
.
getString
(
"tagValue"
)))
{
continue
;
}
...
...
@@ -1401,16 +1384,16 @@ public class AlertCalledServiceImpl extends BaseService<AlertCalledDto, AlertCal
ResponseModel
<
Object
>
targetSeqResult
=
knowledgebaseFeignClient
.
queryListByTargetSeq
(
Long
.
parseLong
(
listForcondition1Nameobj
.
getString
(
"targetSeq"
)));
Object
targetSeqResultObj
=
targetSeqResult
.
getResult
();
JSONArray
targetSeqResultArray
=
JSON
Array
.
parseArray
(
JSONArray
.
toJSONString
(
targetSeqResultObj
));
JSONArray
targetSeqResultArray
=
JSON
.
parseArray
(
JSON
.
toJSONString
(
targetSeqResultObj
));
for
(
Object
m
:
targetSeqResultArray
)
{
JSONObject
detailJson
=
JSON
Object
.
parseObject
(
JSONObject
.
toJSONString
(
m
));
JSONObject
detailJson
=
JSON
.
parseObject
(
JSON
.
toJSONString
(
m
));
if
(
condition2Name
!=
null
&&
condition2Name
.
equals
(
detailJson
.
getString
(
"tagName"
)))
{
ResponseModel
<
Object
>
condition2ResponseForInstanceId
=
knowledgebaseFeignClient
.
queryByInstance
(
Long
.
parseLong
(
detailJson
.
getString
(
"sequenceNbr"
)));
List
condition2ResponseForInstanceIdList
=
(
List
)
condition2ResponseForInstanceId
.
getResult
();
Object
condition2ResponseForInstanceIdDetail
=
condition2ResponseForInstanceIdList
.
get
(
0
);
JSONObject
condition2ResponseForInstanceIdJsonDetail
=
JSON
Object
.
parseObject
(
JSON
Object
.
toJSONString
(
condition2ResponseForInstanceIdDetail
));
JSONObject
condition2ResponseForInstanceIdJsonDetail
=
JSON
.
parseObject
(
JSON
.
toJSONString
(
condition2ResponseForInstanceIdDetail
));
if
(
condition2value
!=
null
&&
condition2value
.
equals
(
condition2ResponseForInstanceIdJsonDetail
.
getString
(
"tagValue"
)))
{
flag2
=
true
;
...
...
@@ -1423,7 +1406,7 @@ public class AlertCalledServiceImpl extends BaseService<AlertCalledDto, AlertCal
List
condition3ResponseForInstanceIdList
=
(
List
)
condition3ResponseForInstanceId
.
getResult
();
Object
condition3ResponseForInstanceIdDetail
=
condition3ResponseForInstanceIdList
.
get
(
0
);
JSONObject
condition3ResponseForInstanceIdJsonDetail
=
JSONObject
.
parseObject
(
JSON
Object
.
toJSONString
(
condition3ResponseForInstanceIdDetail
));
.
parseObject
(
JSON
.
toJSONString
(
condition3ResponseForInstanceIdDetail
));
if
(
condition3value
!=
null
&&
condition3value
.
equals
(
condition3ResponseForInstanceIdJsonDetail
.
getString
(
"tagValue"
)))
{
flag3
=
true
;
...
...
@@ -1451,7 +1434,7 @@ public class AlertCalledServiceImpl extends BaseService<AlertCalledDto, AlertCal
ResponseModel
<
Object
>
SimpleDetailResponse
=
knowledgebaseFeignClient
.
getSimpleDetail
(
listForcondition1Nameobj
.
getString
(
"targetSeq"
));
if
(
ObjectUtils
.
isNotEmpty
(
SimpleDetailResponse
.
getResult
())
&&
priority
!=
0
)
{
JSONArray
detailJsonArray
=
JSON
Array
.
parseArray
(
JSONArray
.
toJSONString
(
SimpleDetailResponse
.
getResult
()));
JSONArray
detailJsonArray
=
JSON
.
parseArray
(
JSON
.
toJSONString
(
SimpleDetailResponse
.
getResult
()));
JSONObject
detailJsonObject
=
detailJsonArray
.
getJSONObject
(
0
);
map
.
put
(
"recDate"
,
DateUtils
.
dateToString
(
detailJsonObject
.
getString
(
"REC_DATE"
)));
map
.
put
(
"sequenceNbr"
,
detailJsonObject
.
getString
(
"SEQUENCE_NBR"
));
...
...
@@ -1467,39 +1450,11 @@ public class AlertCalledServiceImpl extends BaseService<AlertCalledDto, AlertCal
public
void
sort
(
List
<
Map
<
String
,
Object
>>
list
)
{
Collections
.
sort
(
list
,
new
Comparator
<
Map
<
String
,
Object
>>()
{
public
int
compare
(
Map
<
String
,
Object
>
o1
,
Map
<
String
,
Object
>
o2
)
{
Integer
i
=(
Integer
)
o1
.
get
(
"priority"
)
==
(
Integer
)
o2
.
get
(
"priority"
)
?
0
:
-
1
;
return
(
Integer
)
o1
.
get
(
"priority"
)
<
(
Integer
)
o2
.
get
(
"priority"
)
?
((
Integer
)
o1
.
get
(
"priority"
)
==
(
Integer
)
o2
.
get
(
"priority"
)
?
0
:
-
1
)
:
1
;
.
get
(
"priority"
)
?
i
:
1
;
}
});
}
//
// public static void main(String[] args) {
// List<Map<String, Object>> resultList = new ArrayList<Map<String, Object>>();
// Map<String, Object> map = new HashMap<String, Object>();
// map.put("docTitle", "21313213");
// map.put("priority", 21);
// resultList.add(map);
// Map<String, Object> map1 = new HashMap<String, Object>();
// map1.put("docTitle", "21313213");
// map1.put("priority", 12);
// resultList.add(map1);
// Map<String, Object> map2 = new HashMap<String, Object>();
// map2.put("docTitle", "21313213");
// map2.put("priority", 1);
// resultList.add(map2);
// Map<String, Object> map3 = new HashMap<String, Object>();
// map3.put("docTitle", "21313213");
// map3.put("priority", 31);
// resultList.add(map3);
// Map<String, Object> map4 = new HashMap<String, Object>();
// map4.put("docTitle", "21313213");
// map4.put("priority", 18);
// resultList.add(map4);
// sort(resultList);
// for (Map<String, Object> map6 : resultList) {
// System.out.println(map6.get("priority"));
// }
// }
}
amos-boot-module/amos-boot-module-biz/amos-boot-module-jcs-biz/src/main/java/com/yeejoin/amos/boot/module/jcs/biz/service/impl/AlertSubmittedServiceImpl.java
View file @
fc1b3bc8
This diff is collapsed.
Click to expand it.
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