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
456ed99e
Commit
456ed99e
authored
May 06, 2023
by
KeYong
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
更新
parent
98c50fc0
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
21 changed files
with
508 additions
and
26 deletions
+508
-26
ContingencyPlanInstance.java
.../yeejoin/amos/fas/dao/entity/ContingencyPlanInstance.java
+22
-2
EmergencyRelationTree.java
...om/yeejoin/amos/fas/dao/entity/EmergencyRelationTree.java
+3
-0
ContingencyAction.java
...m/yeejoin/amos/fas/business/action/ContingencyAction.java
+28
-0
ContingencyPlanController.java
...os/fas/business/controller/ContingencyPlanController.java
+31
-0
EmergencyTaskController.java
...amos/fas/business/controller/EmergencyTaskController.java
+1
-0
PlanVisual3dController.java
.../amos/fas/business/controller/PlanVisual3dController.java
+41
-0
TimeLineController.java
...join/amos/fas/business/controller/TimeLineController.java
+10
-0
ContingencyInstanceInfoMapper.java
...as/business/dao/mapper/ContingencyInstanceInfoMapper.java
+10
-0
BizContingencyHandler.java
...eejoin/amos/fas/business/event/BizContingencyHandler.java
+13
-1
ContingencyInstanceImpl.java
...os/fas/business/service/impl/ContingencyInstanceImpl.java
+40
-0
ContingencyPlanServiceImpl.java
...fas/business/service/impl/ContingencyPlanServiceImpl.java
+55
-9
PlanStepServiceImpl.java
...n/amos/fas/business/service/impl/PlanStepServiceImpl.java
+6
-0
PlanVisual3dServiceImpl.java
...os/fas/business/service/impl/PlanVisual3dServiceImpl.java
+84
-7
IContingencyInstance.java
...amos/fas/business/service/intfc/IContingencyInstance.java
+2
-0
IContingencyPlanService.java
...s/fas/business/service/intfc/IContingencyPlanService.java
+5
-4
IPlanStepService.java
...oin/amos/fas/business/service/intfc/IPlanStepService.java
+2
-0
IPlanVisual3dService.java
...amos/fas/business/service/intfc/IPlanVisual3dService.java
+6
-0
ContingencyPlanInstanceVO.java
...ejoin/amos/fas/business/vo/ContingencyPlanInstanceVO.java
+1
-1
fas-2.0.1.xml
...utoSysStart/src/main/resources/db/changelog/fas-2.0.1.xml
+15
-0
ContingencyInstanceInfoMapper.xml
...ain/resources/db/mapper/ContingencyInstanceInfoMapper.xml
+133
-2
plan-step.json
...osFireAutoSysStart/src/main/resources/json/plan-step.json
+0
-0
No files found.
YeeAmosFireAutoSysCommon/src/main/java/com/yeejoin/amos/fas/dao/entity/ContingencyPlanInstance.java
View file @
456ed99e
...
...
@@ -79,6 +79,28 @@ public class ContingencyPlanInstance extends BusinessEntity{
@Column
(
name
=
"person_img"
)
private
String
personImg
;
@Column
(
name
=
"task_sort"
)
private
Integer
taskSort
;
@Column
(
name
=
"step_code"
)
private
String
stepCode
;
public
void
setTaskSort
(
Integer
taskSort
)
{
this
.
taskSort
=
taskSort
;
}
public
void
setStepCode
(
String
stepCode
)
{
this
.
stepCode
=
stepCode
;
}
public
Integer
getTaskSort
()
{
return
taskSort
;
}
public
String
getStepCode
()
{
return
stepCode
;
}
public
String
getPersonImg
()
{
return
personImg
;
}
...
...
@@ -184,8 +206,6 @@ public class ContingencyPlanInstance extends BusinessEntity{
this
.
content
=
content
;
}
public
String
getIcon
()
{
return
icon
;
}
...
...
YeeAmosFireAutoSysCommon/src/main/java/com/yeejoin/amos/fas/dao/entity/EmergencyRelationTree.java
View file @
456ed99e
...
...
@@ -31,4 +31,6 @@ public class EmergencyRelationTree extends BasicEntity {
//树节点展示标识
private
String
type
;
private
String
code
;
}
\ No newline at end of file
YeeAmosFireAutoSysService/src/main/java/com/yeejoin/amos/fas/business/action/ContingencyAction.java
View file @
456ed99e
...
...
@@ -972,4 +972,32 @@ public class ContingencyAction implements CustomerAction {
private
Boolean
findByBatchNoAndStatus
(
String
batchNo
)
{
return
CollectionUtils
.
isEmpty
(
planOperationRecordDao
.
findByBatchNoAndStatus
(
batchNo
,
0
));
}
/**
* 任务动作保存
* @param taskName 任务名称
*
*/
@RuleMethod
(
methodLabel
=
"任务动作保存"
,
project
=
"换流站消防专项预案"
)
@Transactional
public
void
saveTaskInfo
(
@MethodParam
(
paramLabel
=
"动作名称"
)
String
taskName
,
@MethodParam
(
paramLabel
=
"角色编码"
)
String
roleCode
,
@MethodParam
(
paramLabel
=
"任务编号"
)
Integer
taskNum
,
@MethodParam
(
paramLabel
=
"步骤编码"
)
String
stepCode
,
@MethodParam
(
paramLabel
=
"按钮json字符串"
)
String
buttonJson
,
@MethodParam
(
paramLabel
=
"预案对象"
)
Object
paramObj
)
{
ContingencyRo
contingencyRo
=
(
ContingencyRo
)
paramObj
;
String
batchNo
=
contingencyRo
.
getBatchNo
();
if
(!
findByBatchNoAndStatus
(
batchNo
))
{
String
instanceId
=
iContingencyInstance
.
getInstanceIdByBatchNOAndCategory
(
"TASKOPERATE"
,
taskName
,
batchNo
);
if
(!
StringUtils
.
isEmpty
(
instanceId
))
{
return
;
}
ContingencyPlanInstance
contingencyPlanInstance
=
new
ContingencyPlanInstance
();
contingencyPlanInstance
.
setBatchNo
(
batchNo
);
contingencyPlanInstance
.
setRecordType
(
"TASKOPERATE"
);
contingencyPlanInstance
.
setRoleCode
(
roleCode
);
contingencyPlanInstance
.
setCategory
(
taskName
);
contingencyPlanInstance
.
setCreateDate
(
new
Date
());
contingencyPlanInstance
.
setTaskSort
(
taskNum
);
contingencyPlanInstance
.
setStepCode
(
stepCode
);
contingencyPlanInstance
.
setContent
(
buttonJson
);
contingencyPlanInstanceRepository
.
save
(
contingencyPlanInstance
);
}
}
}
YeeAmosFireAutoSysService/src/main/java/com/yeejoin/amos/fas/business/controller/ContingencyPlanController.java
View file @
456ed99e
...
...
@@ -257,4 +257,35 @@ public class ContingencyPlanController extends BaseController {
return
CommonResponseUtil2
.
success
(
contingencyPlanService
.
getUserOperateCountAndPlanName
(
roleModelList
));
}
@ApiOperation
(
value
=
"获取当前登录人待处置任务及预案信息"
)
@RequestMapping
(
value
=
"/getUserOperateCountAndTaskName"
,
method
=
RequestMethod
.
GET
)
public
ResponseModel
getUserOperateCountAndTaskName
()
{
AgencyUserModel
user
=
getUserInfo
();
List
<
RoleModel
>
roleModelList
=
new
ArrayList
<>();
for
(
Long
key
:
user
.
getOrgRoles
().
keySet
())
{
roleModelList
.
addAll
(
user
.
getOrgRoles
().
get
(
key
));
}
return
CommonResponseUtil2
.
success
(
contingencyPlanService
.
getUserOperateCountAndTaskName
(
roleModelList
));
}
@ApiOperation
(
value
=
"获取当前登录人待处置任务及预案信息"
)
@GetMapping
(
value
=
"/task/page"
)
public
ResponseModel
selectTaskActionPage
(
@RequestParam
(
value
=
"current"
)
int
current
,
@RequestParam
(
value
=
"size"
)
int
size
,
@RequestParam
(
value
=
"batchNo"
,
required
=
false
)
String
batchNo
,
@RequestParam
(
value
=
"runState"
,
required
=
false
)
String
runState
,
@RequestParam
(
value
=
"updateDate"
,
required
=
false
)
String
updateDate
,
@RequestParam
(
value
=
"roleName"
,
required
=
false
)
String
roleName
)
{
if
(
current
<
1
||
size
<
1
)
{
throw
new
YeeException
(
"分页参数有误"
);
}
List
<
String
>
list
=
new
ArrayList
<>();
if
(!
StringUtils
.
isEmpty
(
roleName
))
{
String
[]
ids
=
new
String
(
roleName
).
split
(
","
);
list
=
Arrays
.
asList
(
ids
);
}
return
CommonResponseUtil2
.
success
(
contingencyPlanService
.
selectTaskActionPage
(
current
,
size
,
batchNo
,
runState
,
updateDate
,
list
));
}
}
YeeAmosFireAutoSysService/src/main/java/com/yeejoin/amos/fas/business/controller/EmergencyTaskController.java
View file @
456ed99e
...
...
@@ -46,6 +46,7 @@ public class EmergencyTaskController extends BaseController{
tree
.
setId
(
e
.
getId
());
tree
.
setName
(
e
.
getDictName
());
tree
.
setType
(
"0"
);
tree
.
setCode
(
e
.
getDictValue
());
tree
.
setChildren
(
treeNodes
.
stream
().
filter
(
t
->
t
.
getObligationId
().
equals
(
e
.
getId
())).
collect
(
Collectors
.
toList
()));
list
.
add
(
tree
);
});
...
...
YeeAmosFireAutoSysService/src/main/java/com/yeejoin/amos/fas/business/controller/PlanVisual3dController.java
View file @
456ed99e
...
...
@@ -251,9 +251,50 @@ public class PlanVisual3dController extends BaseController {
}
@Permission
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"分页查询预案下处置动作列表"
,
notes
=
"分页查询预案下处置动作列表"
)
@GetMapping
(
value
=
"/plan/selectTaskActionPage"
)
public
ResponseModel
selectTaskActionPage
(
@RequestParam
(
value
=
"current"
)
int
current
,
@RequestParam
(
value
=
"size"
)
int
size
,
@RequestParam
(
value
=
"batchNo"
)
String
batchNo
,
@RequestParam
(
value
=
"dataType"
)
int
dataType
)
{
if
(
current
<
1
||
size
<
1
)
{
throw
new
YeeException
(
"分页参数有误"
);
}
AgencyUserModel
user
=
getUserInfo
();
List
<
RoleModel
>
roleModelList
=
new
ArrayList
<>();
for
(
Long
key
:
user
.
getOrgRoles
().
keySet
())
{
roleModelList
.
addAll
(
user
.
getOrgRoles
().
get
(
key
));
}
return
CommonResponseUtil2
.
success
(
planVisual3dService
.
selectTaskActionPage
(
current
,
size
,
batchNo
,
roleModelList
,
dataType
));
}
@Permission
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"查询预案下处置动作列表"
,
notes
=
"查询预案下处置动作列表"
)
@GetMapping
(
value
=
"/plan/selectTaskActionList"
)
public
ResponseModel
selectTaskActionList
(
@RequestParam
(
value
=
"batchNo"
)
String
batchNo
,
@RequestParam
(
value
=
"dataType"
)
int
dataType
)
{
AgencyUserModel
user
=
getUserInfo
();
List
<
RoleModel
>
roleModelList
=
new
ArrayList
<>();
for
(
Long
key
:
user
.
getOrgRoles
().
keySet
())
{
roleModelList
.
addAll
(
user
.
getOrgRoles
().
get
(
key
));
}
return
CommonResponseUtil2
.
success
(
planVisual3dService
.
selectTaskActionList
(
batchNo
,
roleModelList
,
dataType
));
}
@Permission
@ApiOperation
(
value
=
"修改动作执行状态"
,
notes
=
"修改动作执行状态"
)
@PostMapping
(
value
=
"/updateStatusById"
)
public
ResponseModel
updateStatusById
(
@RequestParam
(
"id"
)
String
id
,
@RequestParam
(
"runStatus"
)
Boolean
runStatus
)
{
return
CommonResponseUtil
.
successNew
(
planVisual3dService
.
updateStatusById
(
id
,
runStatus
));
}
@Permission
@ApiOperation
(
value
=
"修改任务动作执行状态"
,
notes
=
"修改任务动作执行状态"
)
@PostMapping
(
value
=
"/status/modify"
)
public
ResponseModel
updateTaskStatusById
(
@RequestParam
(
"id"
)
String
id
,
@RequestParam
(
"runStatus"
)
Boolean
runStatus
)
{
return
CommonResponseUtil
.
successNew
(
planVisual3dService
.
updateTaskStatusById
(
id
,
runStatus
));
}
}
YeeAmosFireAutoSysService/src/main/java/com/yeejoin/amos/fas/business/controller/TimeLineController.java
View file @
456ed99e
...
...
@@ -79,6 +79,16 @@ public class TimeLineController extends BaseController {
}
@Permission
@ApiOperation
(
httpMethod
=
"POST"
,
value
=
"点击按钮"
,
notes
=
"点击按钮"
)
@RequestMapping
(
value
=
"/click"
,
produces
=
"application/json;charset=UTF-8"
,
method
=
RequestMethod
.
POST
)
public
CommonResponse
clickButton
(
@RequestBody
PlanExecuteVo
vo
)
throws
Exception
{
AgencyUserModel
userInfo
=
getUserInfo
();
String
user
=
userInfo
.
getRealName
();
iContingencyInstance
.
clickButton
(
vo
.
getBatchNo
(),
vo
.
getStepCode
(),
vo
.
getButtonJson
(),
vo
.
getContingencyPlanId
(),
vo
.
getButtonCode
(),
vo
.
getConfirm
(),
vo
.
getStepState
(),
"true"
,
"false"
,
getToken
(),
getProduct
(),
getAppKey
(),
user
);
return
CommonResponseUtil
.
success
(
"SUCCESS"
);
}
@Permission
@ApiOperation
(
httpMethod
=
"PUT"
,
value
=
"点击按钮"
,
notes
=
"点击按钮"
)
@RequestMapping
(
value
=
"/fire/exit"
,
produces
=
"application/json;charset=UTF-8"
,
method
=
RequestMethod
.
PUT
)
public
CommonResponse
fireExit
(
@RequestParam
(
"batchNo"
)
String
batchNo
,
...
...
YeeAmosFireAutoSysService/src/main/java/com/yeejoin/amos/fas/business/dao/mapper/ContingencyInstanceInfoMapper.java
View file @
456ed99e
...
...
@@ -26,8 +26,18 @@ public interface ContingencyInstanceInfoMapper extends BaseMapper<ContingencyIns
List
<
ContingencyPlanInstanceVO
>
selectDisposalActionPage
(
@Param
(
"current"
)
int
current
,
@Param
(
"size"
)
int
size
,
@Param
(
"type"
)
String
type
,
@Param
(
"status"
)
String
status
,
@Param
(
"list"
)
List
<
String
>
roles
,
@Param
(
"batchNo"
)
String
batchNo
);
List
<
ContingencyPlanInstanceVO
>
selectTaskActionPage
(
@Param
(
"current"
)
int
current
,
@Param
(
"size"
)
int
size
,
@Param
(
"type"
)
String
type
,
@Param
(
"status"
)
String
status
,
@Param
(
"list"
)
List
<
String
>
roles
,
@Param
(
"batchNo"
)
String
batchNo
);
int
selectCountDisposalActionPage
(
@Param
(
"type"
)
String
type
,
@Param
(
"status"
)
String
status
,
@Param
(
"list"
)
List
<
String
>
roles
,
@Param
(
"batchNo"
)
String
batchNo
);
int
selectCountTaskActionPage
(
@Param
(
"type"
)
String
type
,
@Param
(
"status"
)
String
status
,
@Param
(
"list"
)
List
<
String
>
roles
,
@Param
(
"batchNo"
)
String
batchNo
);
List
<
ContingencyPlanInstanceVO
>
selectDisposalActionList
(
@Param
(
"type"
)
String
type
,
@Param
(
"status"
)
String
status
,
@Param
(
"list"
)
List
<
String
>
roles
,
@Param
(
"batchNo"
)
String
batchNo
);
List
<
ContingencyPlanInstanceVO
>
selectTaskActionList
(
@Param
(
"type"
)
String
type
,
@Param
(
"status"
)
String
status
,
@Param
(
"list"
)
List
<
String
>
roles
,
@Param
(
"batchNo"
)
String
batchNo
);
int
countTaskPage
(
@Param
(
"type"
)
String
type
,
@Param
(
"batchNo"
)
String
batchNo
,
@Param
(
"list"
)
List
<
String
>
roles
);
List
<
ContingencyPlanInstanceVO
>
getTaskActionPage
(
@Param
(
"current"
)
int
current
,
@Param
(
"size"
)
int
size
,
@Param
(
"batchNo"
)
String
batchNo
,
@Param
(
"type"
)
String
type
,
@Param
(
"runState"
)
String
runState
,
@Param
(
"updateDate"
)
String
updateDate
,
@Param
(
"list"
)
List
<
String
>
roles
);
}
YeeAmosFireAutoSysService/src/main/java/com/yeejoin/amos/fas/business/event/BizContingencyHandler.java
View file @
456ed99e
...
...
@@ -11,6 +11,7 @@ import com.yeejoin.amos.fas.business.service.impl.RiskSourceServiceImpl;
import
com.yeejoin.amos.fas.business.service.intfc.*
;
import
com.yeejoin.amos.fas.business.service.model.Operate
;
import
com.yeejoin.amos.fas.business.service.model.OperateGroup
;
import
com.yeejoin.amos.fas.business.vo.ContingencyPlanInstanceVO
;
import
com.yeejoin.amos.fas.dao.entity.ContingencyOriginalData
;
import
com.yeejoin.amos.fas.dao.entity.ContingencyPlanInstance
;
import
com.yeejoin.amos.fas.dao.entity.Equipment
;
...
...
@@ -116,7 +117,7 @@ public class BizContingencyHandler implements EventHandler{
event
.
getPlanExecute
().
getButtonCode
(),
event
.
getPlanExecute
().
getIsExecute
(),
event
.
getPlanExecute
().
getIsAuto
());
setButtonExecuted
(
event
.
getPlanExecute
().
getBatchNo
(),
setButtonExecuted
(
event
.
getPlanExecute
().
getBatchNo
(),
event
.
getPlanExecute
().
getContingencyPlanId
(),
event
.
getPlanExecute
().
getButtonCode
(),
event
.
getPlanExecute
().
getConfirm
(),
...
...
@@ -220,6 +221,17 @@ public class BizContingencyHandler implements EventHandler{
result
.
put
(
"msgContext"
,
Collections
.
EMPTY_MAP
);
result
.
put
(
"msgType"
,
"getStepList"
);
result
.
put
(
"planStep"
,
objects
);
String
planTask
=
""
;
if
(
redisTemplate
.
hasKey
(
"planTask"
))
{
planTask
=
Objects
.
requireNonNull
(
redisTemplate
.
opsForValue
().
get
(
"planTask"
)).
toString
();
}
else
{
List
<
ContingencyPlanInstanceVO
>
list
=
planVisual3dService
.
selectTaskActionList
(
batchNo
,
null
,
1
);
if
(
0
<
list
.
size
())
{
planTask
=
JSON
.
toJSONString
(
list
);
}
}
JSONArray
taskObjects
=
JSON
.
parseArray
(
planTask
);
result
.
put
(
"planTask"
,
taskObjects
);
webMqttComponent
.
publish
(
topic
,
JSON
.
toJSONString
(
result
));
}
});
...
...
YeeAmosFireAutoSysService/src/main/java/com/yeejoin/amos/fas/business/service/impl/ContingencyInstanceImpl.java
View file @
456ed99e
...
...
@@ -56,6 +56,8 @@ public class ContingencyInstanceImpl implements IContingencyInstance {
static
LinkedList
<
Map
<
String
,
String
>>
fireQueue
=
new
LinkedList
<>();
public
final
static
List
<
String
>
list
=
Arrays
.
asList
(
"0"
,
"1"
,
"2"
,
"5"
,
"9"
,
"10"
,
"11"
);
@Autowired
private
IContingencyPlanInstanceRepository
repository
;
...
...
@@ -156,6 +158,10 @@ public class ContingencyInstanceImpl implements IContingencyInstance {
planInstance
.
setCategory
(
category
);
planInstance
.
setBatchNo
(
instanceNo
);
planInstance
.
setCreateDate
(
new
Date
());
if
(
"OPERATE"
.
equalsIgnoreCase
(
recordType
))
{
JSONObject
obj
=
JSON
.
parseObject
(
content
);
planInstance
.
setStepCode
(
String
.
valueOf
(
obj
.
get
(
"stepCode"
)));
}
//计算序号
int
count
=
repository
.
countByBatchNo
(
instanceNo
);
planInstance
.
setSort
(++
count
);
...
...
@@ -381,6 +387,7 @@ public class ContingencyInstanceImpl implements IContingencyInstance {
redisTemplate
.
delete
(
RiskSourceServiceImpl
.
cacheKeyForCanBeRunning
());
// 应急处置中断,初始化planStep,json数据
planStepService
.
initPlanStep
();
planStepService
.
initPlanTask
();
// 应急处置中断,更新预案信息表结束时间
contingencyInstanceInfoService
.
updateEndTimeById
(
batchNo
);
}
...
...
@@ -487,6 +494,39 @@ public class ContingencyInstanceImpl implements IContingencyInstance {
return
Optional
.
empty
();
}
@Override
public
Optional
<
Equipment
>
clickButton
(
String
batchNo
,
String
stepCode
,
String
buttonJson
,
String
contingencyPlanId
,
String
buttonCode
,
String
buttonState
,
String
stepStateOnbutton
,
String
isExecute
,
String
isAuto
,
String
token
,
String
product
,
String
appKey
,
String
startUserName
)
throws
Exception
{
List
<
String
>
strs
=
list
.
stream
().
filter
(
x
->
x
.
equals
(
stepCode
)).
collect
(
Collectors
.
toList
());
if
(
0
<
strs
.
size
())
{
PlanExecuteVo
vo
=
new
PlanExecuteVo
();
vo
.
setConfirm
(
buttonState
);
vo
.
setStepState
(
stepStateOnbutton
);
vo
.
setBatchNo
(
batchNo
);
vo
.
setStepCode
(
stepCode
);
vo
.
setButtonCode
(
buttonCode
);
vo
.
setContingencyPlanId
(
contingencyPlanId
);
vo
.
setButtonJson
(
buttonJson
);
vo
.
setIsAuto
(
isAuto
);
vo
.
setIsExecute
(
isExecute
);
ContingecyExecEvent
fireEvent
=
new
ContingecyExecEvent
(
this
);
fireEvent
.
setEventType
(
EventType
.
FIRE_NEXT_RULE
.
name
());
fireEvent
.
setPlanExecute
(
vo
);
fireEvent
.
setContext
(
RequestContext
.
cloneRequestContext
());
applicationContext
.
publishEvent
(
fireEvent
);
ContingecyExecEvent
updateEvent
=
new
ContingecyExecEvent
(
this
);
updateEvent
.
setEventType
(
EventType
.
UPDATE_CONTINGENCY_DATE
.
name
());
updateEvent
.
setPlanExecute
(
vo
);
updateEvent
.
setContext
(
RequestContext
.
cloneRequestContext
());
try
{
applicationContext
.
publishEvent
(
updateEvent
);
}
catch
(
Exception
e
)
{
e
.
printStackTrace
();
}
}
return
Optional
.
empty
();
}
@Autowired
List
<
EventHandler
>
handlers
;
...
...
YeeAmosFireAutoSysService/src/main/java/com/yeejoin/amos/fas/business/service/impl/ContingencyPlanServiceImpl.java
View file @
456ed99e
...
...
@@ -37,6 +37,7 @@ import org.springframework.data.redis.core.RedisTemplate;
import
org.springframework.stereotype.Service
;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.util.CollectionUtils
;
import
org.springframework.util.ObjectUtils
;
import
org.typroject.tyboot.component.emq.EmqKeeper
;
import
org.typroject.tyboot.core.foundation.utils.Bean
;
import
org.typroject.tyboot.core.foundation.utils.ValidationUtil
;
...
...
@@ -92,6 +93,9 @@ public class ContingencyPlanServiceImpl implements IContingencyPlanService {
private
Boolean
dataSyncSwitch
;
@Autowired
private
ContingencyInstanceInfoMapper
contingencyInstanceInfoMapper
;
@Autowired
private
IDataSyncService
dataSyncService
;
private
final
PlanOperationRecordMapper
planOperationRecordMapper
;
private
final
IPlanDetailDao
planDetailDao
;
...
...
@@ -246,15 +250,16 @@ public class ContingencyPlanServiceImpl implements IContingencyPlanService {
result
.
setMessage
(
ReserveEnum
.
RUN
.
getText
());
result
.
setBatchNo
(
batchNo
);
equipmentHandlerService
.
executeDynamicPlan
(
batchNo
,
deviceData
,
equipment
,
equipmentSpecific
,
toke
,
operationRecord
.
getId
());
// String topic = String.format("/%s/%s/%s", serviceName, stationName, "plan");
// Map<String, Object> map = new HashMap<>();
// JSONObject msgContext = new JSONObject();
// msgContext.put("content", "startPlan");
// map.put("contingency", new ContingencyRo());
//// map.put("msgContext", "{\"content\":\"startPlan\"}");
// map.put("msgContext", msgContext);
// map.put("msgType", "refreshRecord");
// webMqttComponent.publish(topic, JSON.toJSONString(map));
// app端使用
String
topic
=
String
.
format
(
"/%s/%s/%s"
,
serviceName
,
stationName
,
"plan"
);
Map
<
String
,
Object
>
map
=
new
HashMap
<>();
JSONObject
msgContext
=
new
JSONObject
();
msgContext
.
put
(
"content"
,
"startPlan"
);
map
.
put
(
"contingency"
,
new
ContingencyRo
());
// map.put("msgContext", "{\"content\":\"startPlan\"}");
map
.
put
(
"msgContext"
,
msgContext
);
map
.
put
(
"msgType"
,
"refreshRecord"
);
webMqttComponent
.
publish
(
topic
,
JSON
.
toJSONString
(
map
));
}
return
result
;
}
...
...
@@ -881,6 +886,28 @@ public class ContingencyPlanServiceImpl implements IContingencyPlanService {
}
@Override
public
Page
<
ContingencyPlanInstanceVO
>
selectTaskActionPage
(
int
current
,
int
size
,
String
batchNo
,
String
runState
,
String
updateDate
,
List
<
String
>
roleList
)
{
List
<
String
>
roles
=
new
ArrayList
<>();
String
type
=
"TASKOPERATE"
;
Page
<
ContingencyPlanInstanceVO
>
page
=
new
Page
<>(
current
,
size
);
int
total
=
0
;
total
=
contingencyInstanceInfoMapper
.
countTaskPage
(
type
,
batchNo
,
roleList
);
long
start
=
(
page
.
getCurrent
()
-
1
)
*
page
.
getSize
();
if
(
total
==
0
)
{
page
.
setCurrent
(
1
);
}
else
{
if
(
total
<
start
)
{
page
.
setCurrent
(
1
);
start
=
0
;
}
List
<
ContingencyPlanInstanceVO
>
list
=
contingencyInstanceInfoMapper
.
getTaskActionPage
((
int
)
start
,
size
,
batchNo
,
type
,
runState
,
updateDate
,
roles
);
page
.
setRecords
(
list
);
page
.
setTotal
(
total
);
}
return
page
;
}
@Override
public
Map
<
String
,
Object
>
getUserOperateCountAndPlanName
(
List
<
RoleModel
>
roleModelList
)
{
Map
<
String
,
Object
>
map
=
new
HashMap
<>();
List
<
PlanOperationRecord
>
recordList
=
planOperationRecordDao
.
findByStatus
(
0
);
...
...
@@ -898,4 +925,22 @@ public class ContingencyPlanServiceImpl implements IContingencyPlanService {
return
map
;
}
@Override
public
Map
<
String
,
Object
>
getUserOperateCountAndTaskName
(
List
<
RoleModel
>
roleModelList
)
{
Map
<
String
,
Object
>
map
=
new
HashMap
<>();
List
<
PlanOperationRecord
>
recordList
=
planOperationRecordDao
.
findByStatus
(
0
);
if
(!
CollectionUtils
.
isEmpty
(
recordList
))
{
PlanOperationRecord
record
=
recordList
.
get
(
0
);
String
batchNo
=
record
.
getBatchNo
();
ContingencyInstanceInfoVO
instanceInfo
=
contingencyInstanceInfoService
.
selectDisposalDetails
(
batchNo
);
if
(
instanceInfo
!=
null
)
{
map
.
put
(
"planName"
,
instanceInfo
.
getName
());
map
.
put
(
"batchNo"
,
batchNo
);
List
<
ContingencyPlanInstanceVO
>
list
=
planVisual3dService
.
selectTaskActionList
(
batchNo
,
roleModelList
,
1
);
map
.
put
(
"taskNum"
,
list
.
size
());
}
}
return
map
;
}
}
\ No newline at end of file
YeeAmosFireAutoSysService/src/main/java/com/yeejoin/amos/fas/business/service/impl/PlanStepServiceImpl.java
View file @
456ed99e
...
...
@@ -77,4 +77,10 @@ public class PlanStepServiceImpl implements IPlanStepService {
redisTemplate
.
opsForValue
().
set
(
"planStep"
,
getPlanStep
());
redisTemplate
.
delete
(
"isMock"
);
}
@Override
public
void
initPlanTask
()
{
redisTemplate
.
delete
(
"planTask"
);
redisTemplate
.
opsForValue
().
set
(
"planTask"
,
""
);
}
}
YeeAmosFireAutoSysService/src/main/java/com/yeejoin/amos/fas/business/service/impl/PlanVisual3dServiceImpl.java
View file @
456ed99e
...
...
@@ -483,13 +483,15 @@ public class PlanVisual3dServiceImpl implements IPlanVisual3dService {
dto
.
setPersonImg
(
personImg
);
}
dto
.
setContent
(
StringUtil
.
isNotEmpty
(
dto
.
getContent
())
?
dto
.
getContent
()
:
""
);
repository
.
save
(
dto
);
String
topic
=
String
.
format
(
"/%s/%s/%s"
,
serviceName
,
stationName
,
"plan"
);
Map
<
String
,
Object
>
map
=
new
HashMap
<>();
map
.
put
(
"contingency"
,
new
ContingencyRo
());
map
.
put
(
"msgContext"
,
Collections
.
EMPTY_MAP
);
map
.
put
(
"msgType"
,
"replayMessage"
);
webMqttComponent
.
publish
(
topic
,
JSON
.
toJSONString
(
map
));
ContingencyPlanInstance
instance
=
repository
.
save
(
dto
);
if
(!
ObjectUtils
.
isEmpty
(
instance
))
{
String
topic
=
String
.
format
(
"/%s/%s/%s"
,
serviceName
,
stationName
,
"plan"
);
Map
<
String
,
Object
>
map
=
new
HashMap
<>();
map
.
put
(
"contingency"
,
new
ContingencyRo
());
map
.
put
(
"msgContext"
,
Collections
.
EMPTY_MAP
);
map
.
put
(
"msgType"
,
"replayMessage"
);
webMqttComponent
.
publish
(
topic
,
JSON
.
toJSONString
(
map
));
}
return
dto
;
}
...
...
@@ -534,6 +536,59 @@ public class PlanVisual3dServiceImpl implements IPlanVisual3dService {
}
@Override
public
Page
<
ContingencyPlanInstanceVO
>
selectTaskActionPage
(
int
current
,
int
size
,
String
disposalId
,
List
<
RoleModel
>
roleModelList
,
int
dataType
)
{
List
<
String
>
roles
=
new
ArrayList
<>();
String
type
=
"TASKOPERATE"
;
String
status
=
""
;
Page
<
ContingencyPlanInstanceVO
>
page
=
new
Page
<>(
current
,
size
);
for
(
RoleModel
roleModel
:
roleModelList
)
{
roles
.
add
(
roleModel
.
getRoleName
());
}
int
total
=
0
;
if
(
ObjectUtils
.
isEmpty
(
status
))
{
total
=
contingencyInstanceInfoMapper
.
selectCountTaskActionPage
(
type
,
null
,
roles
,
disposalId
);
}
else
{
total
=
contingencyInstanceInfoMapper
.
selectCountTaskActionPage
(
type
,
status
,
roles
,
disposalId
);
}
long
start
=
(
page
.
getCurrent
()
-
1
)
*
page
.
getSize
();
if
(
total
==
0
)
{
page
.
setCurrent
(
1
);
}
else
{
if
(
total
<
start
)
{
page
.
setCurrent
(
1
);
start
=
0
;
}
List
<
ContingencyPlanInstanceVO
>
list
=
contingencyInstanceInfoMapper
.
selectTaskActionPage
((
int
)
start
,
size
,
type
,
status
,
roles
,
disposalId
);
page
.
setRecords
(
list
);
page
.
setTotal
(
total
);
}
return
page
;
}
@Override
public
List
<
ContingencyPlanInstanceVO
>
selectTaskActionList
(
String
batchNo
,
List
<
RoleModel
>
roleModelList
,
int
dataType
)
{
List
<
String
>
roles
=
new
ArrayList
<>();
String
type
=
"TASKOPERATE"
;
String
status
=
""
;
if
(
"1"
.
equals
(
String
.
valueOf
(
dataType
)))
{
if
(
null
!=
roleModelList
&&
0
<
roleModelList
.
size
())
{
for
(
RoleModel
roleModel
:
roleModelList
)
{
roles
.
add
(
roleModel
.
getRoleName
());
}
}
// 根据当前用户预案角色、未执行动作
status
=
"1"
;
}
else
if
(
"2"
.
equals
(
String
.
valueOf
(
dataType
)))
{
// 当前用户预案角色、全部动作数据
for
(
RoleModel
roleModel
:
roleModelList
)
{
roles
.
add
(
roleModel
.
getRoleName
());
}
}
return
contingencyInstanceInfoMapper
.
selectTaskActionList
(
type
,
status
,
roles
,
batchNo
);
}
@Override
public
List
<
ContingencyPlanInstanceVO
>
selectDisposalActionList
(
String
batchNo
,
List
<
RoleModel
>
roleModelList
,
int
dataType
)
{
List
<
String
>
roles
=
new
ArrayList
<>();
String
type
=
"OPERATE"
;
...
...
@@ -610,6 +665,28 @@ public class PlanVisual3dServiceImpl implements IPlanVisual3dService {
}
@Override
public
boolean
updateTaskStatusById
(
String
id
,
Boolean
runStatus
)
{
boolean
bool
=
false
;
if
(
runStatus
)
{
ContingencyPlanInstance
instance
=
contingencyPlanInstanceMapper
.
getMessageById
(
id
);
ContingencyPlanInstance
contingencyPlanInstance
=
deleteButton
(
instance
);
bool
=
contingencyPlanInstanceMapper
.
updateStatusById
(
id
,
contingencyPlanInstance
.
getContent
(),
runStatus
);
}
else
{
bool
=
contingencyPlanInstanceMapper
.
updateStatusById
(
id
,
null
,
runStatus
);
}
if
(
bool
)
{
String
topic
=
String
.
format
(
"/%s/%s/%s"
,
serviceName
,
stationName
,
"plan"
);
Map
<
String
,
Object
>
map
=
new
HashMap
<>();
map
.
put
(
"contingency"
,
new
ContingencyRo
());
map
.
put
(
"msgContext"
,
Collections
.
EMPTY_MAP
);
map
.
put
(
"msgType"
,
"refreshTaskRecord"
);
webMqttComponent
.
publish
(
topic
,
JSON
.
toJSONString
(
map
));
}
return
bool
;
}
@Override
public
ContingencyPlanInstance
updateStatusByIdWeb
(
ContingencyPlanInstance
contingencyPlanInstance
,
Boolean
runStatus
)
{
if
(
runStatus
)
{
deleteButton
(
contingencyPlanInstance
);
...
...
YeeAmosFireAutoSysService/src/main/java/com/yeejoin/amos/fas/business/service/intfc/IContingencyInstance.java
View file @
456ed99e
...
...
@@ -25,6 +25,8 @@ public interface IContingencyInstance {
Optional
<
Equipment
>
fire
(
String
batchNo
,
String
stepCode
,
String
buttonJson
,
String
contingencyPlanId
,
String
buttonCode
,
String
buttonState
,
String
stepStateOnbutton
,
String
isExecute
,
String
isAuto
,
String
token
,
String
product
,
String
appKey
,
String
startUserName
)
throws
Exception
;
Optional
<
Equipment
>
clickButton
(
String
batchNo
,
String
stepCode
,
String
buttonJson
,
String
contingencyPlanId
,
String
buttonCode
,
String
buttonState
,
String
stepStateOnbutton
,
String
isExecute
,
String
isAuto
,
String
token
,
String
product
,
String
appKey
,
String
startUserName
)
throws
Exception
;
/**
* 扩展属性赋值
* @param contingencyPlanInstance
...
...
YeeAmosFireAutoSysService/src/main/java/com/yeejoin/amos/fas/business/service/intfc/IContingencyPlanService.java
View file @
456ed99e
package
com
.
yeejoin
.
amos
.
fas
.
business
.
service
.
intfc
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
com.yeejoin.amos.fas.business.vo.ContingencyPlanParamVo
;
import
com.yeejoin.amos.fas.business.vo.ContingencyPlanResponseVo
;
import
com.yeejoin.amos.fas.business.vo.PlanDetailVo
;
import
com.yeejoin.amos.fas.business.vo.Toke
;
import
com.yeejoin.amos.fas.business.vo.*
;
import
com.yeejoin.amos.fas.dao.entity.PlanDetail
;
import
com.yeejoin.amos.fas.dao.entity.PlanOperationRecord
;
import
com.yeejoin.amos.fas.exception.YeeException
;
...
...
@@ -141,5 +138,9 @@ public interface IContingencyPlanService {
Map
<
String
,
Object
>
getUserOperateCountAndPlanName
(
List
<
RoleModel
>
roleModelList
);
Map
<
String
,
Object
>
getUserOperateCountAndTaskName
(
List
<
RoleModel
>
roleModelList
);
String
getPlanBatchNo
();
Page
<
ContingencyPlanInstanceVO
>
selectTaskActionPage
(
int
current
,
int
size
,
String
batchNo
,
String
runState
,
String
updateDate
,
List
<
String
>
roleList
);
}
YeeAmosFireAutoSysService/src/main/java/com/yeejoin/amos/fas/business/service/intfc/IPlanStepService.java
View file @
456ed99e
...
...
@@ -27,4 +27,6 @@ public interface IPlanStepService {
String
getPlanStep
();
void
initPlanStep
();
void
initPlanTask
();
}
YeeAmosFireAutoSysService/src/main/java/com/yeejoin/amos/fas/business/service/intfc/IPlanVisual3dService.java
View file @
456ed99e
...
...
@@ -91,6 +91,8 @@ public interface IPlanVisual3dService {
Page
<
ContingencyPlanInstanceVO
>
selectDisposalActionPage
(
int
current
,
int
size
,
String
batchNo
,
List
<
RoleModel
>
roleModelList
,
int
dataType
);
Page
<
ContingencyPlanInstanceVO
>
selectTaskActionPage
(
int
current
,
int
size
,
String
batchNo
,
List
<
RoleModel
>
roleModelList
,
int
dataType
);
/**
* 根据批次号获取预案的消息等记录
*
...
...
@@ -103,6 +105,8 @@ public interface IPlanVisual3dService {
List
<
ContingencyPlanInstanceVO
>
selectDisposalActionList
(
String
batchNo
,
List
<
RoleModel
>
roleModelList
,
int
dataType
);
List
<
ContingencyPlanInstanceVO
>
selectTaskActionList
(
String
batchNo
,
List
<
RoleModel
>
roleModelList
,
int
dataType
);
/**
* 极光推送消息
*
...
...
@@ -120,6 +124,8 @@ public interface IPlanVisual3dService {
*/
boolean
updateStatusById
(
String
id
,
Boolean
runStatus
);
boolean
updateTaskStatusById
(
String
id
,
Boolean
runStatus
);
/**
* 修改动作执行状态-web
* @param contingencyPlanInstance
...
...
YeeAmosFireAutoSysService/src/main/java/com/yeejoin/amos/fas/business/vo/ContingencyPlanInstanceVO.java
View file @
456ed99e
...
...
@@ -12,7 +12,7 @@ public class ContingencyPlanInstanceVO {
protected
String
id
;
private
String
recordType
;
// 记录类型:消息MESSAGE,操作OPERATE
,回复消息REPLYMESSAG
E
private
String
recordType
;
// 记录类型:消息MESSAGE,操作OPERATE
, 回复消息REPLYMESSAGE, 任务指令TASKOPERAT
E
private
String
content
;
// 记录内容:文本信息或者json数据
...
...
YeeAmosFireAutoSysStart/src/main/resources/db/changelog/fas-2.0.1.xml
View file @
456ed99e
...
...
@@ -843,4 +843,18 @@
ADD INDEX `INDEX_BATCH_NO`(`batch_No`) USING BTREE;
</sql>
</changeSet>
<changeSet
author=
"keyong"
id=
"1682647357"
>
<preConditions
onFail=
"MARK_RAN"
>
<not>
<columnExists
tableName=
"contingency_plan_instance"
columnName=
"task_sort"
/>
</not>
</preConditions>
<comment>
增加任务动作相关字段
</comment>
<sql>
ALTER TABLE `contingency_plan_instance`
ADD COLUMN `task_sort` int DEFAULT NULL AFTER `person_img`,
ADD COLUMN `step_code` varchar(20) NULL AFTER `task_sort`;
</sql>
</changeSet>
</databaseChangeLog>
\ No newline at end of file
YeeAmosFireAutoSysStart/src/main/resources/db/mapper/ContingencyInstanceInfoMapper.xml
View file @
456ed99e
...
...
@@ -64,6 +64,57 @@
order by cpi.`create_date` ASC
LIMIT #{current}, #{size}
</select>
<select
id=
"selectTaskActionPage"
resultType=
"com.yeejoin.amos.fas.business.vo.ContingencyPlanInstanceVO"
>
select cpi.id, cpi.`record_type`, cpi.`category`, cpi.`content`, cpi.`icon`, cpi.`sort`, cpi.`sequence_num`
, cpi.`batch_no`, cpi.`create_date`, cpi.`create_user`, cpi.`update_date`
, cpi.`update_user`, cpi.`is_delete`, cpi.`tips`, IFNULL(cpi.`runstate`, 0) AS runstate, cpi.`file_path`
, `file_type`, `role_name`, `role_code`, `start_user_name`
, cpi.`start_user_id`, cpi.`person_img`,cii.name
from contingency_plan_instance cpi left join contingency_instance_info cii
on cpi.batch_no = cii.id
<where>
<if
test=
"batchNo != null and batchNo != ''"
>
cpi.batch_no = #{batchNo}
</if>
<if
test=
"type != null and type != ''"
>
and cpi.record_type = #{type}
</if>
<if
test=
"status != null and status != ''"
>
and (cpi.runstate is null or cpi.runstate = 0)
</if>
<if
test=
"list != null and list.size() >0"
>
<foreach
collection=
"list"
item=
"role"
index=
"index"
open=
"and ("
close=
") "
separator=
"or"
>
cpi.role_code like concat('%',#{role},'%')
</foreach>
</if>
</where>
order by cpi.`create_date` ASC
LIMIT #{current}, #{size}
</select>
<select
id=
"selectCountTaskActionPage"
resultType=
"java.lang.Integer"
>
select count(1) from contingency_plan_instance
<where>
<if
test=
"batchNo != null and batchNo != ''"
>
batch_no = #{batchNo}
</if>
<if
test=
"type != null and type != ''"
>
and record_type = #{type}
</if>
<if
test=
"status != null and status != ''"
>
and (runstate is null or runstate = 0)
</if>
<if
test=
"list != null and list.size() >0"
>
<foreach
collection=
"list"
item=
"role"
index=
"index"
open=
"and ("
close=
") "
separator=
"or"
>
role_code like concat('%',#{role},'%')
</foreach>
</if>
</where>
</select>
<select
id=
"selectCountDisposalActionPage"
resultType=
"java.lang.Integer"
>
select count(1) from contingency_plan_instance
<where>
...
...
@@ -77,14 +128,13 @@
and (runstate is null or runstate = 0)
</if>
<if
test=
"list != null and list.size() >0"
>
<foreach
collection=
"list"
item=
"role"
index=
"index"
open=
"and ("
close=
") "
separator=
"or"
>
role_code like concat('%',#{role},'%')
</foreach>
</if>
</where>
</select>
<select
id=
"selectDisposalActionList"
resultType=
"com.yeejoin.amos.fas.business.vo.ContingencyPlanInstanceVO"
>
select cpi.id, cpi.`record_type`, cpi.`category`, cpi.`content`, cpi.`icon`, cpi.`sort`, cpi.`sequence_num`
, cpi.`batch_no`, cpi.`create_date`, cpi.`create_user`, cpi.`update_date`
...
...
@@ -112,5 +162,86 @@
</where>
order by cpi.`create_date`
</select>
<select
id=
"selectTaskActionList"
resultType=
"com.yeejoin.amos.fas.business.vo.ContingencyPlanInstanceVO"
>
select cpi.id, cpi.`record_type`, cpi.`category`, cpi.`content`, cpi.`icon`, cpi.`sort`, cpi.`sequence_num`
, cpi.`batch_no`, cpi.`create_date`, cpi.`create_user`, cpi.`update_date`
, cpi.`update_user`, cpi.`is_delete`, cpi.`tips`, IFNULL(cpi.`runstate`, 0) AS runstate, cpi.`file_path`
, `file_type`, `role_name`, `role_code`, `start_user_name`
, cpi.`start_user_id`, cpi.`person_img`,cii.name
from contingency_plan_instance cpi left join contingency_instance_info cii
on cpi.batch_no = cii.id
<where>
<if
test=
"batchNo != null and batchNo != ''"
>
cpi.batch_no = #{batchNo}
</if>
<if
test=
"type != null and type != ''"
>
and cpi.record_type = #{type}
</if>
<if
test=
"status != null and status != ''"
>
and (cpi.runstate is null or cpi.runstate = 0)
</if>
<if
test=
"list != null and list.size() >0"
>
<foreach
collection=
"list"
item=
"role"
index=
"index"
open=
"and ("
close=
") "
separator=
"or"
>
cpi.role_code like concat('%',#{role},'%')
</foreach>
</if>
</where>
order by cpi.`create_date`
</select>
<select
id=
"countTaskPage"
resultType=
"java.lang.Integer"
>
select count(1) from contingency_plan_instance
<where>
<if
test=
"type != null and type != ''"
>
and record_type = #{type}
</if>
<if
test=
"batchNo != null and batchNo != ''"
>
batch_no = #{batchNo}
</if>
<if
test=
"list != null and list.size() >0"
>
<foreach
collection=
"list"
item=
"role"
index=
"index"
open=
"and ("
close=
") "
separator=
"or"
>
role_code like concat('%', #{role}, '%')
</foreach>
</if>
</where>
</select>
<select
id=
"getTaskActionPage"
resultType=
"com.yeejoin.amos.fas.business.vo.ContingencyPlanInstanceVO"
>
select cpi.id, cpi.`record_type`, cpi.`category`, cpi.`content`, cpi.`icon`, cpi.`sort`, cpi.`sequence_num`
, cpi.`batch_no`, cpi.`create_date`, cpi.`create_user`, cpi.`update_date`
, cpi.`update_user`, cpi.`is_delete`, cpi.`tips`, IFNULL(cpi.`runstate`, 0) AS runstate, cpi.`file_path`
, `file_type`, `role_name`, `role_code`, `start_user_name`
, cpi.`start_user_id`, cpi.`person_img`,cii.name
from contingency_plan_instance cpi left join contingency_instance_info cii
on cpi.batch_no = cii.id
<where>
<if
test=
"batchNo != null and batchNo != ''"
>
cpi.batch_no = #{batchNo}
</if>
<if
test=
"type != null and type != ''"
>
and cpi.record_type = #{type}
</if>
<if
test=
"list != null and list.size() > 0"
>
<foreach
collection=
"list"
item=
"role"
index=
"index"
open=
"and ("
close=
") "
separator=
"or"
>
cpi.role_code like concat('%',#{role},'%')
</foreach>
</if>
</where>
<if
test=
"updateDate != null and updateDate != '' and updateDate == 0"
>
order by cpi.`update_date` DESC
</if>
<if
test=
"updateDate != null and updateDate != '' and updateDate == 1"
>
order by cpi.`update_date` ASC
</if>
<if
test=
"runState != null and runState != '' and runState == 0"
>
, cpi.runstate DESC
</if>
<if
test=
"runState != null and runState != '' and runState == 1"
>
, cpi.runstate ASC
</if>
LIMIT #{current}, #{size}
</select>
</mapper>
YeeAmosFireAutoSysStart/src/main/resources/json/plan-step.json
View file @
456ed99e
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