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
640a10a8
Commit
640a10a8
authored
Jan 19, 2021
by
田涛
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
数字预案绑定资源删除信息同步
parent
e3d3fb78
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
47 additions
and
15 deletions
+47
-15
ContingencyPlanController.java
...os/fas/business/controller/ContingencyPlanController.java
+2
-9
PlanDocMapper.java
...m/yeejoin/amos/fas/business/dao/mapper/PlanDocMapper.java
+1
-4
PlanEquipmentMapper.java
...oin/amos/fas/business/dao/mapper/PlanEquipmentMapper.java
+1
-0
PlanRuleMapper.java
.../yeejoin/amos/fas/business/dao/mapper/PlanRuleMapper.java
+1
-0
ContingencyPlanServiceImpl.java
...fas/business/service/impl/ContingencyPlanServiceImpl.java
+0
-0
IContingencyPlanService.java
...s/fas/business/service/intfc/IContingencyPlanService.java
+12
-1
ApplicationRunnerImpl.java
...va/com/yeejoin/amos/fas/config/ApplicationRunnerImpl.java
+5
-1
PlanDocMapper.xml
...toSysStart/src/main/resources/db/mapper/PlanDocMapper.xml
+8
-0
PlanEquipmentMapper.xml
...tart/src/main/resources/db/mapper/PlanEquipmentMapper.xml
+9
-0
PlanRuleMapper.xml
...oSysStart/src/main/resources/db/mapper/PlanRuleMapper.xml
+8
-0
No files found.
YeeAmosFireAutoSysService/src/main/java/com/yeejoin/amos/fas/business/controller/ContingencyPlanController.java
View file @
640a10a8
package
com
.
yeejoin
.
amos
.
fas
.
business
.
controller
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
com.yeejoin.amos.fas.business.service.intfc.ContingencyPlanService
;
import
com.yeejoin.amos.fas.business.service.intfc.
I
ContingencyPlanService
;
import
com.yeejoin.amos.fas.business.vo.ContingencyPlanParamVo
;
import
com.yeejoin.amos.fas.core.util.CommonResponseUtil2
;
import
com.yeejoin.amos.fas.core.util.ResponseModel
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
com.yeejoin.amos.fas.business.service.intfc.ContingencyPlanService
;
import
com.yeejoin.amos.fas.business.vo.PlanDetailVo
;
import
com.yeejoin.amos.fas.config.Permission
;
import
com.yeejoin.amos.fas.core.util.CommonResponseUtil2
;
import
com.yeejoin.amos.fas.core.util.ResponseModel
;
import
com.yeejoin.amos.fas.exception.YeeException
;
import
com.yeejoin.amos.feign.privilege.model.AgencyUserModel
;
import
io.swagger.annotations.Api
;
...
...
@@ -18,10 +14,7 @@ import io.swagger.annotations.ApiOperation;
import
io.swagger.annotations.ApiParam
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.web.bind.annotation.*
;
import
io.swagger.annotations.ApiOperation
;
import
org.apache.commons.lang3.StringUtils
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.web.bind.annotation.*
;
import
java.util.ArrayList
;
import
java.util.Date
;
...
...
@@ -33,7 +26,7 @@ import java.util.List;
public
class
ContingencyPlanController
extends
BaseController
{
@Autowired
private
ContingencyPlanService
contingencyPlanService
;
private
I
ContingencyPlanService
contingencyPlanService
;
/**
* 创建数字预案
...
...
YeeAmosFireAutoSysService/src/main/java/com/yeejoin/amos/fas/business/dao/mapper/PlanDocMapper.java
View file @
640a10a8
...
...
@@ -23,8 +23,5 @@ public interface PlanDocMapper {
*/
int
updateIsDeleteByPlanIdList
(
@Param
(
"planIdList"
)
List
<
Long
>
idList
,
@Param
(
"isDelete"
)
Boolean
isDelete
);
/**
* 获取预案已使用的文档id
*/
Map
<
String
,
Long
>
getUsedDocId
();
int
logicDeleteByDocIdList
(
@Param
(
"docIdList"
)
List
<
Long
>
idList
);
}
YeeAmosFireAutoSysService/src/main/java/com/yeejoin/amos/fas/business/dao/mapper/PlanEquipmentMapper.java
View file @
640a10a8
...
...
@@ -22,4 +22,5 @@ public interface PlanEquipmentMapper {
*/
int
updateIsDeleteByPlanIdList
(
@Param
(
"planIdList"
)
List
<
Long
>
idList
,
@Param
(
"isDelete"
)
Boolean
isDelete
);
int
logicDeleteByEquipIdList
(
@Param
(
"equipIdList"
)
List
<
Long
>
idList
);
}
YeeAmosFireAutoSysService/src/main/java/com/yeejoin/amos/fas/business/dao/mapper/PlanRuleMapper.java
View file @
640a10a8
...
...
@@ -22,5 +22,6 @@ public interface PlanRuleMapper {
*/
int
updateIsDeleteByPlanIdList
(
@Param
(
"planIdList"
)
List
<
Long
>
idList
,
@Param
(
"isDelete"
)
Boolean
isDelete
);
int
logicDeleteByRuleIdList
(
@Param
(
"ruleIdList"
)
List
<
String
>
idList
);
}
YeeAmosFireAutoSysService/src/main/java/com/yeejoin/amos/fas/business/service/impl/ContingencyPlanServiceImpl.java
View file @
640a10a8
This diff is collapsed.
Click to expand it.
YeeAmosFireAutoSysService/src/main/java/com/yeejoin/amos/fas/business/service/intfc/ContingencyPlanService.java
→
YeeAmosFireAutoSysService/src/main/java/com/yeejoin/amos/fas/business/service/intfc/
I
ContingencyPlanService.java
View file @
640a10a8
...
...
@@ -7,6 +7,8 @@ import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import
com.yeejoin.amos.fas.business.vo.PlanDetailVo
;
import
com.yeejoin.amos.fas.dao.entity.PlanDetail
;
import
com.yeejoin.amos.fas.exception.YeeException
;
import
org.apache.logging.log4j.LogManager
;
import
org.apache.logging.log4j.Logger
;
import
org.springframework.transaction.annotation.Transactional
;
import
java.util.Date
;
...
...
@@ -18,7 +20,11 @@ import java.util.Map;
* @date 2021-01-14
* 预案操作
*/
public
interface
ContingencyPlanService
{
public
interface
IContingencyPlanService
{
String
DELETE_SYNC_PLAN_DOC
=
"DELETE_SYNC_PLAN_DOC"
;
String
DELETE_SYNC_PLAN_RULE
=
"DELETE_SYNC_PLAN_RULE"
;
String
DELETE_SYNC_PLAN_EQUIP
=
"DELETE_SYNC_PLAN_EQUIP"
;
String
planStart
(
ContingencyPlanParamVo
vo
);
...
...
@@ -100,4 +106,9 @@ public interface ContingencyPlanService {
* @return
*/
Map
<
Long
,
Long
>
getPlanUsedEquipments
();
/**
* 监听文档取消发布/规则、装备删除动态
*/
void
subscribeTopic
();
}
YeeAmosFireAutoSysService/src/main/java/com/yeejoin/amos/fas/config/ApplicationRunnerImpl.java
View file @
640a10a8
package
com
.
yeejoin
.
amos
.
fas
.
config
;
import
com.yeejoin.amos.fas.business.service.intfc.IContingencyPlanService
;
import
com.yeejoin.amos.fas.business.service.intfc.IEquipmentHandlerService
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.boot.ApplicationArguments
;
...
...
@@ -18,10 +19,13 @@ import org.springframework.stereotype.Component;
public
class
ApplicationRunnerImpl
implements
ApplicationRunner
{
@Autowired
IEquipmentHandlerService
equipmentHandlerService
;
private
IEquipmentHandlerService
equipmentHandlerService
;
@Autowired
private
IContingencyPlanService
contingencyPlanService
;
@Override
public
void
run
(
ApplicationArguments
args
)
throws
Exception
{
equipmentHandlerService
.
subscribeTopic
();
contingencyPlanService
.
subscribeTopic
();
}
}
YeeAmosFireAutoSysStart/src/main/resources/db/mapper/PlanDocMapper.xml
View file @
640a10a8
...
...
@@ -8,4 +8,11 @@
#{planId}
</foreach>
</update>
<update
id=
"logicDeleteByDocIdList"
parameterType=
"list"
>
UPDATE c_plan_doc SET is_delete = 1 WHERE doc_id IN
<foreach
collection=
"docIdList"
separator=
","
item=
"docId"
open=
"("
close=
")"
>
#{docId}
</foreach>
</update>
</mapper>
\ No newline at end of file
YeeAmosFireAutoSysStart/src/main/resources/db/mapper/PlanEquipmentMapper.xml
View file @
640a10a8
...
...
@@ -8,4 +8,12 @@
#{planId}
</foreach>
</update>
<update
id=
"logicDeleteByEquipIdList"
parameterType=
"list"
>
UPDATE c_plan_equipment SET is_delete = 1 WHERE fire_equipment_id IN
<foreach
collection=
"equipIdList"
separator=
","
item=
"equipId"
open=
"("
close=
")"
>
#{equipId}
</foreach>
</update>
</mapper>
\ No newline at end of file
YeeAmosFireAutoSysStart/src/main/resources/db/mapper/PlanRuleMapper.xml
View file @
640a10a8
...
...
@@ -8,4 +8,11 @@
#{planId}
</foreach>
</update>
<update
id=
"logicDeleteByRuleIdList"
parameterType=
"list"
>
UPDATE c_plan_rule SET is_delete = 1 WHERE rule_id IN
<foreach
collection=
"ruleIdList"
separator=
","
item=
"ruleId"
open=
"("
close=
")"
>
#{ruleId}
</foreach>
</update>
</mapper>
\ No newline at end of file
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