Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
Y
YeeAmosFireAutoSysRoot
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
station
YeeAmosFireAutoSysRoot
Commits
6add715e
Commit
6add715e
authored
Oct 20, 2022
by
zhangsen
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
daima tijaio
parent
8c172f01
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
8 additions
and
4 deletions
+8
-4
PlanVisual3dController.java
.../amos/fas/business/controller/PlanVisual3dController.java
+2
-1
PlanVisual3dServiceImpl.java
...os/fas/business/service/impl/PlanVisual3dServiceImpl.java
+5
-2
IPlanVisual3dService.java
...amos/fas/business/service/intfc/IPlanVisual3dService.java
+1
-1
No files found.
YeeAmosFireAutoSysService/src/main/java/com/yeejoin/amos/fas/business/controller/PlanVisual3dController.java
View file @
6add715e
...
...
@@ -205,13 +205,14 @@ public class PlanVisual3dController extends BaseController {
@ApiOperation
(
value
=
"根据批次号获取预案的消息等记录"
,
notes
=
"根据批次号获取预案的消息等记录"
)
@GetMapping
(
value
=
"/plan/getPlaneRecordByNew"
)
public
ResponseModel
<
ContingencyPlanInstanceVO
>
getPlaneRecordByNew
(
@RequestParam
Integer
pageNum
,
@RequestParam
Integer
size
,
@RequestParam
(
required
=
false
)
String
batchNo
)
{
AgencyUserModel
user
=
getUserInfo
();
if
(!
StringUtil
.
isNotEmpty
(
batchNo
))
{
batchNo
=
planVisual3dService
.
getNewestBatchNo
();
}
if
(!
StringUtil
.
isNotEmpty
(
batchNo
))
{
return
CommonResponseUtil
.
successNew
(
null
);
}
return
CommonResponseUtil
.
successNew
(
planVisual3dService
.
getPlaneRecordByNew
(
pageNum
,
size
,
batchNo
));
return
CommonResponseUtil
.
successNew
(
planVisual3dService
.
getPlaneRecordByNew
(
pageNum
,
size
,
batchNo
,
user
));
}
@Permission
...
...
YeeAmosFireAutoSysService/src/main/java/com/yeejoin/amos/fas/business/service/impl/PlanVisual3dServiceImpl.java
View file @
6add715e
...
...
@@ -40,6 +40,7 @@ import org.springframework.util.ObjectUtils;
import
org.typroject.tyboot.component.emq.EmqKeeper
;
import
java.io.IOException
;
import
java.lang.reflect.InvocationTargetException
;
import
java.nio.charset.StandardCharsets
;
import
java.util.*
;
import
java.util.stream.Collectors
;
...
...
@@ -375,7 +376,7 @@ public class PlanVisual3dServiceImpl implements IPlanVisual3dService {
}
@Override
public
Page
<
ContingencyPlanInstanceVO
>
getPlaneRecordByNew
(
Integer
pageNum
,
Integer
size
,
String
batchNo
)
{
public
Page
<
ContingencyPlanInstanceVO
>
getPlaneRecordByNew
(
Integer
pageNum
,
Integer
size
,
String
batchNo
,
AgencyUserModel
user
)
{
Integer
planInstanceCount
=
contingencyPlanInstanceMapper
.
getPlanInstanceCount
(
batchNo
);
// 根据批次号获取预案记录
List
<
ContingencyPlanInstance
>
planInstanceListByPage
=
contingencyPlanInstanceMapper
.
getPlanInstanceListByPage
(
batchNo
,
(
pageNum
-
1
)
*
size
,
size
);
...
...
@@ -383,7 +384,8 @@ public class PlanVisual3dServiceImpl implements IPlanVisual3dService {
if
(!
CollectionUtils
.
isEmpty
(
planInstanceListByPage
))
{
planInstanceListByPage
.
stream
().
forEach
(
item
->
{
ContingencyPlanInstanceVO
instanceVO
=
new
ContingencyPlanInstanceVO
();
BeanUtils
.
copyProperties
(
planInstanceListByPage
,
instanceVO
);
BeanUtils
.
copyProperties
(
item
,
instanceVO
);
instanceVO
.
setLoginUserId
(
user
.
getUserId
());
list
.
add
(
instanceVO
);
});
list
.
stream
().
sorted
(
Comparator
.
comparing
(
ContingencyPlanInstanceVO:
:
getCreateDate
)).
collect
(
Collectors
.
toList
());
...
...
@@ -432,6 +434,7 @@ public class PlanVisual3dServiceImpl implements IPlanVisual3dService {
dto
.
setCreateDate
(
new
Date
());
Map
<
String
,
String
>
userInfo
=
contingencyPlanInstanceMapper
.
getUserByUserId
(
user
.
getUserId
());
dto
.
setPersonImg
(
userInfo
.
get
(
"personImg"
));
dto
.
setContent
(
StringUtil
.
isNotEmpty
(
dto
.
getContent
())
?
dto
.
getContent
()
:
""
);
repository
.
save
(
dto
);
try
{
String
topic
=
String
.
format
(
"/%s/%s/%s"
,
serviceName
,
stationName
,
"plan"
);
...
...
YeeAmosFireAutoSysService/src/main/java/com/yeejoin/amos/fas/business/service/intfc/IPlanVisual3dService.java
View file @
6add715e
...
...
@@ -92,7 +92,7 @@ public interface IPlanVisual3dService {
* @param batchNo
* @return
*/
Page
<
ContingencyPlanInstanceVO
>
getPlaneRecordByNew
(
Integer
pageNum
,
Integer
size
,
String
batchNo
);
Page
<
ContingencyPlanInstanceVO
>
getPlaneRecordByNew
(
Integer
pageNum
,
Integer
size
,
String
batchNo
,
AgencyUserModel
user
);
ContingencyPlanInstance
replyMessage
(
AgencyUserModel
user
,
ContingencyPlanInstance
dto
);
...
...
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