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
3eec8871
Commit
3eec8871
authored
Nov 12, 2021
by
chenhao
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'developer' of
http://172.16.10.76/moa/amos-boot-biz
into developer
parents
0f341cc9
a13be602
Hide whitespace changes
Inline
Side-by-side
Showing
47 changed files
with
888 additions
and
423 deletions
+888
-423
DateUtils.java
...ava/com/yeejoin/amos/boot/biz/common/utils/DateUtils.java
+30
-8
FireBuildingDto.java
...yeejoin/amos/boot/module/ccs/api/dto/FireBuildingDto.java
+8
-0
FireVideoDto.java
...om/yeejoin/amos/boot/module/ccs/api/dto/FireVideoDto.java
+0
-1
FireWaterDto.java
...om/yeejoin/amos/boot/module/ccs/api/dto/FireWaterDto.java
+0
-1
BaseEntity.java
...m/yeejoin/amos/boot/module/ccs/api/entity/BaseEntity.java
+2
-2
FireBuilding.java
...yeejoin/amos/boot/module/ccs/api/entity/FireBuilding.java
+6
-1
FireAlarmDayStatisticsMapper.java
...t/module/ccs/api/mapper/FireAlarmDayStatisticsMapper.java
+13
-1
FireDangerDayStatisticsMapper.java
.../module/ccs/api/mapper/FireDangerDayStatisticsMapper.java
+12
-1
FireLatentDangerMapper.java
...os/boot/module/ccs/api/mapper/FireLatentDangerMapper.java
+11
-2
IFireBuildingService.java
...mos/boot/module/ccs/api/service/IFireBuildingService.java
+4
-1
IStatisticsService.java
.../amos/boot/module/ccs/api/service/IStatisticsService.java
+26
-0
FireAlarmDayStatisticsMapper.xml
...rc/main/resources/mapper/FireAlarmDayStatisticsMapper.xml
+24
-0
FireDangerDayStatisticsMapper.xml
...c/main/resources/mapper/FireDangerDayStatisticsMapper.xml
+24
-0
FireEquipmentAlarmLogMapper.xml
...src/main/resources/mapper/FireEquipmentAlarmLogMapper.xml
+10
-2
FireLatentDangerMapper.xml
...-api/src/main/resources/mapper/FireLatentDangerMapper.xml
+34
-14
CompanyRo.java
...a/com/yeejoin/amos/boot/module/jcs/api/dto/CompanyRo.java
+1
-1
ExecuteStateNameEnum.java
...n/amos/supervision/common/enums/ExecuteStateNameEnum.java
+47
-0
RuleTypeEnum.java
...m/yeejoin/amos/supervision/common/enums/RuleTypeEnum.java
+6
-1
FireAlarmDayStatisticsController.java
.../ccs/biz/controller/FireAlarmDayStatisticsController.java
+0
-71
FireBuildingController.java
...oot/module/ccs/biz/controller/FireBuildingController.java
+14
-5
FireDangerDayStatisticsController.java
...ccs/biz/controller/FireDangerDayStatisticsController.java
+3
-60
FireLatentDangerController.java
...module/ccs/biz/controller/FireLatentDangerController.java
+13
-0
FireVehicleController.java
...boot/module/ccs/biz/controller/FireVehicleController.java
+6
-5
FireVideoController.java
...s/boot/module/ccs/biz/controller/FireVideoController.java
+18
-6
FireWaterController.java
...s/boot/module/ccs/biz/controller/FireWaterController.java
+6
-19
StatisticsController.java
.../boot/module/ccs/biz/controller/StatisticsController.java
+50
-0
FireAlarmDayStatisticsServiceImpl.java
...s/biz/service/impl/FireAlarmDayStatisticsServiceImpl.java
+22
-12
FireBuildingServiceImpl.java
.../module/ccs/biz/service/impl/FireBuildingServiceImpl.java
+14
-7
FireDangerDayStatisticsServiceImpl.java
.../biz/service/impl/FireDangerDayStatisticsServiceImpl.java
+22
-12
FireLatentDangerServiceImpl.java
...ule/ccs/biz/service/impl/FireLatentDangerServiceImpl.java
+22
-13
FireVehicleServiceImpl.java
...t/module/ccs/biz/service/impl/FireVehicleServiceImpl.java
+2
-10
FireVideoServiceImpl.java
...oot/module/ccs/biz/service/impl/FireVideoServiceImpl.java
+2
-9
FireWaterServiceImpl.java
...oot/module/ccs/biz/service/impl/FireWaterServiceImpl.java
+1
-1
StatisticsServiceImpl.java
...ot/module/ccs/biz/service/impl/StatisticsServiceImpl.java
+58
-0
PlanRo.java
...ava/com/yeejoin/amos/supervision/business/dto/PlanRo.java
+53
-0
CheckServiceImpl.java
...s/supervision/business/service/impl/CheckServiceImpl.java
+3
-9
PlanAuditServiceImpl.java
...pervision/business/service/impl/PlanAuditServiceImpl.java
+1
-1
PlanServiceImpl.java
...os/supervision/business/service/impl/PlanServiceImpl.java
+18
-11
PlanTaskServiceImpl.java
...upervision/business/service/impl/PlanTaskServiceImpl.java
+8
-12
RulePlanService.java
...os/supervision/business/service/impl/RulePlanService.java
+77
-0
MsgParamUtils.java
...yeejoin/amos/supervision/business/util/MsgParamUtils.java
+11
-0
AsyncTask.java
...va/com/yeejoin/amos/supervision/core/async/AsyncTask.java
+0
-83
RemoteSecurityService.java
...yeejoin/amos/supervision/feign/RemoteSecurityService.java
+0
-30
MessageAction.java
...m/yeejoin/amos/supervision/rule/action/MessageAction.java
+40
-0
application.properties
...boot-system-ccs/src/main/resources/application.properties
+1
-1
amos-ccs-biz.sql
...ccs/src/main/resources/db/changelog/init/amos-ccs-biz.sql
+164
-8
AmosTzsApplication.java
...zs/src/main/java/com/yeejoin/amos/AmosTzsApplication.java
+1
-2
No files found.
amos-boot-biz-common/src/main/java/com/yeejoin/amos/boot/biz/common/utils/DateUtils.java
View file @
3eec8871
...
@@ -709,6 +709,7 @@ public class DateUtils {
...
@@ -709,6 +709,7 @@ public class DateUtils {
/**
/**
* 根据两个日期返回相差的时分秒
* 根据两个日期返回相差的时分秒
*
* @param newTime 靠后时间
* @param newTime 靠后时间
* @param oldTime 靠前时间
* @param oldTime 靠前时间
* @return
* @return
...
@@ -718,7 +719,7 @@ public class DateUtils {
...
@@ -718,7 +719,7 @@ public class DateUtils {
Long
oldTimes
=
oldTime
.
getTime
();
Long
oldTimes
=
oldTime
.
getTime
();
// 不改时间会多加八个小时
// 不改时间会多加八个小时
timeSdf
.
setTimeZone
(
TimeZone
.
getTimeZone
(
"GMT+00:00"
));
timeSdf
.
setTimeZone
(
TimeZone
.
getTimeZone
(
"GMT+00:00"
));
return
timeSdf
.
format
(
newTimes
-
oldTimes
);
return
timeSdf
.
format
(
newTimes
-
oldTimes
);
}
}
/**
/**
...
@@ -748,11 +749,12 @@ public class DateUtils {
...
@@ -748,11 +749,12 @@ public class DateUtils {
/**
/**
* 通过月份计算季度
* 通过月份计算季度
*
* @param month
* @param month
* @return
* @return
*/
*/
public
static
int
getQuarter
(
int
month
)
{
public
static
int
getQuarter
(
int
month
)
{
if
(
month
<
1
||
month
>
12
)
{
if
(
month
<
1
||
month
>
12
)
{
throw
new
IllegalArgumentException
(
"month is invalid."
);
throw
new
IllegalArgumentException
(
"month is invalid."
);
}
}
return
(
month
-
1
)
/
3
+
1
;
return
(
month
-
1
)
/
3
+
1
;
...
@@ -760,11 +762,12 @@ public class DateUtils {
...
@@ -760,11 +762,12 @@ public class DateUtils {
/**
/**
* 通过月份计算季度
* 通过月份计算季度
*
* @param month
* @param month
* @return
* @return
*/
*/
public
static
String
getQuarterStr
(
int
month
)
{
public
static
String
getQuarterStr
(
int
month
)
{
if
(
month
<
1
||
month
>
12
)
{
if
(
month
<
1
||
month
>
12
)
{
throw
new
IllegalArgumentException
(
"month is invalid."
);
throw
new
IllegalArgumentException
(
"month is invalid."
);
}
}
return
(
month
-
1
)
/
3
+
1
+
""
;
return
(
month
-
1
)
/
3
+
1
+
""
;
...
@@ -772,6 +775,7 @@ public class DateUtils {
...
@@ -772,6 +775,7 @@ public class DateUtils {
/**
/**
* 获取指定时间所在周的第一天日期
* 获取指定时间所在周的第一天日期
*
* @param date
* @param date
* @return
* @return
*/
*/
...
@@ -785,8 +789,25 @@ public class DateUtils {
...
@@ -785,8 +789,25 @@ public class DateUtils {
return
getDate
(
calendar
.
getTime
());
return
getDate
(
calendar
.
getTime
());
}
}
public
static
Date
beginDateOfWeek
(
Date
date
)
{
Calendar
calendar
=
Calendar
.
getInstance
();
calendar
.
setFirstDayOfWeek
(
Calendar
.
MONDAY
);
calendar
.
setTime
(
date
);
calendar
.
set
(
Calendar
.
DAY_OF_WEEK
,
Calendar
.
MONDAY
);
return
calendar
.
getTime
();
}
public
static
Date
endDateOfWeek
(
Date
date
)
{
Calendar
calendar
=
Calendar
.
getInstance
();
calendar
.
setFirstDayOfWeek
(
Calendar
.
MONDAY
);
calendar
.
setTime
(
date
);
calendar
.
set
(
Calendar
.
DAY_OF_WEEK
,
Calendar
.
SUNDAY
);
return
calendar
.
getTime
();
}
/**
/**
* 获取指定时间所在周的最后一天日期
* 获取指定时间所在周的最后一天日期
*
* @param date
* @param date
* @return
* @return
*/
*/
...
@@ -802,18 +823,19 @@ public class DateUtils {
...
@@ -802,18 +823,19 @@ public class DateUtils {
/**
/**
* 将秒数转换为时分秒格式
* 将秒数转换为时分秒格式
*
* @param times
* @param times
* @return
* @return
*/
*/
public
static
String
secondsToTimeStr
(
int
times
)
{
public
static
String
secondsToTimeStr
(
int
times
)
{
if
(
times
<=
0
)
{
if
(
times
<=
0
)
{
return
"00:00:00"
;
return
"00:00:00"
;
}
}
int
h
=
times
/
3600
;
int
h
=
times
/
3600
;
int
m
=
(
times
-
h
*
3600
)/
60
;
int
m
=
(
times
-
h
*
3600
)
/
60
;
int
s
=
times
-
h
*
3600
-
m
*
60
;
int
s
=
times
-
h
*
3600
-
m
*
60
;
String
time
=
"%02d:%02d:%02d"
;
String
time
=
"%02d:%02d:%02d"
;
time
=
String
.
format
(
time
,
h
,
m
,
s
);
time
=
String
.
format
(
time
,
h
,
m
,
s
);
return
time
;
return
time
;
}
}
}
}
amos-boot-module/amos-boot-module-api/amos-boot-module-ccs-api/src/main/java/com/yeejoin/amos/boot/module/ccs/api/dto/FireBuildingDto.java
View file @
3eec8871
...
@@ -5,6 +5,8 @@ import io.swagger.annotations.ApiModelProperty;
...
@@ -5,6 +5,8 @@ import io.swagger.annotations.ApiModelProperty;
import
lombok.Data
;
import
lombok.Data
;
import
lombok.EqualsAndHashCode
;
import
lombok.EqualsAndHashCode
;
import
java.util.List
;
/**
/**
* 消防建筑表
* 消防建筑表
*
*
...
@@ -43,6 +45,9 @@ public class FireBuildingDto extends BaseDto {
...
@@ -43,6 +45,9 @@ public class FireBuildingDto extends BaseDto {
@ApiModelProperty
(
value
=
"父级mrid"
)
@ApiModelProperty
(
value
=
"父级mrid"
)
private
String
parentMrid
;
private
String
parentMrid
;
@ApiModelProperty
(
value
=
"树形mrids,包括自己,冗余用于树形查询"
)
private
String
treeMrids
;
@ApiModelProperty
(
value
=
"类型(建筑、楼层、房间)"
)
@ApiModelProperty
(
value
=
"类型(建筑、楼层、房间)"
)
private
String
type
;
private
String
type
;
...
@@ -54,4 +59,7 @@ public class FireBuildingDto extends BaseDto {
...
@@ -54,4 +59,7 @@ public class FireBuildingDto extends BaseDto {
@ApiModelProperty
(
value
=
"纬度"
)
@ApiModelProperty
(
value
=
"纬度"
)
private
String
lat
;
private
String
lat
;
@ApiModelProperty
(
value
=
"子节点"
)
private
List
<
FireBuildingDto
>
children
;
}
}
amos-boot-module/amos-boot-module-api/amos-boot-module-ccs-api/src/main/java/com/yeejoin/amos/boot/module/ccs/api/dto/FireVideoDto.java
View file @
3eec8871
package
com
.
yeejoin
.
amos
.
boot
.
module
.
ccs
.
api
.
dto
;
package
com
.
yeejoin
.
amos
.
boot
.
module
.
ccs
.
api
.
dto
;
import
com.yeejoin.amos.boot.biz.common.dto.BaseDto
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModelProperty
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
import
lombok.Data
;
...
...
amos-boot-module/amos-boot-module-api/amos-boot-module-ccs-api/src/main/java/com/yeejoin/amos/boot/module/ccs/api/dto/FireWaterDto.java
View file @
3eec8871
package
com
.
yeejoin
.
amos
.
boot
.
module
.
ccs
.
api
.
dto
;
package
com
.
yeejoin
.
amos
.
boot
.
module
.
ccs
.
api
.
dto
;
import
com.yeejoin.amos.boot.biz.common.dto.BaseDto
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModel
;
import
io.swagger.annotations.ApiModelProperty
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
import
lombok.Data
;
...
...
amos-boot-module/amos-boot-module-api/amos-boot-module-ccs-api/src/main/java/com/yeejoin/amos/boot/module/ccs/api/entity/BaseEntity.java
View file @
3eec8871
...
@@ -20,13 +20,13 @@ public class BaseEntity implements Serializable {
...
@@ -20,13 +20,13 @@ public class BaseEntity implements Serializable {
private
static
final
long
serialVersionUID
=
1L
;
private
static
final
long
serialVersionUID
=
1L
;
@TableId
(
value
=
"id"
,
type
=
IdType
.
ID_WORKER
)
@TableId
(
value
=
"id"
,
type
=
IdType
.
ID_WORKER
)
protected
Lo
ng
id
;
protected
Stri
ng
id
;
/**
/**
* 同步日期
* 同步日期
*/
*/
@TableField
(
value
=
"syn_date"
,
fill
=
FieldFill
.
INSERT_UPDATE
)
@TableField
(
value
=
"syn_date"
,
fill
=
FieldFill
.
INSERT_UPDATE
)
protected
Date
rec
Date
;
protected
Date
syn
Date
;
/**
/**
* 业务创建日期
* 业务创建日期
...
...
amos-boot-module/amos-boot-module-api/amos-boot-module-ccs-api/src/main/java/com/yeejoin/amos/boot/module/ccs/api/entity/FireBuilding.java
View file @
3eec8871
...
@@ -2,7 +2,6 @@ package com.yeejoin.amos.boot.module.ccs.api.entity;
...
@@ -2,7 +2,6 @@ package com.yeejoin.amos.boot.module.ccs.api.entity;
import
com.baomidou.mybatisplus.annotation.TableField
;
import
com.baomidou.mybatisplus.annotation.TableField
;
import
com.baomidou.mybatisplus.annotation.TableName
;
import
com.baomidou.mybatisplus.annotation.TableName
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
import
lombok.Data
;
import
lombok.EqualsAndHashCode
;
import
lombok.EqualsAndHashCode
;
import
lombok.experimental.Accessors
;
import
lombok.experimental.Accessors
;
...
@@ -68,6 +67,12 @@ public class FireBuilding extends BaseEntity {
...
@@ -68,6 +67,12 @@ public class FireBuilding extends BaseEntity {
@TableField
(
"parent_mrid"
)
@TableField
(
"parent_mrid"
)
private
String
parentMrid
;
private
String
parentMrid
;
/**
* 树形mrids,包括自己,冗余用于树形查询
*/
private
String
treeMrids
;
/**
/**
* 类型(建筑、楼层、房间)
* 类型(建筑、楼层、房间)
*/
*/
...
...
amos-boot-module/amos-boot-module-api/amos-boot-module-ccs-api/src/main/java/com/yeejoin/amos/boot/module/ccs/api/mapper/FireAlarmDayStatisticsMapper.java
View file @
3eec8871
package
com
.
yeejoin
.
amos
.
boot
.
module
.
ccs
.
api
.
mapper
;
package
com
.
yeejoin
.
amos
.
boot
.
module
.
ccs
.
api
.
mapper
;
import
com.yeejoin.amos.boot.module.ccs.api.entity.FireAlarmDayStatistics
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
import
com.yeejoin.amos.boot.module.ccs.api.entity.FireAlarmDayStatistics
;
import
org.apache.ibatis.annotations.Param
;
import
java.util.List
;
/**
/**
* 换流站告警日统计 Mapper 接口
* 换流站告警日统计 Mapper 接口
...
@@ -11,4 +14,13 @@ import com.baomidou.mybatisplus.core.mapper.BaseMapper;
...
@@ -11,4 +14,13 @@ import com.baomidou.mybatisplus.core.mapper.BaseMapper;
*/
*/
public
interface
FireAlarmDayStatisticsMapper
extends
BaseMapper
<
FireAlarmDayStatistics
>
{
public
interface
FireAlarmDayStatisticsMapper
extends
BaseMapper
<
FireAlarmDayStatistics
>
{
/**
* 告警次数-折线图使用
*
* @param stationCode 换流程code
* @param beginDate 开始日期
* @param endDate 结束日期
* @return List<String>
*/
List
<
String
>
queryAlarmTimesTrend
(
@Param
(
"stationCode"
)
String
stationCode
,
@Param
(
"beginDate"
)
String
beginDate
,
@Param
(
"endDate"
)
String
endDate
);
}
}
amos-boot-module/amos-boot-module-api/amos-boot-module-ccs-api/src/main/java/com/yeejoin/amos/boot/module/ccs/api/mapper/FireDangerDayStatisticsMapper.java
View file @
3eec8871
package
com
.
yeejoin
.
amos
.
boot
.
module
.
ccs
.
api
.
mapper
;
package
com
.
yeejoin
.
amos
.
boot
.
module
.
ccs
.
api
.
mapper
;
import
com.yeejoin.amos.boot.module.ccs.api.entity.FireDangerDayStatistics
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
import
com.yeejoin.amos.boot.module.ccs.api.entity.FireDangerDayStatistics
;
import
java.util.List
;
/**
/**
* 换流站隐患日统计 Mapper 接口
* 换流站隐患日统计 Mapper 接口
...
@@ -11,4 +13,13 @@ import com.baomidou.mybatisplus.core.mapper.BaseMapper;
...
@@ -11,4 +13,13 @@ import com.baomidou.mybatisplus.core.mapper.BaseMapper;
*/
*/
public
interface
FireDangerDayStatisticsMapper
extends
BaseMapper
<
FireDangerDayStatistics
>
{
public
interface
FireDangerDayStatisticsMapper
extends
BaseMapper
<
FireDangerDayStatistics
>
{
/**
* 隐患增长趋势
*
* @param stationCode 换流站code
* @param beginDate 开始日期
* @param endDate 结束日期
* @return List<String>
*/
List
<
String
>
queryDangerTimesTrend
(
String
stationCode
,
String
beginDate
,
String
endDate
);
}
}
amos-boot-module/amos-boot-module-api/amos-boot-module-ccs-api/src/main/java/com/yeejoin/amos/boot/module/ccs/api/mapper/FireLatentDangerMapper.java
View file @
3eec8871
package
com
.
yeejoin
.
amos
.
boot
.
module
.
ccs
.
api
.
mapper
;
package
com
.
yeejoin
.
amos
.
boot
.
module
.
ccs
.
api
.
mapper
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
import
com.yeejoin.amos.boot.module.ccs.api.dto.FireLatentDangerDto
;
import
com.yeejoin.amos.boot.module.ccs.api.dto.FireLatentDangerDto
;
import
com.yeejoin.amos.boot.module.ccs.api.entity.FireLatentDanger
;
import
com.yeejoin.amos.boot.module.ccs.api.entity.FireLatentDanger
;
import
com.baomidou.mybatisplus.core.mapper.BaseMapper
;
import
org.apache.ibatis.annotations.Param
;
import
org.apache.ibatis.annotations.Param
;
import
java.util.List
;
import
java.util.List
;
import
java.util.Map
;
/**
/**
* 隐患信息 Mapper 接口
* 隐患信息 Mapper 接口
...
@@ -16,10 +17,18 @@ import java.util.List;
...
@@ -16,10 +17,18 @@ import java.util.List;
public
interface
FireLatentDangerMapper
extends
BaseMapper
<
FireLatentDanger
>
{
public
interface
FireLatentDangerMapper
extends
BaseMapper
<
FireLatentDanger
>
{
/**
/**
* 隐患列表倒序列表
* 隐患列表倒序列表
* @param top 限制w
*
* @param top 限制w
* @param stationCode 站code
* @param stationCode 站code
* @return List<FireLatentDangerDto>
* @return List<FireLatentDangerDto>
*/
*/
List
<
FireLatentDangerDto
>
queryDangerList
(
@Param
(
"top"
)
Long
top
,
@Param
(
"stationCode"
)
String
stationCode
);
List
<
FireLatentDangerDto
>
queryDangerList
(
@Param
(
"top"
)
Long
top
,
@Param
(
"stationCode"
)
String
stationCode
);
/**
* 隐患分组列表
*
* @param stationCode 换流站编号
* @return List<Map < String, Object>>
*/
List
<
Map
<
String
,
Object
>>
dangerStateGroupMap
(
String
stationCode
);
}
}
amos-boot-module/amos-boot-module-api/amos-boot-module-ccs-api/src/main/java/com/yeejoin/amos/boot/module/ccs/api/service/IFireBuildingService.java
View file @
3eec8871
package
com
.
yeejoin
.
amos
.
boot
.
module
.
ccs
.
api
.
service
;
package
com
.
yeejoin
.
amos
.
boot
.
module
.
ccs
.
api
.
service
;
import
com.yeejoin.amos.boot.module.ccs.api.dto.FireBuildingDto
;
import
java.util.List
;
/**
/**
* 消防建筑表接口类
* 消防建筑表接口类
*
*
...
@@ -8,5 +12,4 @@ package com.yeejoin.amos.boot.module.ccs.api.service;
...
@@ -8,5 +12,4 @@ package com.yeejoin.amos.boot.module.ccs.api.service;
* @date 2021-11-09
* @date 2021-11-09
*/
*/
public
interface
IFireBuildingService
{
public
interface
IFireBuildingService
{
}
}
amos-boot-module/amos-boot-module-api/amos-boot-module-ccs-api/src/main/java/com/yeejoin/amos/boot/module/ccs/api/service/IStatisticsService.java
0 → 100644
View file @
3eec8871
package
com
.
yeejoin
.
amos
.
boot
.
module
.
ccs
.
api
.
service
;
import
java.text.ParseException
;
import
java.util.List
;
import
java.util.Map
;
/**
* @author DELL
*/
public
interface
IStatisticsService
{
/**
* 告警隐患统计
* @param stationCode 站编号
* @return Map<String, Object>
*/
Map
<
String
,
Object
>
alarmAndDangerNumCount
(
String
stationCode
)
throws
ParseException
;
/**
* 告警和隐患趋势
* @param stationCode 换流站编号
* @param beginDate 开始日期
* @param endDate 结束日期
* @return Map<String, Object>
*/
Map
<
String
,
Object
>
alarmAndDangerTrend
(
String
stationCode
,
String
beginDate
,
String
endDate
);
}
amos-boot-module/amos-boot-module-api/amos-boot-module-ccs-api/src/main/resources/mapper/FireAlarmDayStatisticsMapper.xml
View file @
3eec8871
...
@@ -2,4 +2,28 @@
...
@@ -2,4 +2,28 @@
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper
namespace=
"com.yeejoin.amos.boot.module.ccs.api.mapper.FireAlarmDayStatisticsMapper"
>
<mapper
namespace=
"com.yeejoin.amos.boot.module.ccs.api.mapper.FireAlarmDayStatisticsMapper"
>
<select
id=
"queryAlarmTimesTrend"
resultType=
"java.lang.String"
>
select
(SELECT
IFNULL(sum(s.alarm_times),0)
FROM `asf_fire_alarm_day_statistics` s
<where>
<if
test=
"stationCode != null and stationCode != ''"
>
s.station_code = #{stationCode}
</if>
s.collect_date = t.date
</where>
) as times
from
(SELECT
DATE_FORMAT(DATE( DATE_ADD( #{beginDate}, INTERVAL @s DAY )),'%Y-%m-%d') AS date,
@s := @s + 1 AS `index`
FROM
mysql.help_topic,
( SELECT @s := 0 ) temp
WHERE
@s
<![CDATA[<=]]>
DATEDIFF(#{endDate},#{beginDate})) t
GROUP BY t.date
</select>
</mapper>
</mapper>
amos-boot-module/amos-boot-module-api/amos-boot-module-ccs-api/src/main/resources/mapper/FireDangerDayStatisticsMapper.xml
View file @
3eec8871
...
@@ -2,4 +2,28 @@
...
@@ -2,4 +2,28 @@
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper
namespace=
"com.yeejoin.amos.boot.module.ccs.api.mapper.FireDangerDayStatisticsMapper"
>
<mapper
namespace=
"com.yeejoin.amos.boot.module.ccs.api.mapper.FireDangerDayStatisticsMapper"
>
<select
id=
"queryDangerTimesTrend"
resultType=
"java.lang.String"
>
select
(SELECT
IFNULL(sum(s.danger_times),0)
FROM `asf_fire_danger_day_statistics` s
<where>
<if
test=
"stationCode != null and stationCode != ''"
>
s.station_code = #{stationCode}
</if>
s.collect_date = t.date
</where>
) as times
from
(SELECT
DATE_FORMAT(DATE( DATE_ADD( #{beginDate}, INTERVAL @s DAY )),'%Y-%m-%d') AS date,
@s := @s + 1 AS `index`
FROM
mysql.help_topic,
( SELECT @s := 0 ) temp
WHERE
@s
<![CDATA[<=]]>
DATEDIFF(#{endDate},#{beginDate})) t
GROUP BY t.date
</select>
</mapper>
</mapper>
amos-boot-module/amos-boot-module-api/amos-boot-module-ccs-api/src/main/resources/mapper/FireEquipmentAlarmLogMapper.xml
View file @
3eec8871
...
@@ -14,8 +14,16 @@
...
@@ -14,8 +14,16 @@
s.name as station_name,
s.name as station_name,
a.station_code,
a.station_code,
a.location,
a.location,
a.lat,
<choose>
a.lng,
<when
test=
"stationCode != null and stationCode != ''"
>
a.lat,
a.lng,
</when>
<otherwise>
s.lng,
s.lat,
</otherwise>
</choose>
s.lat as stationLat,
s.lat as stationLat,
s.lng as stationLng
s.lng as stationLng
from
from
...
...
amos-boot-module/amos-boot-module-api/amos-boot-module-ccs-api/src/main/resources/mapper/FireLatentDangerMapper.xml
View file @
3eec8871
...
@@ -4,19 +4,27 @@
...
@@ -4,19 +4,27 @@
<select
id=
"queryDangerList"
resultType=
"com.yeejoin.amos.boot.module.ccs.api.dto.FireLatentDangerDto"
>
<select
id=
"queryDangerList"
resultType=
"com.yeejoin.amos.boot.module.ccs.api.dto.FireLatentDangerDto"
>
select
select
d.id,
d.id,
d.danger_name,
d.danger_name,
d.danger_state,
d.danger_state,
d.danger_state_name,
d.danger_state_name,
d.danger_level,
d.danger_level,
d.danger_level_name,
d.danger_level_name,
s.name as station_name,
s.name as station_name,
d.station_code,
d.station_code,
d.discovery_date,
d.discovery_date,
d.lat,
<choose>
d.lng,
<when
test=
"stationCode != null and stationCode != ''"
>
s.lat as stationLat,
d.lat,
s.lng as stationLng
d.lng,
</when>
<otherwise>
s.lng,
s.lat,
</otherwise>
</choose>
s.lng as stationLng,
s.lat as stationLat
from
from
asf_fire_latent_danger d,
asf_fire_latent_danger d,
asf_fire_station_info s
asf_fire_station_info s
...
@@ -27,7 +35,19 @@
...
@@ -27,7 +35,19 @@
</if>
</if>
order by d.discovery_date desc
order by d.discovery_date desc
<if
test=
"top != null"
>
<if
test=
"top != null"
>
limit ${top}
limit ${top}
</if>
</if>
</select>
</select>
<select
id=
"dangerStateGroupMap"
resultType=
"java.util.Map"
>
SELECT
d.danger_state as dangerState,
count(1) as num
FROM `asf_fire_latent_danger` d
<where>
<if
test=
"stationCode != null and stationCode != ''"
>
d.station_code = #{stationCode}
</if>
</where>
GROUP BY d.danger_state
</select>
</mapper>
</mapper>
amos-boot-module/amos-boot-module-api/amos-boot-module-jcs-api/src/main/java/com/yeejoin/amos/boot/module/jcs/api/dto/Company
Dt
o.java
→
amos-boot-module/amos-boot-module-api/amos-boot-module-jcs-api/src/main/java/com/yeejoin/amos/boot/module/jcs/api/dto/Company
R
o.java
View file @
3eec8871
...
@@ -11,7 +11,7 @@ import lombok.Data;
...
@@ -11,7 +11,7 @@ import lombok.Data;
* @createDate: 2021/11/11
* @createDate: 2021/11/11
*/
*/
@Data
@Data
public
class
Company
Dt
o
{
public
class
Company
R
o
{
@ApiModelProperty
(
value
=
" 调派单位id"
)
@ApiModelProperty
(
value
=
" 调派单位id"
)
private
Long
powerCompanyId
;
private
Long
powerCompanyId
;
...
...
amos-boot-module/amos-boot-module-api/amos-boot-module-supervision-api/src/main/java/com/yeejoin/amos/supervision/common/enums/ExecuteStateNameEnum.java
0 → 100644
View file @
3eec8871
package
com
.
yeejoin
.
amos
.
supervision
.
common
.
enums
;
public
enum
ExecuteStateNameEnum
{
通过
(
"通过"
,
0
),
不通过
(
"不通过"
,
1
);
/**
* 名称,描述
*/
private
String
name
;
/**
* 编码
*/
private
Integer
code
;
ExecuteStateNameEnum
(
String
name
,
Integer
code
)
{
this
.
name
=
name
;
this
.
code
=
code
;
}
public
String
getName
()
{
return
name
;
}
public
void
setName
(
String
name
)
{
this
.
name
=
name
;
}
public
Integer
getCode
()
{
return
code
;
}
public
void
setCode
(
Integer
code
)
{
this
.
code
=
code
;
}
public
static
String
getNameByCode
(
Integer
code
)
{
for
(
ExecuteStateNameEnum
e
:
ExecuteStateNameEnum
.
values
())
{
if
(
code
.
equals
(
e
.
getCode
()))
{
return
e
.
getName
();
}
}
return
null
;
}
}
amos-boot-module/amos-boot-module-api/amos-boot-module-supervision-api/src/main/java/com/yeejoin/amos/supervision/common/enums/RuleTypeEnum.java
View file @
3eec8871
...
@@ -8,8 +8,13 @@ package com.yeejoin.amos.supervision.common.enums;
...
@@ -8,8 +8,13 @@ package com.yeejoin.amos.supervision.common.enums;
public
enum
RuleTypeEnum
{
public
enum
RuleTypeEnum
{
GETCONTENT
(
"维保项获取"
,
"getContent"
),
GETCONTENT
(
"维保项获取"
,
"getContent"
),
CHECKRESULT
(
"结果校验"
,
"checkResult"
)
;
CHECKRESULT
(
"结果校验"
,
"checkResult"
)
,
// 防火监督
计划提交
(
"计划提交"
,
"addPlan"
),
计划审核
(
"计划审核"
,
"planAudit"
),
计划生成
(
"计划生成"
,
"addPlanTask"
),
计划完成
(
"计划完成"
,
"planCompleted"
);
/**
/**
* 名称,描述
* 名称,描述
...
...
amos-boot-module/amos-boot-module-biz/amos-boot-module-ccs-biz/src/main/java/com/yeejoin/amos/boot/module/ccs/biz/controller/FireAlarmDayStatisticsController.java
View file @
3eec8871
...
@@ -31,77 +31,6 @@ public class FireAlarmDayStatisticsController extends BaseController {
...
@@ -31,77 +31,6 @@ public class FireAlarmDayStatisticsController extends BaseController {
FireAlarmDayStatisticsServiceImpl
fireAlarmDayStatisticsServiceImpl
;
FireAlarmDayStatisticsServiceImpl
fireAlarmDayStatisticsServiceImpl
;
/**
/**
* 新增换流站告警日统计
*
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@PostMapping
(
value
=
"/save"
)
@ApiOperation
(
httpMethod
=
"POST"
,
value
=
"新增换流站告警日统计"
,
notes
=
"新增换流站告警日统计"
)
public
ResponseModel
<
FireAlarmDayStatisticsDto
>
save
(
@RequestBody
FireAlarmDayStatisticsDto
model
)
{
model
=
fireAlarmDayStatisticsServiceImpl
.
createWithModel
(
model
);
return
ResponseHelper
.
buildResponse
(
model
);
}
/**
* 根据sequenceNbr更新
*
* @param sequenceNbr 主键
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@PutMapping
(
value
=
"/{sequenceNbr}"
)
@ApiOperation
(
httpMethod
=
"PUT"
,
value
=
"根据sequenceNbr更新换流站告警日统计"
,
notes
=
"根据sequenceNbr更新换流站告警日统计"
)
public
ResponseModel
<
FireAlarmDayStatisticsDto
>
updateBySequenceNbrFireAlarmDayStatistics
(
@RequestBody
FireAlarmDayStatisticsDto
model
,
@PathVariable
(
value
=
"sequenceNbr"
)
String
sequenceNbr
)
{
model
.
setId
(
sequenceNbr
);
return
ResponseHelper
.
buildResponse
(
fireAlarmDayStatisticsServiceImpl
.
updateWithModel
(
model
));
}
/**
* 根据sequenceNbr删除
*
* @param sequenceNbr 主键
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@DeleteMapping
(
value
=
"/{sequenceNbr}"
)
@ApiOperation
(
httpMethod
=
"DELETE"
,
value
=
"根据sequenceNbr删除换流站告警日统计"
,
notes
=
"根据sequenceNbr删除换流站告警日统计"
)
public
ResponseModel
<
Boolean
>
deleteBySequenceNbr
(
HttpServletRequest
request
,
@PathVariable
(
value
=
"sequenceNbr"
)
Long
sequenceNbr
)
{
return
ResponseHelper
.
buildResponse
(
fireAlarmDayStatisticsServiceImpl
.
removeById
(
sequenceNbr
));
}
/**
* 根据sequenceNbr查询
*
* @param sequenceNbr 主键
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@GetMapping
(
value
=
"/{sequenceNbr}"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"根据sequenceNbr查询单个换流站告警日统计"
,
notes
=
"根据sequenceNbr查询单个换流站告警日统计"
)
public
ResponseModel
<
FireAlarmDayStatisticsDto
>
selectOne
(
@PathVariable
Long
sequenceNbr
)
{
return
ResponseHelper
.
buildResponse
(
fireAlarmDayStatisticsServiceImpl
.
queryBySeq
(
sequenceNbr
));
}
/**
* 列表分页查询
*
* @param current 当前页
* @param current 每页大小
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@GetMapping
(
value
=
"/page"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"换流站告警日统计分页查询"
,
notes
=
"换流站告警日统计分页查询"
)
public
ResponseModel
<
Page
<
FireAlarmDayStatisticsDto
>>
queryForPage
(
@RequestParam
(
value
=
"current"
)
int
current
,
@RequestParam
(
value
=
"size"
)
int
size
)
{
Page
<
FireAlarmDayStatisticsDto
>
page
=
new
Page
<
FireAlarmDayStatisticsDto
>();
page
.
setCurrent
(
current
);
page
.
setSize
(
size
);
return
ResponseHelper
.
buildResponse
(
fireAlarmDayStatisticsServiceImpl
.
queryForFireAlarmDayStatisticsPage
(
page
));
}
/**
* 列表全部数据查询
* 列表全部数据查询
*
*
* @return
* @return
...
...
amos-boot-module/amos-boot-module-biz/amos-boot-module-ccs-biz/src/main/java/com/yeejoin/amos/boot/module/ccs/biz/controller/FireBuildingController.java
View file @
3eec8871
...
@@ -6,6 +6,7 @@ import com.yeejoin.amos.boot.module.ccs.api.dto.FireBuildingDto;
...
@@ -6,6 +6,7 @@ import com.yeejoin.amos.boot.module.ccs.api.dto.FireBuildingDto;
import
com.yeejoin.amos.boot.module.ccs.biz.service.impl.FireBuildingServiceImpl
;
import
com.yeejoin.amos.boot.module.ccs.biz.service.impl.FireBuildingServiceImpl
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiOperation
;
import
io.swagger.annotations.ApiOperation
;
import
io.swagger.annotations.ApiParam
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.web.bind.annotation.*
;
import
org.springframework.web.bind.annotation.*
;
import
org.typroject.tyboot.core.foundation.enumeration.UserType
;
import
org.typroject.tyboot.core.foundation.enumeration.UserType
;
...
@@ -36,16 +37,24 @@ public class FireBuildingController extends BaseController {
...
@@ -36,16 +37,24 @@ public class FireBuildingController extends BaseController {
* @return
* @return
*/
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@GetMapping
(
value
=
"{stationCode}/page"
)
@GetMapping
(
value
=
"
/
{stationCode}/page"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"消防建筑表分页查询"
,
notes
=
"消防建筑表分页查询"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"消防建筑表分页查询"
,
notes
=
"消防建筑表分页查询"
)
public
ResponseModel
<
Page
<
FireBuildingDto
>>
queryForPage
(
public
ResponseModel
<
Page
<
FireBuildingDto
>>
queryForPage
(
@RequestParam
(
value
=
"name"
,
required
=
false
)
String
name
,
@
ApiParam
(
value
=
"建筑名称"
)
@
RequestParam
(
value
=
"name"
,
required
=
false
)
String
name
,
@RequestParam
(
value
=
"current"
)
int
current
,
@
ApiParam
(
value
=
"当前页"
,
required
=
true
)
@
RequestParam
(
value
=
"current"
)
int
current
,
@RequestParam
(
value
=
"size"
)
int
size
,
@
ApiParam
(
value
=
"页大小"
,
required
=
true
)
@
RequestParam
(
value
=
"size"
)
int
size
,
@PathVariable
String
stationCode
)
{
@
ApiParam
(
value
=
"换流站code"
,
required
=
true
)
@
PathVariable
String
stationCode
)
{
Page
<
FireBuildingDto
>
page
=
new
Page
<
FireBuildingDto
>();
Page
<
FireBuildingDto
>
page
=
new
Page
<
FireBuildingDto
>();
page
.
setCurrent
(
current
);
page
.
setCurrent
(
current
);
page
.
setSize
(
size
);
page
.
setSize
(
size
);
return
ResponseHelper
.
buildResponse
(
fireBuildingServiceImpl
.
queryForFireBuildingPage
(
page
,
name
,
stationCode
));
return
ResponseHelper
.
buildResponse
(
fireBuildingServiceImpl
.
queryForFireBuildingPage
(
page
,
name
,
stationCode
));
}
}
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@GetMapping
(
value
=
"/{stationCode}/tree"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"指定换流站的消防建筑树"
,
notes
=
"指定换流站的消防建筑树"
)
public
ResponseModel
buildingTree
(
@ApiParam
(
value
=
"换流站code"
)
@PathVariable
String
stationCode
)
{
return
ResponseHelper
.
buildResponse
(
fireBuildingServiceImpl
.
buildingTree
(
stationCode
));
}
}
}
amos-boot-module/amos-boot-module-biz/amos-boot-module-ccs-biz/src/main/java/com/yeejoin/amos/boot/module/ccs/biz/controller/FireDangerDayStatisticsController.java
View file @
3eec8871
package
com
.
yeejoin
.
amos
.
boot
.
module
.
ccs
.
biz
.
controller
;
package
com
.
yeejoin
.
amos
.
boot
.
module
.
ccs
.
biz
.
controller
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
com.yeejoin.amos.boot.biz.common.controller.BaseController
;
import
com.yeejoin.amos.boot.biz.common.controller.BaseController
;
import
com.yeejoin.amos.boot.module.ccs.api.dto.FireDangerDayStatisticsDto
;
import
com.yeejoin.amos.boot.module.ccs.api.dto.FireDangerDayStatisticsDto
;
import
com.yeejoin.amos.boot.module.ccs.biz.service.impl.FireDangerDayStatisticsServiceImpl
;
import
com.yeejoin.amos.boot.module.ccs.biz.service.impl.FireDangerDayStatisticsServiceImpl
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiOperation
;
import
io.swagger.annotations.ApiOperation
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.web.bind.annotation.*
;
import
org.springframework.web.bind.annotation.GetMapping
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.RestController
;
import
org.typroject.tyboot.core.foundation.enumeration.UserType
;
import
org.typroject.tyboot.core.foundation.enumeration.UserType
;
import
org.typroject.tyboot.core.restful.doc.TycloudOperation
;
import
org.typroject.tyboot.core.restful.doc.TycloudOperation
;
import
org.typroject.tyboot.core.restful.utils.ResponseHelper
;
import
org.typroject.tyboot.core.restful.utils.ResponseHelper
;
import
org.typroject.tyboot.core.restful.utils.ResponseModel
;
import
org.typroject.tyboot.core.restful.utils.ResponseModel
;
import
javax.servlet.http.HttpServletRequest
;
import
java.util.List
;
import
java.util.List
;
/**
/**
...
@@ -31,63 +31,6 @@ public class FireDangerDayStatisticsController extends BaseController {
...
@@ -31,63 +31,6 @@ public class FireDangerDayStatisticsController extends BaseController {
FireDangerDayStatisticsServiceImpl
fireDangerDayStatisticsServiceImpl
;
FireDangerDayStatisticsServiceImpl
fireDangerDayStatisticsServiceImpl
;
/**
/**
* 新增换流站隐患日统计
*
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@PostMapping
(
value
=
"/save"
)
@ApiOperation
(
httpMethod
=
"POST"
,
value
=
"新增换流站隐患日统计"
,
notes
=
"新增换流站隐患日统计"
)
public
ResponseModel
<
FireDangerDayStatisticsDto
>
save
(
@RequestBody
FireDangerDayStatisticsDto
model
)
{
model
=
fireDangerDayStatisticsServiceImpl
.
createWithModel
(
model
);
return
ResponseHelper
.
buildResponse
(
model
);
}
/**
* 根据sequenceNbr删除
*
* @param sequenceNbr 主键
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@DeleteMapping
(
value
=
"/{sequenceNbr}"
)
@ApiOperation
(
httpMethod
=
"DELETE"
,
value
=
"根据sequenceNbr删除换流站隐患日统计"
,
notes
=
"根据sequenceNbr删除换流站隐患日统计"
)
public
ResponseModel
<
Boolean
>
deleteBySequenceNbr
(
HttpServletRequest
request
,
@PathVariable
(
value
=
"sequenceNbr"
)
Long
sequenceNbr
)
{
return
ResponseHelper
.
buildResponse
(
fireDangerDayStatisticsServiceImpl
.
removeById
(
sequenceNbr
));
}
/**
* 根据sequenceNbr查询
*
* @param sequenceNbr 主键
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@GetMapping
(
value
=
"/{sequenceNbr}"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"根据sequenceNbr查询单个换流站隐患日统计"
,
notes
=
"根据sequenceNbr查询单个换流站隐患日统计"
)
public
ResponseModel
<
FireDangerDayStatisticsDto
>
selectOne
(
@PathVariable
Long
sequenceNbr
)
{
return
ResponseHelper
.
buildResponse
(
fireDangerDayStatisticsServiceImpl
.
queryBySeq
(
sequenceNbr
));
}
/**
* 列表分页查询
*
* @param current 当前页
* @param current 每页大小
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@GetMapping
(
value
=
"/page"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"换流站隐患日统计分页查询"
,
notes
=
"换流站隐患日统计分页查询"
)
public
ResponseModel
<
Page
<
FireDangerDayStatisticsDto
>>
queryForPage
(
@RequestParam
(
value
=
"current"
)
int
current
,
@RequestParam
(
value
=
"size"
)
int
size
)
{
Page
<
FireDangerDayStatisticsDto
>
page
=
new
Page
<
FireDangerDayStatisticsDto
>();
page
.
setCurrent
(
current
);
page
.
setSize
(
size
);
return
ResponseHelper
.
buildResponse
(
fireDangerDayStatisticsServiceImpl
.
queryForFireDangerDayStatisticsPage
(
page
));
}
/**
* 列表全部数据查询
* 列表全部数据查询
*
*
* @return
* @return
...
...
amos-boot-module/amos-boot-module-biz/amos-boot-module-ccs-biz/src/main/java/com/yeejoin/amos/boot/module/ccs/biz/controller/FireLatentDangerController.java
View file @
3eec8871
...
@@ -45,4 +45,17 @@ public class FireLatentDangerController extends BaseController {
...
@@ -45,4 +45,17 @@ public class FireLatentDangerController extends BaseController {
@ApiParam
(
value
=
"换流站编号"
)
@RequestParam
(
required
=
false
)
String
stationCode
)
{
@ApiParam
(
value
=
"换流站编号"
)
@RequestParam
(
required
=
false
)
String
stationCode
)
{
return
ResponseHelper
.
buildResponse
(
fireLatentDangerServiceImpl
.
queryForFireLatentDangerList
(
top
,
stationCode
));
return
ResponseHelper
.
buildResponse
(
fireLatentDangerServiceImpl
.
queryForFireLatentDangerList
(
top
,
stationCode
));
}
}
/**
* 隐患分组列表
*
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"隐患分组"
,
notes
=
"隐患分组"
)
@GetMapping
(
value
=
"/state/group"
)
public
ResponseModel
dangerStateGroupMap
(
@ApiParam
(
value
=
"换流站编号"
)
@RequestParam
(
required
=
false
)
String
stationCode
)
{
return
ResponseHelper
.
buildResponse
(
fireLatentDangerServiceImpl
.
dangerStateGroupMap
(
stationCode
));
}
}
}
amos-boot-module/amos-boot-module-biz/amos-boot-module-ccs-biz/src/main/java/com/yeejoin/amos/boot/module/ccs/biz/controller/FireVehicleController.java
View file @
3eec8871
...
@@ -6,6 +6,7 @@ import com.yeejoin.amos.boot.module.ccs.api.dto.FireVehicleDto;
...
@@ -6,6 +6,7 @@ import com.yeejoin.amos.boot.module.ccs.api.dto.FireVehicleDto;
import
com.yeejoin.amos.boot.module.ccs.biz.service.impl.FireVehicleServiceImpl
;
import
com.yeejoin.amos.boot.module.ccs.biz.service.impl.FireVehicleServiceImpl
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiOperation
;
import
io.swagger.annotations.ApiOperation
;
import
io.swagger.annotations.ApiParam
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.web.bind.annotation.*
;
import
org.springframework.web.bind.annotation.*
;
import
org.typroject.tyboot.core.foundation.enumeration.UserType
;
import
org.typroject.tyboot.core.foundation.enumeration.UserType
;
...
@@ -35,13 +36,13 @@ public class FireVehicleController extends BaseController {
...
@@ -35,13 +36,13 @@ public class FireVehicleController extends BaseController {
* @return
* @return
*/
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@GetMapping
(
value
=
"{stationCode}/page"
)
@GetMapping
(
value
=
"
/
{stationCode}/page"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"消防车辆信息分页查询"
,
notes
=
"消防车辆信息分页查询"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"消防车辆信息分页查询"
,
notes
=
"消防车辆信息分页查询"
)
public
ResponseModel
<
Page
<
FireVehicleDto
>>
queryForPage
(
public
ResponseModel
<
Page
<
FireVehicleDto
>>
queryForPage
(
@RequestParam
(
value
=
"name"
,
required
=
false
)
String
name
,
@
ApiParam
(
value
=
"建筑名称"
)
@
RequestParam
(
value
=
"name"
,
required
=
false
)
String
name
,
@RequestParam
(
value
=
"current"
)
int
current
,
@
ApiParam
(
value
=
"当前页"
,
required
=
true
)
@
RequestParam
(
value
=
"current"
)
int
current
,
@RequestParam
(
value
=
"size"
)
int
size
,
@
ApiParam
(
value
=
"页大小"
,
required
=
true
)
@
RequestParam
(
value
=
"size"
)
int
size
,
@PathVariable
String
stationCode
)
{
@
ApiParam
(
value
=
"换流站code"
,
required
=
true
)
@
PathVariable
String
stationCode
)
{
Page
<
FireVehicleDto
>
page
=
new
Page
<
FireVehicleDto
>();
Page
<
FireVehicleDto
>
page
=
new
Page
<
FireVehicleDto
>();
page
.
setCurrent
(
current
);
page
.
setCurrent
(
current
);
page
.
setSize
(
size
);
page
.
setSize
(
size
);
...
...
amos-boot-module/amos-boot-module-biz/amos-boot-module-ccs-biz/src/main/java/com/yeejoin/amos/boot/module/ccs/biz/controller/FireVideoController.java
View file @
3eec8871
...
@@ -6,6 +6,8 @@ import com.yeejoin.amos.boot.module.ccs.api.dto.FireVideoDto;
...
@@ -6,6 +6,8 @@ import com.yeejoin.amos.boot.module.ccs.api.dto.FireVideoDto;
import
com.yeejoin.amos.boot.module.ccs.biz.service.impl.FireVideoServiceImpl
;
import
com.yeejoin.amos.boot.module.ccs.biz.service.impl.FireVideoServiceImpl
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiOperation
;
import
io.swagger.annotations.ApiOperation
;
import
io.swagger.annotations.ApiParam
;
import
org.apache.commons.lang3.StringUtils
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.web.bind.annotation.*
;
import
org.springframework.web.bind.annotation.*
;
import
org.typroject.tyboot.core.foundation.enumeration.UserType
;
import
org.typroject.tyboot.core.foundation.enumeration.UserType
;
...
@@ -13,6 +15,11 @@ import org.typroject.tyboot.core.restful.doc.TycloudOperation;
...
@@ -13,6 +15,11 @@ import org.typroject.tyboot.core.restful.doc.TycloudOperation;
import
org.typroject.tyboot.core.restful.utils.ResponseHelper
;
import
org.typroject.tyboot.core.restful.utils.ResponseHelper
;
import
org.typroject.tyboot.core.restful.utils.ResponseModel
;
import
org.typroject.tyboot.core.restful.utils.ResponseModel
;
import
java.util.ArrayList
;
import
java.util.Arrays
;
import
java.util.List
;
import
java.util.stream.Collectors
;
/**
/**
* 消防视频表
* 消防视频表
*
*
...
@@ -36,17 +43,22 @@ public class FireVideoController extends BaseController {
...
@@ -36,17 +43,22 @@ public class FireVideoController extends BaseController {
* @return
* @return
*/
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@GetMapping
(
value
=
"{stationCode}/page"
)
@GetMapping
(
value
=
"
/
{stationCode}/page"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"消防视频表分页查询"
,
notes
=
"消防视频表分页查询"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"消防视频表分页查询"
,
notes
=
"消防视频表分页查询"
)
public
ResponseModel
<
Page
<
FireVideoDto
>>
queryForPage
(
public
ResponseModel
<
Page
<
FireVideoDto
>>
queryForPage
(
@RequestParam
(
value
=
"name"
,
required
=
false
)
String
name
,
@ApiParam
(
value
=
"建筑名称"
)
@RequestParam
(
value
=
"name"
,
required
=
false
)
String
name
,
@RequestParam
(
value
=
"current"
)
int
current
,
@ApiParam
(
value
=
"当前页"
,
required
=
true
)
@RequestParam
(
value
=
"current"
)
int
current
,
@RequestParam
(
value
=
"size"
)
int
size
,
@ApiParam
(
value
=
"页大小"
,
required
=
true
)
@RequestParam
(
value
=
"size"
)
int
size
,
@PathVariable
String
stationCode
)
{
@ApiParam
(
value
=
"换流站code"
,
required
=
true
)
@PathVariable
String
stationCode
,
@ApiParam
(
value
=
"所在建筑,多个用逗号分隔"
)
@RequestParam
(
value
=
"buildingMrids"
,
required
=
false
)
String
buildingMrids
)
{
List
<
String
>
buildingMridList
=
new
ArrayList
<>();
if
(
StringUtils
.
isNotBlank
(
buildingMrids
)){
buildingMridList
=
Arrays
.
stream
(
buildingMrids
.
split
(
","
)).
collect
(
Collectors
.
toList
());
}
Page
<
FireVideoDto
>
page
=
new
Page
<>();
Page
<
FireVideoDto
>
page
=
new
Page
<>();
page
.
setCurrent
(
current
);
page
.
setCurrent
(
current
);
page
.
setSize
(
size
);
page
.
setSize
(
size
);
return
ResponseHelper
.
buildResponse
(
fireVideoServiceImpl
.
queryForFireVideoPage
(
page
,
name
,
stationCode
));
return
ResponseHelper
.
buildResponse
(
fireVideoServiceImpl
.
queryForFireVideoPage
(
page
,
name
,
stationCode
,
buildingMridList
));
}
}
}
}
amos-boot-module/amos-boot-module-biz/amos-boot-module-ccs-biz/src/main/java/com/yeejoin/amos/boot/module/ccs/biz/controller/FireWaterController.java
View file @
3eec8871
...
@@ -6,6 +6,7 @@ import com.yeejoin.amos.boot.module.ccs.api.dto.FireWaterDto;
...
@@ -6,6 +6,7 @@ import com.yeejoin.amos.boot.module.ccs.api.dto.FireWaterDto;
import
com.yeejoin.amos.boot.module.ccs.biz.service.impl.FireWaterServiceImpl
;
import
com.yeejoin.amos.boot.module.ccs.biz.service.impl.FireWaterServiceImpl
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiOperation
;
import
io.swagger.annotations.ApiOperation
;
import
io.swagger.annotations.ApiParam
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.web.bind.annotation.*
;
import
org.springframework.web.bind.annotation.*
;
import
org.typroject.tyboot.core.foundation.enumeration.UserType
;
import
org.typroject.tyboot.core.foundation.enumeration.UserType
;
...
@@ -13,8 +14,6 @@ import org.typroject.tyboot.core.restful.doc.TycloudOperation;
...
@@ -13,8 +14,6 @@ import org.typroject.tyboot.core.restful.doc.TycloudOperation;
import
org.typroject.tyboot.core.restful.utils.ResponseHelper
;
import
org.typroject.tyboot.core.restful.utils.ResponseHelper
;
import
org.typroject.tyboot.core.restful.utils.ResponseModel
;
import
org.typroject.tyboot.core.restful.utils.ResponseModel
;
import
java.util.List
;
/**
/**
* 消防水源表
* 消防水源表
*
*
...
@@ -37,28 +36,16 @@ public class FireWaterController extends BaseController {
...
@@ -37,28 +36,16 @@ public class FireWaterController extends BaseController {
* @return
* @return
*/
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@GetMapping
(
value
=
"{stationCode}/page"
)
@GetMapping
(
value
=
"
/
{stationCode}/page"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"消防水源表分页查询"
,
notes
=
"消防水源表分页查询"
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"消防水源表分页查询"
,
notes
=
"消防水源表分页查询"
)
public
ResponseModel
<
Page
<
FireWaterDto
>>
queryForPage
(
public
ResponseModel
<
Page
<
FireWaterDto
>>
queryForPage
(
@RequestParam
(
value
=
"name"
,
required
=
false
)
String
name
,
@
ApiParam
(
value
=
"建筑名称"
)
@
RequestParam
(
value
=
"name"
,
required
=
false
)
String
name
,
@RequestParam
(
value
=
"current"
)
int
current
,
@
ApiParam
(
value
=
"当前页"
,
required
=
true
)
@
RequestParam
(
value
=
"current"
)
int
current
,
@RequestParam
(
value
=
"size"
)
int
size
,
@
ApiParam
(
value
=
"页大小"
,
required
=
true
)
@
RequestParam
(
value
=
"size"
)
int
size
,
@PathVariable
String
stationCode
)
{
@
ApiParam
(
value
=
"换流站code"
,
required
=
true
)
@
PathVariable
String
stationCode
)
{
Page
<
FireWaterDto
>
page
=
new
Page
<
FireWaterDto
>();
Page
<
FireWaterDto
>
page
=
new
Page
<
FireWaterDto
>();
page
.
setCurrent
(
current
);
page
.
setCurrent
(
current
);
page
.
setSize
(
size
);
page
.
setSize
(
size
);
return
ResponseHelper
.
buildResponse
(
fireWaterServiceImpl
.
queryForFireWaterPage
(
page
,
name
,
stationCode
));
return
ResponseHelper
.
buildResponse
(
fireWaterServiceImpl
.
queryForFireWaterPage
(
page
,
name
,
stationCode
));
}
}
/**
* 列表全部数据查询
*
* @return
*/
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"消防水源表列表全部数据查询"
,
notes
=
"消防水源表列表全部数据查询"
)
@GetMapping
(
value
=
"/list"
)
public
ResponseModel
<
List
<
FireWaterDto
>>
selectForList
()
{
return
ResponseHelper
.
buildResponse
(
fireWaterServiceImpl
.
queryForFireWaterList
());
}
}
}
amos-boot-module/amos-boot-module-biz/amos-boot-module-ccs-biz/src/main/java/com/yeejoin/amos/boot/module/ccs/biz/controller/StatisticsController.java
0 → 100644
View file @
3eec8871
package
com
.
yeejoin
.
amos
.
boot
.
module
.
ccs
.
biz
.
controller
;
import
com.yeejoin.amos.boot.module.ccs.api.service.IStatisticsService
;
import
io.swagger.annotations.Api
;
import
io.swagger.annotations.ApiOperation
;
import
io.swagger.annotations.ApiParam
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.web.bind.annotation.GetMapping
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.RequestParam
;
import
org.springframework.web.bind.annotation.RestController
;
import
org.typroject.tyboot.core.foundation.enumeration.UserType
;
import
org.typroject.tyboot.core.restful.doc.TycloudOperation
;
import
org.typroject.tyboot.core.restful.utils.ResponseHelper
;
import
org.typroject.tyboot.core.restful.utils.ResponseModel
;
import
java.text.ParseException
;
/**
* @author DELL
*/
@RestController
@Api
(
tags
=
"融合统计"
)
@RequestMapping
(
value
=
"/statistics"
)
public
class
StatisticsController
{
@Autowired
IStatisticsService
iStatisticsService
;
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"告警隐患"
,
notes
=
"告警隐患"
)
@GetMapping
(
value
=
"/alarmAndDangerNumCount"
)
public
ResponseModel
alarmAndDangerNumCount
(
@ApiParam
(
value
=
"换流站编号"
)
@RequestParam
(
required
=
false
)
String
stationCode
)
throws
ParseException
{
return
ResponseHelper
.
buildResponse
(
iStatisticsService
.
alarmAndDangerNumCount
(
stationCode
));
}
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"查询指定区间的告警隐患趋势"
,
notes
=
"查询指定区间的告警隐患趋势"
)
@GetMapping
(
value
=
"/alarmAndDangerTrend"
)
public
ResponseModel
alarmAndDangerTrend
(
@ApiParam
(
value
=
"开始日期"
,
required
=
true
)
@RequestParam
(
value
=
"beginDate"
)
String
beginDate
,
@ApiParam
(
value
=
"结束日期"
,
required
=
true
)
@RequestParam
(
value
=
"endDate"
)
String
endDate
,
@ApiParam
(
value
=
"换流站编号"
)
@RequestParam
(
required
=
false
)
String
stationCode
)
{
return
ResponseHelper
.
buildResponse
(
iStatisticsService
.
alarmAndDangerTrend
(
stationCode
,
beginDate
,
endDate
));
}
}
amos-boot-module/amos-boot-module-biz/amos-boot-module-ccs-biz/src/main/java/com/yeejoin/amos/boot/module/ccs/biz/service/impl/FireAlarmDayStatisticsServiceImpl.java
View file @
3eec8871
package
com
.
yeejoin
.
amos
.
boot
.
module
.
ccs
.
biz
.
service
.
impl
;
package
com
.
yeejoin
.
amos
.
boot
.
module
.
ccs
.
biz
.
service
.
impl
;
import
com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper
;
import
com.yeejoin.amos.boot.module.ccs.api.dto.FireAlarmDayStatisticsDto
;
import
com.yeejoin.amos.boot.module.ccs.api.entity.FireAlarmDayStatistics
;
import
com.yeejoin.amos.boot.module.ccs.api.entity.FireAlarmDayStatistics
;
import
com.yeejoin.amos.boot.module.ccs.api.mapper.FireAlarmDayStatisticsMapper
;
import
com.yeejoin.amos.boot.module.ccs.api.mapper.FireAlarmDayStatisticsMapper
;
import
com.yeejoin.amos.boot.module.ccs.api.service.IFireAlarmDayStatisticsService
;
import
com.yeejoin.amos.boot.module.ccs.api.service.IFireAlarmDayStatisticsService
;
import
com.yeejoin.amos.boot.module.ccs.api.dto.FireAlarmDayStatisticsDto
;
import
org.apache.commons.lang3.StringUtils
;
import
org.typroject.tyboot.core.rdbms.service.BaseService
;
import
org.springframework.stereotype.Service
;
import
org.springframework.stereotype.Service
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
org.typroject.tyboot.core.rdbms.service.BaseService
;
import
java.util.List
;
import
java.util.List
;
/**
/**
...
@@ -16,18 +18,25 @@ import java.util.List;
...
@@ -16,18 +18,25 @@ import java.util.List;
* @date 2021-11-09
* @date 2021-11-09
*/
*/
@Service
@Service
public
class
FireAlarmDayStatisticsServiceImpl
extends
BaseService
<
FireAlarmDayStatisticsDto
,
FireAlarmDayStatistics
,
FireAlarmDayStatisticsMapper
>
implements
IFireAlarmDayStatisticsService
{
public
class
FireAlarmDayStatisticsServiceImpl
extends
BaseService
<
FireAlarmDayStatisticsDto
,
FireAlarmDayStatistics
,
FireAlarmDayStatisticsMapper
>
implements
IFireAlarmDayStatisticsService
{
/**
* 分页查询
*/
public
Page
<
FireAlarmDayStatisticsDto
>
queryForFireAlarmDayStatisticsPage
(
Page
<
FireAlarmDayStatisticsDto
>
page
)
{
return
this
.
queryForPage
(
page
,
null
,
false
);
}
/**
/**
* 列表查询 示例
* 列表查询 示例
*/
*/
public
List
<
FireAlarmDayStatisticsDto
>
queryForFireAlarmDayStatisticsList
()
{
public
List
<
FireAlarmDayStatisticsDto
>
queryForFireAlarmDayStatisticsList
()
{
return
this
.
queryForList
(
""
,
false
);
return
this
.
queryForList
(
""
,
false
);
}
public
int
alarmTimesCount
(
String
stationCode
,
String
beginDate
,
String
endDate
)
{
LambdaQueryWrapper
<
FireAlarmDayStatistics
>
wrapper
=
new
LambdaQueryWrapper
<>();
wrapper
.
eq
(
StringUtils
.
isNotBlank
(
stationCode
),
FireAlarmDayStatistics:
:
getStationCode
,
stationCode
);
wrapper
.
ge
(
FireAlarmDayStatistics:
:
getCollectDate
,
beginDate
);
wrapper
.
le
(
FireAlarmDayStatistics:
:
getCollectDate
,
endDate
);
List
<
FireAlarmDayStatistics
>
list
=
this
.
list
(
wrapper
);
return
list
.
stream
().
mapToInt
(
FireAlarmDayStatistics:
:
getAlarmTimes
).
sum
();
}
public
List
<
String
>
alarmTimesTrend
(
String
stationCode
,
String
beginDate
,
String
endDate
)
{
return
this
.
baseMapper
.
queryAlarmTimesTrend
(
stationCode
,
beginDate
,
endDate
);
}
}
}
}
\ No newline at end of file
amos-boot-module/amos-boot-module-biz/amos-boot-module-ccs-biz/src/main/java/com/yeejoin/amos/boot/module/ccs/biz/service/impl/FireBuildingServiceImpl.java
View file @
3eec8871
package
com
.
yeejoin
.
amos
.
boot
.
module
.
ccs
.
biz
.
service
.
impl
;
package
com
.
yeejoin
.
amos
.
boot
.
module
.
ccs
.
biz
.
service
.
impl
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
com.yeejoin.amos.boot.module.ccs.api.dto.BaseDto
;
import
com.yeejoin.amos.boot.module.ccs.api.dto.FireBuildingDto
;
import
com.yeejoin.amos.boot.module.ccs.api.dto.FireBuildingDto
;
import
com.yeejoin.amos.boot.module.ccs.api.entity.FireBuilding
;
import
com.yeejoin.amos.boot.module.ccs.api.entity.FireBuilding
;
import
com.yeejoin.amos.boot.module.ccs.api.mapper.FireBuildingMapper
;
import
com.yeejoin.amos.boot.module.ccs.api.mapper.FireBuildingMapper
;
import
com.yeejoin.amos.boot.module.ccs.api.service.IFireBuildingService
;
import
com.yeejoin.amos.boot.module.ccs.api.service.IFireBuildingService
;
import
org.apache.commons.lang3.StringUtils
;
import
org.springframework.stereotype.Service
;
import
org.springframework.stereotype.Service
;
import
org.typroject.tyboot.core.rdbms.annotation.Condition
;
import
org.typroject.tyboot.core.rdbms.annotation.Condition
;
import
org.typroject.tyboot.core.rdbms.annotation.Operator
;
import
org.typroject.tyboot.core.rdbms.annotation.Operator
;
import
org.typroject.tyboot.core.rdbms.service.BaseService
;
import
org.typroject.tyboot.core.rdbms.service.BaseService
;
import
java.util.Comparator
;
import
java.util.List
;
import
java.util.List
;
import
java.util.stream.Collectors
;
/**
/**
* 消防建筑表服务实现类
* 消防建筑表服务实现类
...
@@ -23,15 +27,17 @@ public class FireBuildingServiceImpl extends BaseService<FireBuildingDto, FireBu
...
@@ -23,15 +27,17 @@ public class FireBuildingServiceImpl extends BaseService<FireBuildingDto, FireBu
/**
/**
* 分页查询
* 分页查询
*/
*/
public
Page
<
FireBuildingDto
>
queryForFireBuildingPage
(
Page
<
FireBuildingDto
>
page
,
@Condition
(
Operator
.
like
)
String
name
,
@Condition
String
stationCode
)
{
public
Page
<
FireBuildingDto
>
queryForFireBuildingPage
(
Page
<
FireBuildingDto
>
page
,
@Condition
(
Operator
.
like
)
String
name
,
@Condition
String
stationCode
)
{
return
this
.
queryForPage
(
page
,
"create
D
ate"
,
false
,
name
,
stationCode
);
return
this
.
queryForPage
(
page
,
"create
_d
ate"
,
false
,
name
,
stationCode
);
}
}
/**
public
List
<
FireBuildingDto
>
buildingTree
(
String
stationCode
)
{
* 列表查询 示例
List
<
FireBuildingDto
>
dtoList
=
this
.
queryForList
(
"create_date"
,
true
,
stationCode
);
*/
return
dtoList
.
stream
().
filter
(
d
->
StringUtils
.
isBlank
(
d
.
getParentMrid
())
||
"0"
.
equals
(
d
.
getParentMrid
())
||
"-1"
.
equals
(
d
.
getParentMrid
())).
peek
(
s
->
s
.
setChildren
(
this
.
getChildren
(
s
.
getMrid
(),
dtoList
))).
sorted
(
Comparator
.
comparing
(
BaseDto:
:
getCreateDate
)).
collect
(
Collectors
.
toList
());
public
List
<
FireBuildingDto
>
queryForFireBuildingList
()
{
}
return
this
.
queryForList
(
""
,
false
);
private
List
<
FireBuildingDto
>
getChildren
(
String
mrid
,
List
<
FireBuildingDto
>
dtoList
)
{
return
dtoList
.
stream
().
filter
(
d
->
StringUtils
.
isNotBlank
(
d
.
getParentMrid
())
&&
d
.
getParentMrid
().
equals
(
mrid
)).
peek
(
s
->
s
.
setChildren
(
this
.
getChildren
(
s
.
getMrid
(),
dtoList
))).
sorted
(
Comparator
.
comparing
(
BaseDto:
:
getCreateDate
)).
collect
(
Collectors
.
toList
());
}
}
}
}
\ No newline at end of file
amos-boot-module/amos-boot-module-biz/amos-boot-module-ccs-biz/src/main/java/com/yeejoin/amos/boot/module/ccs/biz/service/impl/FireDangerDayStatisticsServiceImpl.java
View file @
3eec8871
package
com
.
yeejoin
.
amos
.
boot
.
module
.
ccs
.
biz
.
service
.
impl
;
package
com
.
yeejoin
.
amos
.
boot
.
module
.
ccs
.
biz
.
service
.
impl
;
import
com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper
;
import
com.yeejoin.amos.boot.module.ccs.api.dto.FireDangerDayStatisticsDto
;
import
com.yeejoin.amos.boot.module.ccs.api.entity.FireDangerDayStatistics
;
import
com.yeejoin.amos.boot.module.ccs.api.entity.FireDangerDayStatistics
;
import
com.yeejoin.amos.boot.module.ccs.api.mapper.FireDangerDayStatisticsMapper
;
import
com.yeejoin.amos.boot.module.ccs.api.mapper.FireDangerDayStatisticsMapper
;
import
com.yeejoin.amos.boot.module.ccs.api.service.IFireDangerDayStatisticsService
;
import
com.yeejoin.amos.boot.module.ccs.api.service.IFireDangerDayStatisticsService
;
import
com.yeejoin.amos.boot.module.ccs.api.dto.FireDangerDayStatisticsDto
;
import
org.apache.commons.lang3.StringUtils
;
import
org.typroject.tyboot.core.rdbms.service.BaseService
;
import
org.springframework.stereotype.Service
;
import
org.springframework.stereotype.Service
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
org.typroject.tyboot.core.rdbms.service.BaseService
;
import
java.util.List
;
import
java.util.List
;
/**
/**
...
@@ -16,18 +18,25 @@ import java.util.List;
...
@@ -16,18 +18,25 @@ import java.util.List;
* @date 2021-11-09
* @date 2021-11-09
*/
*/
@Service
@Service
public
class
FireDangerDayStatisticsServiceImpl
extends
BaseService
<
FireDangerDayStatisticsDto
,
FireDangerDayStatistics
,
FireDangerDayStatisticsMapper
>
implements
IFireDangerDayStatisticsService
{
public
class
FireDangerDayStatisticsServiceImpl
extends
BaseService
<
FireDangerDayStatisticsDto
,
FireDangerDayStatistics
,
FireDangerDayStatisticsMapper
>
implements
IFireDangerDayStatisticsService
{
/**
* 分页查询
*/
public
Page
<
FireDangerDayStatisticsDto
>
queryForFireDangerDayStatisticsPage
(
Page
<
FireDangerDayStatisticsDto
>
page
)
{
return
this
.
queryForPage
(
page
,
null
,
false
);
}
/**
/**
* 列表查询 示例
* 列表查询 示例
*/
*/
public
List
<
FireDangerDayStatisticsDto
>
queryForFireDangerDayStatisticsList
()
{
public
List
<
FireDangerDayStatisticsDto
>
queryForFireDangerDayStatisticsList
()
{
return
this
.
queryForList
(
""
,
false
);
return
this
.
queryForList
(
""
,
false
);
}
public
int
createDangerTimesCount
(
String
stationCode
,
String
beginDate
,
String
endDate
)
{
LambdaQueryWrapper
<
FireDangerDayStatistics
>
wrapper
=
new
LambdaQueryWrapper
<>();
wrapper
.
eq
(
StringUtils
.
isNotBlank
(
stationCode
),
FireDangerDayStatistics:
:
getStationCode
,
stationCode
);
wrapper
.
ge
(
FireDangerDayStatistics:
:
getCollectDate
,
beginDate
);
wrapper
.
le
(
FireDangerDayStatistics:
:
getCollectDate
,
endDate
);
List
<
FireDangerDayStatistics
>
list
=
this
.
list
(
wrapper
);
return
list
.
stream
().
mapToInt
(
FireDangerDayStatistics:
:
getDangerTimes
).
sum
();
}
public
List
<
String
>
dangerTimesTrend
(
String
stationCode
,
String
beginDate
,
String
endDate
)
{
return
this
.
baseMapper
.
queryDangerTimesTrend
(
stationCode
,
beginDate
,
endDate
);
}
}
}
}
\ No newline at end of file
amos-boot-module/amos-boot-module-biz/amos-boot-module-ccs-biz/src/main/java/com/yeejoin/amos/boot/module/ccs/biz/service/impl/FireLatentDangerServiceImpl.java
View file @
3eec8871
package
com
.
yeejoin
.
amos
.
boot
.
module
.
ccs
.
biz
.
service
.
impl
;
package
com
.
yeejoin
.
amos
.
boot
.
module
.
ccs
.
biz
.
service
.
impl
;
import
com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
com.yeejoin.amos.boot.module.ccs.api.dto.FireLatentDangerDto
;
import
com.yeejoin.amos.boot.module.ccs.api.dto.BaseDto
;
import
com.yeejoin.amos.boot.module.ccs.api.entity.BaseEntity
;
import
com.yeejoin.amos.boot.module.ccs.api.entity.FireLatentDanger
;
import
com.yeejoin.amos.boot.module.ccs.api.entity.FireLatentDanger
;
import
com.yeejoin.amos.boot.module.ccs.api.mapper.FireLatentDangerMapper
;
import
com.yeejoin.amos.boot.module.ccs.api.mapper.FireLatentDangerMapper
;
import
com.yeejoin.amos.boot.module.ccs.api.service.IFireLatentDangerService
;
import
com.yeejoin.amos.boot.module.ccs.api.service.IFireLatentDangerService
;
import
com.yeejoin.amos.boot.module.ccs.api.dto.FireLatentDangerDto
;
import
org.typroject.tyboot.core.foundation.utils.Bean
;
import
org.typroject.tyboot.core.rdbms.service.BaseService
;
import
org.springframework.stereotype.Service
;
import
org.springframework.stereotype.Service
;
import
com.baomidou.mybatisplus.extension.plugins.pagination.Page
;
import
org.typroject.tyboot.core.rdbms.service.BaseService
;
import
java.util.LinkedHashMap
;
import
java.util.List
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.stream.Collectors
;
import
java.util.stream.Collectors
;
/**
/**
...
@@ -22,20 +20,30 @@ import java.util.stream.Collectors;
...
@@ -22,20 +20,30 @@ import java.util.stream.Collectors;
* @date 2021-11-09
* @date 2021-11-09
*/
*/
@Service
@Service
public
class
FireLatentDangerServiceImpl
extends
BaseService
<
FireLatentDangerDto
,
FireLatentDanger
,
FireLatentDangerMapper
>
implements
IFireLatentDangerService
{
public
class
FireLatentDangerServiceImpl
extends
BaseService
<
FireLatentDangerDto
,
FireLatentDanger
,
FireLatentDangerMapper
>
implements
IFireLatentDangerService
{
/**
/**
* 分页查询
* 分页查询
*/
*/
public
Page
<
FireLatentDangerDto
>
queryForFireLatentDangerPage
(
Page
<
FireLatentDangerDto
>
page
)
{
public
Page
<
FireLatentDangerDto
>
queryForFireLatentDangerPage
(
Page
<
FireLatentDangerDto
>
page
)
{
return
this
.
queryForPage
(
page
,
null
,
false
);
return
this
.
queryForPage
(
page
,
null
,
false
);
}
}
/**
/**
* 列表查询 示例
* 列表查询 示例
* @param top 取值
*
* @param top 取值
* @param stationCode 站code
* @param stationCode 站code
*/
*/
public
List
<
FireLatentDangerDto
>
queryForFireLatentDangerList
(
Long
top
,
String
stationCode
)
{
public
List
<
FireLatentDangerDto
>
queryForFireLatentDangerList
(
Long
top
,
String
stationCode
)
{
return
this
.
getBaseMapper
().
queryDangerList
(
top
,
stationCode
);
return
this
.
baseMapper
.
queryDangerList
(
top
,
stationCode
);
}
public
Map
<
String
,
Object
>
dangerStateGroupMap
(
String
stationCode
)
{
List
<
Map
<
String
,
Object
>>
list
=
this
.
baseMapper
.
dangerStateGroupMap
(
stationCode
);
Map
<
String
,
Object
>
result
=
new
LinkedHashMap
<>();
list
.
forEach
(
m
->
{
result
.
put
(
m
.
get
(
"dangerState"
).
toString
(),
m
.
get
(
"num"
));
});
return
result
;
}
}
}
}
\ No newline at end of file
amos-boot-module/amos-boot-module-biz/amos-boot-module-ccs-biz/src/main/java/com/yeejoin/amos/boot/module/ccs/biz/service/impl/FireVehicleServiceImpl.java
View file @
3eec8871
...
@@ -10,8 +10,6 @@ import org.typroject.tyboot.core.rdbms.annotation.Condition;
...
@@ -10,8 +10,6 @@ import org.typroject.tyboot.core.rdbms.annotation.Condition;
import
org.typroject.tyboot.core.rdbms.annotation.Operator
;
import
org.typroject.tyboot.core.rdbms.annotation.Operator
;
import
org.typroject.tyboot.core.rdbms.service.BaseService
;
import
org.typroject.tyboot.core.rdbms.service.BaseService
;
import
java.util.List
;
/**
/**
* 消防车辆信息服务实现类
* 消防车辆信息服务实现类
*
*
...
@@ -24,13 +22,6 @@ public class FireVehicleServiceImpl extends BaseService<FireVehicleDto, FireVehi
...
@@ -24,13 +22,6 @@ public class FireVehicleServiceImpl extends BaseService<FireVehicleDto, FireVehi
* 分页查询
* 分页查询
*/
*/
public
Page
<
FireVehicleDto
>
queryForFireVehiclePage
(
Page
<
FireVehicleDto
>
page
,
@Condition
(
Operator
.
like
)
String
name
,
String
stationCode
)
{
public
Page
<
FireVehicleDto
>
queryForFireVehiclePage
(
Page
<
FireVehicleDto
>
page
,
@Condition
(
Operator
.
like
)
String
name
,
String
stationCode
)
{
return
this
.
queryForPage
(
page
,
"createDate"
,
false
,
name
,
stationCode
);
return
this
.
queryForPage
(
page
,
"create_date"
,
false
,
name
,
stationCode
);
}
/**
* 列表查询 示例
*/
public
List
<
FireVehicleDto
>
queryForFireVehicleList
()
{
return
this
.
queryForList
(
""
,
false
);
}
}
}
}
\ No newline at end of file
amos-boot-module/amos-boot-module-biz/amos-boot-module-ccs-biz/src/main/java/com/yeejoin/amos/boot/module/ccs/biz/service/impl/FireVideoServiceImpl.java
View file @
3eec8871
...
@@ -23,14 +23,8 @@ public class FireVideoServiceImpl extends BaseService<FireVideoDto, FireVideo, F
...
@@ -23,14 +23,8 @@ public class FireVideoServiceImpl extends BaseService<FireVideoDto, FireVideo, F
/**
/**
* 分页查询
* 分页查询
*/
*/
public
Page
<
FireVideoDto
>
queryForFireVideoPage
(
Page
<
FireVideoDto
>
page
,
@Condition
(
Operator
.
like
)
String
name
,
String
stationCode
)
{
public
Page
<
FireVideoDto
>
queryForFireVideoPage
(
Page
<
FireVideoDto
>
page
,
@Condition
(
Operator
.
like
)
String
name
,
String
stationCode
,
@Condition
(
Operator
.
in
)
List
<
String
>
buildingMrid
)
{
return
this
.
queryForPage
(
page
,
"create
Date"
,
false
,
name
,
stationCode
);
return
this
.
queryForPage
(
page
,
"create
_date"
,
false
,
name
,
stationCode
,
buildingMrid
);
}
}
/**
* 列表查询 示例
*/
public
List
<
FireVideoDto
>
queryForFireVideoList
()
{
return
this
.
queryForList
(
""
,
false
);
}
}
}
\ No newline at end of file
amos-boot-module/amos-boot-module-biz/amos-boot-module-ccs-biz/src/main/java/com/yeejoin/amos/boot/module/ccs/biz/service/impl/FireWaterServiceImpl.java
View file @
3eec8871
...
@@ -24,7 +24,7 @@ public class FireWaterServiceImpl extends BaseService<FireWaterDto, FireWater, F
...
@@ -24,7 +24,7 @@ public class FireWaterServiceImpl extends BaseService<FireWaterDto, FireWater, F
* 分页查询
* 分页查询
*/
*/
public
Page
<
FireWaterDto
>
queryForFireWaterPage
(
Page
<
FireWaterDto
>
page
,
@Condition
(
Operator
.
like
)
String
name
,
String
stationCode
)
{
public
Page
<
FireWaterDto
>
queryForFireWaterPage
(
Page
<
FireWaterDto
>
page
,
@Condition
(
Operator
.
like
)
String
name
,
String
stationCode
)
{
return
this
.
queryForPage
(
page
,
"create
D
ate"
,
false
,
name
,
stationCode
);
return
this
.
queryForPage
(
page
,
"create
_d
ate"
,
false
,
name
,
stationCode
);
}
}
/**
/**
...
...
amos-boot-module/amos-boot-module-biz/amos-boot-module-ccs-biz/src/main/java/com/yeejoin/amos/boot/module/ccs/biz/service/impl/StatisticsServiceImpl.java
0 → 100644
View file @
3eec8871
package
com
.
yeejoin
.
amos
.
boot
.
module
.
ccs
.
biz
.
service
.
impl
;
import
com.yeejoin.amos.boot.biz.common.utils.DateUtils
;
import
com.yeejoin.amos.boot.module.ccs.api.service.IStatisticsService
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
java.text.ParseException
;
import
java.util.Date
;
import
java.util.HashMap
;
import
java.util.List
;
import
java.util.Map
;
/**
* @author DELL
*/
@Service
public
class
StatisticsServiceImpl
implements
IStatisticsService
{
@Autowired
FireAlarmDayStatisticsServiceImpl
fireAlarmDayStatisticsService
;
@Autowired
FireDangerDayStatisticsServiceImpl
fireDangerDayStatisticsService
;
@Override
public
Map
<
String
,
Object
>
alarmAndDangerNumCount
(
String
stationCode
)
throws
ParseException
{
//本周开始日期
Date
weekBegin
=
DateUtils
.
beginDateOfWeek
(
new
Date
());
//今日告警
Integer
todayAddAlarm
=
fireAlarmDayStatisticsService
.
alarmTimesCount
(
stationCode
,
DateUtils
.
dateFormat
(
new
Date
(),
DateUtils
.
DATE_PATTERN
),
DateUtils
.
dateFormat
(
new
Date
(),
DateUtils
.
DATE_PATTERN
));
//本周告警数量
Integer
weekAddAlarm
=
fireAlarmDayStatisticsService
.
alarmTimesCount
(
stationCode
,
DateUtils
.
dateFormat
(
weekBegin
,
DateUtils
.
DATE_PATTERN
),
DateUtils
.
dateFormat
(
new
Date
(),
DateUtils
.
DATE_PATTERN
));
//今日新增隐患
Integer
todayAddDanger
=
fireDangerDayStatisticsService
.
createDangerTimesCount
(
stationCode
,
DateUtils
.
dateFormat
(
new
Date
(),
DateUtils
.
DATE_PATTERN
),
DateUtils
.
dateFormat
(
new
Date
(),
DateUtils
.
DATE_PATTERN
));
//本周新增隐患
Integer
weekAddDanger
=
fireDangerDayStatisticsService
.
createDangerTimesCount
(
stationCode
,
DateUtils
.
dateFormat
(
weekBegin
,
DateUtils
.
DATE_PATTERN
),
DateUtils
.
dateFormat
(
new
Date
(),
DateUtils
.
DATE_PATTERN
));
Map
<
String
,
Object
>
result
=
new
HashMap
<>();
result
.
put
(
"todayAddAlarm"
,
todayAddAlarm
);
result
.
put
(
"weekAddAlarm"
,
weekAddAlarm
);
result
.
put
(
"todayAddDanger"
,
todayAddDanger
);
result
.
put
(
"weekAddDanger"
,
weekAddDanger
);
return
result
;
}
@Override
public
Map
<
String
,
Object
>
alarmAndDangerTrend
(
String
stationCode
,
String
beginDate
,
String
endDate
)
{
//告警增长趋势
List
<
String
>
alarmTrend
=
fireAlarmDayStatisticsService
.
alarmTimesTrend
(
stationCode
,
beginDate
,
endDate
);
//隐患增加趋势
List
<
String
>
dangerTrend
=
fireDangerDayStatisticsService
.
dangerTimesTrend
(
stationCode
,
beginDate
,
endDate
);
Map
<
String
,
Object
>
result
=
new
HashMap
<>();
result
.
put
(
"alarmTrend"
,
alarmTrend
);
result
.
put
(
"dangerTrend"
,
dangerTrend
);
return
result
;
}
}
amos-boot-module/amos-boot-module-biz/amos-boot-module-supervision-biz/src/main/java/com/yeejoin/amos/supervision/business/dto/PlanRo.java
0 → 100644
View file @
3eec8871
package
com
.
yeejoin
.
amos
.
supervision
.
business
.
dto
;
import
com.yeejoin.amos.component.rule.Label
;
import
com.yeejoin.amos.component.rule.RuleFact
;
import
lombok.Data
;
import
java.io.Serializable
;
import
java.util.List
;
/**
* @Author: xl
* @Description: 计划规则触发对象
* @Date: 2021/11/10 10:01
*/
@Data
@RuleFact
(
value
=
"巡检计划"
,
project
=
"消息规则"
)
public
class
PlanRo
implements
Serializable
{
private
static
final
long
serialVersionUID
=
3847767788621939352L
;
@Label
(
"计划名称"
)
private
String
name
;
@Label
(
value
=
"检查类型名称"
)
private
String
checkTypeName
;
@Label
(
value
=
"执行方法"
)
private
String
ruleType
;
@Label
(
value
=
"执行状态"
)
private
String
excuteStateName
;
@Label
(
value
=
"推送时间"
)
private
String
sendTime
;
@Label
(
value
=
"接收人"
)
private
List
<
String
>
recivers
;
@Label
(
value
=
"发送到web标识"
)
private
Boolean
isSendWeb
;
@Label
(
value
=
"发送到app标识"
)
private
Boolean
isSendApp
;
@Label
(
"关联id"
)
private
String
relationId
;
@Label
(
"消息类型"
)
private
String
msgType
;
@Label
(
value
=
"终端标识"
)
private
String
terminal
;
}
amos-boot-module/amos-boot-module-biz/amos-boot-module-supervision-biz/src/main/java/com/yeejoin/amos/supervision/business/service/impl/CheckServiceImpl.java
View file @
3eec8871
package
com
.
yeejoin
.
amos
.
supervision
.
business
.
service
.
impl
;
package
com
.
yeejoin
.
amos
.
supervision
.
business
.
service
.
impl
;
import
com.alibaba.fastjson.JSON
;
import
com.alibaba.fastjson.JSONArray
;
import
com.alibaba.fastjson.JSONArray
;
import
com.alibaba.fastjson.JSONObject
;
import
com.alibaba.fastjson.JSONObject
;
import
com.google.common.base.Joiner
;
import
com.google.common.base.Joiner
;
...
@@ -9,7 +8,6 @@ import com.google.common.collect.Lists;
...
@@ -9,7 +8,6 @@ import com.google.common.collect.Lists;
import
com.google.common.collect.Maps
;
import
com.google.common.collect.Maps
;
import
com.yeejoin.amos.boot.biz.common.bo.DepartmentBo
;
import
com.yeejoin.amos.boot.biz.common.bo.DepartmentBo
;
import
com.yeejoin.amos.boot.biz.common.bo.ReginParams
;
import
com.yeejoin.amos.boot.biz.common.bo.ReginParams
;
import
com.yeejoin.amos.boot.biz.common.utils.DateUtils
;
import
com.yeejoin.amos.component.feign.model.FeignClientResult
;
import
com.yeejoin.amos.component.feign.model.FeignClientResult
;
import
com.yeejoin.amos.feign.privilege.model.AgencyUserModel
;
import
com.yeejoin.amos.feign.privilege.model.AgencyUserModel
;
import
com.yeejoin.amos.feign.privilege.model.CompanyModel
;
import
com.yeejoin.amos.feign.privilege.model.CompanyModel
;
...
@@ -31,7 +29,6 @@ import com.yeejoin.amos.supervision.business.vo.CheckAnalysisVo;
...
@@ -31,7 +29,6 @@ import com.yeejoin.amos.supervision.business.vo.CheckAnalysisVo;
import
com.yeejoin.amos.supervision.business.vo.CheckInfoVo
;
import
com.yeejoin.amos.supervision.business.vo.CheckInfoVo
;
import
com.yeejoin.amos.supervision.business.vo.CheckVo
;
import
com.yeejoin.amos.supervision.business.vo.CheckVo
;
import
com.yeejoin.amos.supervision.common.enums.*
;
import
com.yeejoin.amos.supervision.common.enums.*
;
import
com.yeejoin.amos.supervision.core.async.AsyncTask
;
import
com.yeejoin.amos.supervision.core.common.dto.DangerDto
;
import
com.yeejoin.amos.supervision.core.common.dto.DangerDto
;
import
com.yeejoin.amos.supervision.core.common.request.CommonPageable
;
import
com.yeejoin.amos.supervision.core.common.request.CommonPageable
;
import
com.yeejoin.amos.supervision.core.common.response.*
;
import
com.yeejoin.amos.supervision.core.common.response.*
;
...
@@ -50,13 +47,10 @@ import org.springframework.data.domain.Page;
...
@@ -50,13 +47,10 @@ import org.springframework.data.domain.Page;
import
org.springframework.data.domain.PageImpl
;
import
org.springframework.data.domain.PageImpl
;
import
org.springframework.stereotype.Service
;
import
org.springframework.stereotype.Service
;
import
org.springframework.util.ObjectUtils
;
import
org.springframework.util.ObjectUtils
;
import
org.typroject.tyboot.core.foundation.context.RequestContext
;
import
org.typroject.tyboot.core.foundation.utils.Bean
;
import
org.typroject.tyboot.core.foundation.utils.Bean
;
import
org.typroject.tyboot.core.foundation.utils.ValidationUtil
;
import
javax.annotation.Resource
;
import
javax.annotation.Resource
;
import
javax.transaction.Transactional
;
import
javax.transaction.Transactional
;
import
java.text.ParseException
;
import
java.util.*
;
import
java.util.*
;
import
java.util.stream.Collectors
;
import
java.util.stream.Collectors
;
...
@@ -106,7 +100,7 @@ public class CheckServiceImpl implements ICheckService {
...
@@ -106,7 +100,7 @@ public class CheckServiceImpl implements ICheckService {
private
IPlanService
planService
;
private
IPlanService
planService
;
@Autowired
@Autowired
private
AsyncTask
asyncTask
;
private
RulePlanService
rulePlanService
;
@Autowired
@Autowired
DangerFeignClient
DangerFeignClient
;
DangerFeignClient
DangerFeignClient
;
...
@@ -1578,9 +1572,9 @@ public class CheckServiceImpl implements ICheckService {
...
@@ -1578,9 +1572,9 @@ public class CheckServiceImpl implements ICheckService {
recordParam
.
getPlanTaskId
(),
mtUserSeq
,
userName
,
size
,
planTaskStatus
);
recordParam
.
getPlanTaskId
(),
mtUserSeq
,
userName
,
size
,
planTaskStatus
);
Plan
plan
=
planService
.
queryPlanById
(
planTask
.
getPlanId
());
Plan
plan
=
planService
.
queryPlanById
(
planTask
.
getPlanId
());
// 计划完成,
发
送消息
// 计划完成,
规则推
送消息
if
(
PlanStatusEnum
.
COMPLETED
.
getValue
()
==
plan
.
getStatus
()){
if
(
PlanStatusEnum
.
COMPLETED
.
getValue
()
==
plan
.
getStatus
()){
asyncTask
.
sendPlanMsgToLeadPeople
(
RequestContext
.
cloneRequestContext
(),
plan
);
rulePlanService
.
addPlanRule
(
plan
,
null
,
RuleTypeEnum
.
计划完成
.
getCode
()
);
}
}
// p_plan_task_detail更新隐患个数
// p_plan_task_detail更新隐患个数
...
...
amos-boot-module/amos-boot-module-biz/amos-boot-module-supervision-biz/src/main/java/com/yeejoin/amos/supervision/business/service/impl/PlanAuditServiceImpl.java
View file @
3eec8871
...
@@ -73,7 +73,7 @@ public class PlanAuditServiceImpl implements IPlanAuditService {
...
@@ -73,7 +73,7 @@ public class PlanAuditServiceImpl implements IPlanAuditService {
planAuditLog
.
setFlowJson
(
condition
);
planAuditLog
.
setFlowJson
(
condition
);
planAuditLog
.
setRoleName
(
roleName
);
planAuditLog
.
setRoleName
(
roleName
);
planAuditLogDao
.
save
(
planAuditLog
);
planAuditLogDao
.
save
(
planAuditLog
);
planService
.
getUserIdsByWorkflow
(
plan
,
instanceId
);
planService
.
getUserIdsByWorkflow
(
plan
,
instanceId
,
status
,
planAuditLog
.
getExcuteState
()
);
return
Boolean
.
TRUE
;
return
Boolean
.
TRUE
;
}
}
}
}
...
...
amos-boot-module/amos-boot-module-biz/amos-boot-module-supervision-biz/src/main/java/com/yeejoin/amos/supervision/business/service/impl/PlanServiceImpl.java
View file @
3eec8871
...
@@ -15,10 +15,7 @@ import com.yeejoin.amos.supervision.business.dao.mapper.PointMapper;
...
@@ -15,10 +15,7 @@ import com.yeejoin.amos.supervision.business.dao.mapper.PointMapper;
import
com.yeejoin.amos.supervision.business.dao.repository.*
;
import
com.yeejoin.amos.supervision.business.dao.repository.*
;
import
com.yeejoin.amos.supervision.business.param.PlanInfoPageParam
;
import
com.yeejoin.amos.supervision.business.param.PlanInfoPageParam
;
import
com.yeejoin.amos.supervision.business.service.intfc.IPlanService
;
import
com.yeejoin.amos.supervision.business.service.intfc.IPlanService
;
import
com.yeejoin.amos.supervision.common.enums.CheckTypeSuEnum
;
import
com.yeejoin.amos.supervision.common.enums.*
;
import
com.yeejoin.amos.supervision.common.enums.DangerCheckTypeLevelEnum
;
import
com.yeejoin.amos.supervision.common.enums.PlanStatusEnum
;
import
com.yeejoin.amos.supervision.common.enums.WorkFlowBranchEnum
;
import
com.yeejoin.amos.supervision.core.async.AsyncTask
;
import
com.yeejoin.amos.supervision.core.async.AsyncTask
;
import
com.yeejoin.amos.supervision.core.common.request.AddPlanRequest
;
import
com.yeejoin.amos.supervision.core.common.request.AddPlanRequest
;
import
com.yeejoin.amos.supervision.core.common.response.PlanPointRespone
;
import
com.yeejoin.amos.supervision.core.common.response.PlanPointRespone
;
...
@@ -36,6 +33,7 @@ import org.springframework.stereotype.Service;
...
@@ -36,6 +33,7 @@ import org.springframework.stereotype.Service;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.util.ObjectUtils
;
import
org.springframework.util.ObjectUtils
;
import
org.typroject.tyboot.core.foundation.context.RequestContext
;
import
org.typroject.tyboot.core.foundation.context.RequestContext
;
import
org.typroject.tyboot.core.foundation.utils.ValidationUtil
;
import
java.time.format.DateTimeFormatter
;
import
java.time.format.DateTimeFormatter
;
import
java.time.temporal.TemporalAccessor
;
import
java.time.temporal.TemporalAccessor
;
...
@@ -83,6 +81,9 @@ public class PlanServiceImpl implements IPlanService {
...
@@ -83,6 +81,9 @@ public class PlanServiceImpl implements IPlanService {
private
AsyncTask
asyncTask
;
private
AsyncTask
asyncTask
;
@Autowired
@Autowired
private
RulePlanService
rulePlanService
;
@Autowired
WorkflowFeignService
workflowFeignService
;
WorkflowFeignService
workflowFeignService
;
@Autowired
@Autowired
...
@@ -183,7 +184,7 @@ public class PlanServiceImpl implements IPlanService {
...
@@ -183,7 +184,7 @@ public class PlanServiceImpl implements IPlanService {
//更新时间
//更新时间
audit
.
setUpdateDate
(
new
Date
());
audit
.
setUpdateDate
(
new
Date
());
planAuditDao
.
save
(
audit
);
planAuditDao
.
save
(
audit
);
this
.
getUserIdsByWorkflow
(
plan
,
processInstanceId
);
this
.
getUserIdsByWorkflow
(
plan
,
processInstanceId
,
null
,
null
);
//记录执行流水-启动节点
//记录执行流水-启动节点
insertAuditLog
(
reginParams
,
plan
,
personIdentity
,
audit
);
insertAuditLog
(
reginParams
,
plan
,
personIdentity
,
audit
);
}
else
{
}
else
{
...
@@ -198,7 +199,7 @@ public class PlanServiceImpl implements IPlanService {
...
@@ -198,7 +199,7 @@ public class PlanServiceImpl implements IPlanService {
planAuditDao
.
save
(
audit
);
planAuditDao
.
save
(
audit
);
//记录执行流水-启动节点
//记录执行流水-启动节点
insertAuditLog
(
reginParams
,
plan
,
personIdentity
,
audit
);
insertAuditLog
(
reginParams
,
plan
,
personIdentity
,
audit
);
this
.
getUserIdsByWorkflow
(
plan
,
processInstanceId
);
this
.
getUserIdsByWorkflow
(
plan
,
processInstanceId
,
null
,
null
);
}
}
}
catch
(
Exception
e
)
{
}
catch
(
Exception
e
)
{
log
.
error
(
"=============防火监督,计划提交,工作流启动失败!!!============="
);
log
.
error
(
"=============防火监督,计划提交,工作流启动失败!!!============="
);
...
@@ -208,10 +209,10 @@ public class PlanServiceImpl implements IPlanService {
...
@@ -208,10 +209,10 @@ public class PlanServiceImpl implements IPlanService {
}
}
/**
/**
* 根据工作流获取下一审核人角色下的所有用户ID
* 根据工作流获取下一审核人角色下的所有用户ID
=》规则推送消息
* @return
* @return
*/
*/
protected
List
<
String
>
getUserIdsByWorkflow
(
Plan
plan
,
String
processInstanceId
){
protected
List
<
String
>
getUserIdsByWorkflow
(
Plan
plan
,
String
processInstanceId
,
Integer
status
,
Integer
excuteState
){
List
<
String
>
userIds
=
new
ArrayList
<>();
List
<
String
>
userIds
=
new
ArrayList
<>();
JSONObject
teskObject
=
workflowFeignService
.
getTaskList
(
processInstanceId
);
JSONObject
teskObject
=
workflowFeignService
.
getTaskList
(
processInstanceId
);
JSONArray
taskDetailArray
=
teskObject
.
getJSONArray
(
WorkFlowEnum
.
DATA
.
getCode
());
JSONArray
taskDetailArray
=
teskObject
.
getJSONArray
(
WorkFlowEnum
.
DATA
.
getCode
());
...
@@ -223,9 +224,15 @@ public class PlanServiceImpl implements IPlanService {
...
@@ -223,9 +224,15 @@ public class PlanServiceImpl implements IPlanService {
JSONObject
jsonItem
=
(
JSONObject
)
item
;
JSONObject
jsonItem
=
(
JSONObject
)
item
;
return
jsonItem
.
getString
(
"userId"
);
return
jsonItem
.
getString
(
"userId"
);
}).
collect
(
Collectors
.
toList
());
}).
collect
(
Collectors
.
toList
());
asyncTask
.
sendAddPlanMsg
(
RequestContext
.
cloneRequestContext
(),
plan
,
userIds
,
true
,
false
);
}
}
else
{
try
{
asyncTask
.
sendPlanMsgToLeadPeople
(
RequestContext
.
cloneRequestContext
(),
plan
);
if
(
ValidationUtil
.
isEmpty
(
status
)){
rulePlanService
.
addPlanRule
(
plan
,
userIds
,
RuleTypeEnum
.
计划提交
.
getCode
());
// 计划提交
}
else
{
rulePlanService
.
addPlanAuditRule
(
plan
,
userIds
,
RuleTypeEnum
.
计划审核
.
getCode
(),
ExecuteStateNameEnum
.
getNameByCode
(
excuteState
));
// 计划审核
}
}
catch
(
Exception
e
)
{
log
.
info
(
"规则调用失败"
);
}
}
}
}
return
userIds
;
return
userIds
;
...
...
amos-boot-module/amos-boot-module-biz/amos-boot-module-supervision-biz/src/main/java/com/yeejoin/amos/supervision/business/service/impl/PlanTaskServiceImpl.java
View file @
3eec8871
...
@@ -12,11 +12,6 @@ import com.yeejoin.amos.supervision.business.dao.mapper.PlanTaskDetailMapper;
...
@@ -12,11 +12,6 @@ import com.yeejoin.amos.supervision.business.dao.mapper.PlanTaskDetailMapper;
import
com.yeejoin.amos.supervision.business.dao.mapper.PlanTaskMapper
;
import
com.yeejoin.amos.supervision.business.dao.mapper.PlanTaskMapper
;
import
com.yeejoin.amos.supervision.business.dao.mapper.RoutePointItemMapper
;
import
com.yeejoin.amos.supervision.business.dao.mapper.RoutePointItemMapper
;
import
com.yeejoin.amos.supervision.business.dao.repository.*
;
import
com.yeejoin.amos.supervision.business.dao.repository.*
;
import
com.yeejoin.amos.supervision.business.dao.repository.ICheckDao
;
import
com.yeejoin.amos.supervision.business.dao.repository.IPlanDao
;
import
com.yeejoin.amos.supervision.business.dao.repository.IPlanTaskDao
;
import
com.yeejoin.amos.supervision.business.dao.repository.IPlanTaskDetailDao
;
import
com.yeejoin.amos.supervision.business.dao.repository.IRoutePointDao
;
import
com.yeejoin.amos.supervision.business.entity.mybatis.CheckChkExListBo
;
import
com.yeejoin.amos.supervision.business.entity.mybatis.CheckChkExListBo
;
import
com.yeejoin.amos.supervision.business.entity.mybatis.PointCheckDetailBo
;
import
com.yeejoin.amos.supervision.business.entity.mybatis.PointCheckDetailBo
;
import
com.yeejoin.amos.supervision.business.feign.Business
;
import
com.yeejoin.amos.supervision.business.feign.Business
;
...
@@ -34,19 +29,21 @@ import com.yeejoin.amos.supervision.business.vo.PlanTaskVo;
...
@@ -34,19 +29,21 @@ import com.yeejoin.amos.supervision.business.vo.PlanTaskVo;
import
com.yeejoin.amos.supervision.common.enums.PlanStatusEnum
;
import
com.yeejoin.amos.supervision.common.enums.PlanStatusEnum
;
import
com.yeejoin.amos.supervision.common.enums.PlanTaskDetailIsFinishEnum
;
import
com.yeejoin.amos.supervision.common.enums.PlanTaskDetailIsFinishEnum
;
import
com.yeejoin.amos.supervision.common.enums.PlanTaskFinishStatusEnum
;
import
com.yeejoin.amos.supervision.common.enums.PlanTaskFinishStatusEnum
;
import
com.yeejoin.amos.supervision.co
re.async.AsyncTask
;
import
com.yeejoin.amos.supervision.co
mmon.enums.RuleTypeEnum
;
import
com.yeejoin.amos.supervision.core.common.request.CommonPageable
;
import
com.yeejoin.amos.supervision.core.common.request.CommonPageable
;
import
com.yeejoin.amos.supervision.core.common.response.AppCheckInputRespone
;
import
com.yeejoin.amos.supervision.core.common.response.AppCheckInputRespone
;
import
com.yeejoin.amos.supervision.core.common.response.AppPointCheckRespone
;
import
com.yeejoin.amos.supervision.core.common.response.AppPointCheckRespone
;
import
com.yeejoin.amos.supervision.core.util.DateUtil
;
import
com.yeejoin.amos.supervision.core.util.DateUtil
;
import
com.yeejoin.amos.supervision.core.util.StringUtil
;
import
com.yeejoin.amos.supervision.core.util.StringUtil
;
import
com.yeejoin.amos.supervision.dao.entity.*
;
import
com.yeejoin.amos.supervision.dao.entity.Check
;
import
com.yeejoin.amos.supervision.dao.entity.Plan
;
import
com.yeejoin.amos.supervision.dao.entity.PlanTask
;
import
com.yeejoin.amos.supervision.dao.entity.PlanTaskDetail
;
import
com.yeejoin.amos.supervision.exception.YeeException
;
import
com.yeejoin.amos.supervision.exception.YeeException
;
import
com.yeejoin.amos.supervision.feign.RemoteSecurityService
;
import
com.yeejoin.amos.supervision.feign.RemoteSecurityService
;
import
com.yeejoin.amos.supervision.quartz.IJobService
;
import
com.yeejoin.amos.supervision.quartz.IJobService
;
import
org.apache.commons.collections.CollectionUtils
;
import
org.apache.commons.collections.CollectionUtils
;
import
org.assertj.core.util.Lists
;
import
org.assertj.core.util.Lists
;
import
org.checkerframework.checker.units.qual.A
;
import
org.slf4j.Logger
;
import
org.slf4j.Logger
;
import
org.slf4j.LoggerFactory
;
import
org.slf4j.LoggerFactory
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Autowired
;
...
@@ -56,7 +53,6 @@ import org.springframework.stereotype.Service;
...
@@ -56,7 +53,6 @@ import org.springframework.stereotype.Service;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.util.ObjectUtils
;
import
org.springframework.util.ObjectUtils
;
import
org.springframework.util.StringUtils
;
import
org.springframework.util.StringUtils
;
import
org.typroject.tyboot.core.foundation.context.RequestContext
;
import
org.typroject.tyboot.core.foundation.utils.ValidationUtil
;
import
org.typroject.tyboot.core.foundation.utils.ValidationUtil
;
import
java.text.ParseException
;
import
java.text.ParseException
;
...
@@ -106,7 +102,7 @@ public class PlanTaskServiceImpl implements IPlanTaskService {
...
@@ -106,7 +102,7 @@ public class PlanTaskServiceImpl implements IPlanTaskService {
private
RoutePointItemMapper
routePointItemMapper
;
private
RoutePointItemMapper
routePointItemMapper
;
@Autowired
@Autowired
private
AsyncTask
asyncTask
;
private
RulePlanService
rulePlanService
;
@Override
@Override
public
Page
<
HashMap
<
String
,
Object
>>
getPlanTaskInfo
(
PlanTaskPageParam
params
)
{
public
Page
<
HashMap
<
String
,
Object
>>
getPlanTaskInfo
(
PlanTaskPageParam
params
)
{
...
@@ -531,8 +527,8 @@ public class PlanTaskServiceImpl implements IPlanTaskService {
...
@@ -531,8 +527,8 @@ public class PlanTaskServiceImpl implements IPlanTaskService {
// 2.保存执行数据明细表
// 2.保存执行数据明细表
planTaskDetail
.
saveAndFlush
(
planTaskDetailInstance
);
planTaskDetail
.
saveAndFlush
(
planTaskDetailInstance
);
// 推送消息
//
规则
推送消息
asyncTask
.
sendPlanMsg
(
RequestContext
.
cloneRequestContext
(),
plan
);
rulePlanService
.
addPlanRule
(
plan
,
null
,
RuleTypeEnum
.
计划生成
.
getCode
()
);
}
}
// 定时任务监控
// 定时任务监控
jobService
.
planTaskAddJob
(
planTask
);
jobService
.
planTaskAddJob
(
planTask
);
...
...
amos-boot-module/amos-boot-module-biz/amos-boot-module-supervision-biz/src/main/java/com/yeejoin/amos/supervision/business/service/impl/RulePlanService.java
0 → 100644
View file @
3eec8871
package
com
.
yeejoin
.
amos
.
supervision
.
business
.
service
.
impl
;
import
com.yeejoin.amos.component.rule.RuleTrigger
;
import
com.yeejoin.amos.supervision.business.dto.PlanRo
;
import
com.yeejoin.amos.supervision.business.feign.JCSFeignClient
;
import
com.yeejoin.amos.supervision.business.util.DateUtil
;
import
com.yeejoin.amos.supervision.dao.entity.Plan
;
import
org.springframework.beans.BeanUtils
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
org.typroject.tyboot.core.foundation.utils.ValidationUtil
;
import
java.util.Date
;
import
java.util.List
;
/**
* @Author: xl
* @Description: 巡检计划触发规则
* @Date: 2021/11/10 9:50
*/
@Service
public
class
RulePlanService
{
private
final
String
packageId
=
"消息/addPlanRule"
;
private
final
String
msgType
=
"supervision"
;
private
final
String
APP
=
"APP"
;
private
final
String
WEB
=
"WEB"
;
private
final
String
APP_WEB
=
"APP/WEB"
;
@Autowired
private
RuleTrigger
ruleTrigger
;
@Autowired
private
JCSFeignClient
jcsFeignClient
;
public
Boolean
addPlanRule
(
Plan
plan
,
List
<
String
>
userIds
,
String
ruleType
)
throws
Exception
{
PlanRo
planRo
=
buildPlanRo
(
plan
,
userIds
,
ruleType
);
//触发规则
ruleTrigger
.
publish
(
planRo
,
packageId
,
new
String
[
0
]);
return
true
;
}
public
Boolean
addPlanAuditRule
(
Plan
plan
,
List
<
String
>
userIds
,
String
ruleType
,
String
excuteStateName
)
throws
Exception
{
PlanRo
planRo
=
buildPlanRo
(
plan
,
userIds
,
ruleType
);
planRo
.
setExcuteStateName
(
excuteStateName
);
//触发规则
ruleTrigger
.
publish
(
planRo
,
packageId
,
new
String
[
0
]);
return
true
;
}
private
PlanRo
buildPlanRo
(
Plan
plan
,
List
<
String
>
userIds
,
String
ruleType
){
PlanRo
planRo
=
new
PlanRo
();
BeanUtils
.
copyProperties
(
plan
,
planRo
);
planRo
.
setMsgType
(
msgType
);
planRo
.
setRuleType
(
ruleType
);
planRo
.
setRelationId
(
String
.
valueOf
(
plan
.
getId
()));
if
(
ValidationUtil
.
isEmpty
(
userIds
)){
String
leadPeopleIds
=
plan
.
getLeadPeopleIds
();
if
(!
ValidationUtil
.
isEmpty
(
plan
.
getUserId
())
&&
!
leadPeopleIds
.
contains
(
plan
.
getUserId
())){
leadPeopleIds
+=
","
+
plan
.
getUserId
();
}
userIds
=
(
List
<
String
>)
jcsFeignClient
.
getAmosIdListByUserIds
(
leadPeopleIds
).
getResult
();
planRo
.
setIsSendApp
(
true
);
planRo
.
setTerminal
(
WEB
);
}
else
{
planRo
.
setIsSendWeb
(
true
);
planRo
.
setIsSendApp
(
false
);
planRo
.
setTerminal
(
APP_WEB
);
}
planRo
.
setSendTime
(
DateUtil
.
date2LongStr
(
new
Date
()));
planRo
.
setRecivers
(
userIds
);
return
planRo
;
}
}
amos-boot-module/amos-boot-module-biz/amos-boot-module-supervision-biz/src/main/java/com/yeejoin/amos/supervision/business/util/MsgParamUtils.java
View file @
3eec8871
package
com
.
yeejoin
.
amos
.
supervision
.
business
.
util
;
package
com
.
yeejoin
.
amos
.
supervision
.
business
.
util
;
import
java.lang.reflect.Field
;
import
java.lang.reflect.Method
;
import
java.util.HashMap
;
import
java.util.HashMap
;
import
java.util.List
;
import
java.util.List
;
import
java.util.Map
;
import
com.alibaba.fastjson.JSON
;
import
com.yeejoin.amos.supervision.business.param.MsgInfoPageParam
;
import
com.yeejoin.amos.supervision.business.param.MsgInfoPageParam
;
import
com.yeejoin.amos.supervision.core.common.request.CommonPageable
;
import
com.yeejoin.amos.supervision.core.common.request.CommonPageable
;
import
com.yeejoin.amos.supervision.core.common.request.CommonRequest
;
import
com.yeejoin.amos.supervision.core.common.request.CommonRequest
;
...
@@ -40,4 +44,11 @@ public class MsgParamUtils {
...
@@ -40,4 +44,11 @@ public class MsgParamUtils {
return
value
.
toString
();
return
value
.
toString
();
}
}
}
}
public
static
String
instedParams
(
String
content
,
Object
msgObj
)
{
Map
<
String
,
Object
>
strengthMap
=
JSON
.
parseObject
(
JSON
.
toJSONString
(
msgObj
),
Map
.
class
);
for
(
String
key
:
strengthMap
.
keySet
())
content
=
content
.
replaceAll
(
"\\$\\{"
+
key
+
"}"
,
String
.
valueOf
(
strengthMap
.
get
(
key
)));
return
content
;
}
}
}
amos-boot-module/amos-boot-module-biz/amos-boot-module-supervision-biz/src/main/java/com/yeejoin/amos/supervision/core/async/AsyncTask.java
View file @
3eec8871
...
@@ -306,89 +306,6 @@ public class AsyncTask {
...
@@ -306,89 +306,6 @@ public class AsyncTask {
}
}
}
}
/**
* 提交计划任务消息
* @param requestContextModel
* @param plan
* @param userIds 发送用户id集合
* @param isSendWeb 发送web标识
* @param isSendApp 发送app标识
*/
@Async
public
void
sendAddPlanMsg
(
RequestContextModel
requestContextModel
,
Plan
plan
,
List
<
String
>
userIds
,
boolean
isSendWeb
,
boolean
isSendApp
){
MessageModel
model
=
new
MessageModel
();
model
.
setTitle
(
plan
.
getName
());
String
body
=
String
.
format
(
"计划名称:%s;检查类型:%s;推送时间:%s"
,
plan
.
getName
(),
plan
.
getCheckTypeName
(),
DateUtil
.
date2LongStr
(
new
Date
()));
model
.
setBody
(
body
);
try
{
model
.
setIsSendWeb
(
isSendWeb
);
model
.
setIsSendApp
(
isSendApp
);
model
.
setMsgType
(
msgType
);
model
.
setRelationId
(
String
.
valueOf
(
plan
.
getId
()));
model
.
setRecivers
(
userIds
);
remoteSecurityService
.
addMessage
(
requestContextModel
,
model
);
}
catch
(
Exception
e
)
{
e
.
printStackTrace
();
}
}
/**
* 发送消息至检查组长
* @param plan
*/
@Async
public
void
sendPlanMsgToLeadPeople
(
RequestContextModel
requestContextModel
,
Plan
plan
){
MessageModel
model
=
new
MessageModel
();
model
.
setTitle
(
plan
.
getName
());
String
body
=
String
.
format
(
"计划名称:%s;检查类型:%s;推送时间:%s"
,
plan
.
getName
(),
plan
.
getCheckTypeName
(),
DateUtil
.
date2LongStr
(
new
Date
()));
model
.
setBody
(
body
);
String
leadPeopleIds
=
plan
.
getLeadPeopleIds
();
if
(!
ValidationUtil
.
isEmpty
(
plan
.
getUserId
())
&&
!
leadPeopleIds
.
contains
(
plan
.
getUserId
())){
leadPeopleIds
+=
","
+
plan
.
getUserId
();
}
try
{
List
<
String
>
recivers
=
remoteSecurityService
.
getAmosIdListByUserIds
(
requestContextModel
,
leadPeopleIds
);
model
.
setIsSendWeb
(
true
);
model
.
setIsSendApp
(
true
);
model
.
setMsgType
(
msgType
);
model
.
setRelationId
(
String
.
valueOf
(
plan
.
getId
()));
model
.
setRecivers
(
recivers
);
remoteSecurityService
.
addMessage
(
requestContextModel
,
model
);
}
catch
(
Exception
e
)
{
e
.
printStackTrace
();
}
}
/**
* 发送消息至检查组员
* @param plan
*/
@Async
public
void
sendPlanMsg
(
RequestContextModel
requestContextModel
,
Plan
plan
){
MessageModel
model
=
new
MessageModel
();
model
.
setTitle
(
plan
.
getName
());
String
body
=
String
.
format
(
"计划名称:%s;检查类型:%s;推送时间:%s"
,
plan
.
getName
(),
plan
.
getCheckTypeName
(),
DateUtil
.
date2LongStr
(
new
Date
()));
model
.
setBody
(
body
);
String
leadPeopleIds
=
plan
.
getLeadPeopleIds
();
if
(!
ValidationUtil
.
isEmpty
(
plan
.
getUserId
())
&&
!
leadPeopleIds
.
contains
(
plan
.
getUserId
())){
leadPeopleIds
+=
","
+
plan
.
getUserId
();
}
try
{
List
<
String
>
recivers
=
remoteSecurityService
.
getAmosIdListByUserIds
(
requestContextModel
,
leadPeopleIds
);
model
.
setIsSendApp
(
true
);
model
.
setIsSendWeb
(
true
);
model
.
setMsgType
(
msgType
);
model
.
setRelationId
(
String
.
valueOf
(
plan
.
getId
()));
model
.
setRecivers
(
recivers
);
remoteSecurityService
.
addMessage
(
requestContextModel
,
model
);
}
catch
(
Exception
e
)
{
e
.
printStackTrace
();
}
}
private
Set
<
String
>
userIdFilter
(
Set
<
String
>
sendUserIds
,
String
msgType
)
{
private
Set
<
String
>
userIdFilter
(
Set
<
String
>
sendUserIds
,
String
msgType
)
{
Set
<
String
>
afterFilterUserIds
=
Sets
.
newHashSet
();
Set
<
String
>
afterFilterUserIds
=
Sets
.
newHashSet
();
if
(
CollectionUtils
.
isEmpty
(
sendUserIds
))
{
if
(
CollectionUtils
.
isEmpty
(
sendUserIds
))
{
...
...
amos-boot-module/amos-boot-module-biz/amos-boot-module-supervision-biz/src/main/java/com/yeejoin/amos/supervision/feign/RemoteSecurityService.java
View file @
3eec8871
...
@@ -752,36 +752,6 @@ public class RemoteSecurityService {
...
@@ -752,36 +752,6 @@ public class RemoteSecurityService {
return
handleArray
(
feignClientResult
,
DepartmentModel
.
class
);
return
handleArray
(
feignClientResult
,
DepartmentModel
.
class
);
}
}
/**
* 平台消息-添加
*/
public
void
addMessage
(
RequestContextModel
requestContextModel
,
MessageModel
model
){
RequestContext
.
setToken
(
requestContextModel
.
getToken
());
RequestContext
.
setProduct
(
requestContextModel
.
getProduct
());
RequestContext
.
setAppKey
(
requestContextModel
.
getAppKey
());
try
{
FeignClientResult
<
MessageModel
>
messageModelFeignClientResult
=
Systemctl
.
messageClient
.
create
(
model
);
}
catch
(
InnerInvokException
e
)
{
e
.
printStackTrace
();
}
}
/**
* 机场用户id批量获取平台用户id
*/
public
List
<
String
>
getAmosIdListByUserIds
(
RequestContextModel
requestContextModel
,
String
orgUserIds
){
RequestContext
.
setToken
(
requestContextModel
.
getToken
());
RequestContext
.
setProduct
(
requestContextModel
.
getProduct
());
RequestContext
.
setAppKey
(
requestContextModel
.
getAppKey
());
List
<
String
>
userNames
=
new
ArrayList
<>();
try
{
userNames
=
(
List
<
String
>)
jcsFeignClient
.
getAmosIdListByUserIds
(
orgUserIds
).
getResult
();
}
catch
(
InnerInvokException
e
)
{
e
.
printStackTrace
();
}
return
userNames
;
}
private
<
T
>
List
<
T
>
handleArray
(
FeignClientResult
feignClientResult
,
Class
<
T
>
t
)
{
private
<
T
>
List
<
T
>
handleArray
(
FeignClientResult
feignClientResult
,
Class
<
T
>
t
)
{
List
<
T
>
list
=
new
ArrayList
<>();
List
<
T
>
list
=
new
ArrayList
<>();
if
(
feignClientResult
!=
null
&&
feignClientResult
.
getStatus
()
==
200
)
{
if
(
feignClientResult
!=
null
&&
feignClientResult
.
getStatus
()
==
200
)
{
...
...
amos-boot-module/amos-boot-module-biz/amos-boot-module-supervision-biz/src/main/java/com/yeejoin/amos/supervision/rule/action/MessageAction.java
0 → 100644
View file @
3eec8871
package
com
.
yeejoin
.
amos
.
supervision
.
rule
.
action
;
import
com.alibaba.fastjson.JSON
;
import
com.yeejoin.amos.component.rule.RuleActionBean
;
import
com.yeejoin.amos.component.rule.RuleMethod
;
import
com.yeejoin.amos.feign.systemctl.Systemctl
;
import
com.yeejoin.amos.feign.systemctl.model.MessageModel
;
import
com.yeejoin.amos.supervision.business.util.MsgParamUtils
;
import
org.slf4j.Logger
;
import
org.slf4j.LoggerFactory
;
import
org.springframework.stereotype.Component
;
import
org.typroject.tyboot.core.foundation.utils.ValidationUtil
;
/**
* @Author: xl
* @Description: 消息规则动作
* @Date: 2021/11/10 11:49
*/
@Component
@RuleActionBean
(
beanLabel
=
"消息发送"
)
public
class
MessageAction
{
public
static
final
Logger
log
=
LoggerFactory
.
getLogger
(
MessageAction
.
class
);
@RuleMethod
(
methodLabel
=
"消息发送"
,
project
=
"消息"
)
public
void
sendMessage
(
Object
msgObj
,
String
title
,
String
content
)
{
MessageModel
messageModel
=
JSON
.
parseObject
(
JSON
.
toJSONString
(
msgObj
),
MessageModel
.
class
);
messageModel
.
setTitle
(
title
);
messageModel
.
setBody
(
MsgParamUtils
.
instedParams
(
content
,
msgObj
));
if
(!
ValidationUtil
.
isEmpty
(
messageModel
))
{
try
{
Systemctl
.
messageClient
.
create
(
messageModel
);
}
catch
(
Exception
e
)
{
e
.
printStackTrace
();
}
}
}
}
amos-boot-system-ccs/src/main/resources/application.properties
View file @
3eec8871
spring.application.name
=
AMOS-BIZ-
API-CCS
spring.application.name
=
AMOS-BIZ-
CCS-API
server.servlet.context-path
=
/ccs
server.servlet.context-path
=
/ccs
server.port
=
8807
server.port
=
8807
spring.profiles.active
=
dev
spring.profiles.active
=
dev
...
...
amos-boot-system-ccs/src/main/resources/db/changelog/init/amos-ccs-biz.sql
View file @
3eec8871
...
@@ -10,7 +10,7 @@ Target Server Type : MYSQL
...
@@ -10,7 +10,7 @@ Target Server Type : MYSQL
Target Server Version : 80018
Target Server Version : 80018
File Encoding : 65001
File Encoding : 65001
Date: 2021-11-
09 18:01:08
Date: 2021-11-
12 11:20:29
*/
*/
SET
FOREIGN_KEY_CHECKS
=
0
;
SET
FOREIGN_KEY_CHECKS
=
0
;
...
@@ -26,7 +26,7 @@ CREATE TABLE `asf_fire_alarm_day_statistics` (
...
@@ -26,7 +26,7 @@ CREATE TABLE `asf_fire_alarm_day_statistics` (
`collect_date`
date
DEFAULT
NULL
COMMENT
'统计日期'
,
`collect_date`
date
DEFAULT
NULL
COMMENT
'统计日期'
,
`equipment_definition_mrid`
varchar
(
32
)
CHARACTER
SET
utf8mb4
COLLATE
utf8mb4_0900_ai_ci
NOT
NULL
COMMENT
'装备定义mrid'
,
`equipment_definition_mrid`
varchar
(
32
)
CHARACTER
SET
utf8mb4
COLLATE
utf8mb4_0900_ai_ci
NOT
NULL
COMMENT
'装备定义mrid'
,
`equipment_definition_name`
varchar
(
255
)
CHARACTER
SET
utf8mb4
COLLATE
utf8mb4_0900_ai_ci
DEFAULT
NULL
COMMENT
'装备定义名称'
,
`equipment_definition_name`
varchar
(
255
)
CHARACTER
SET
utf8mb4
COLLATE
utf8mb4_0900_ai_ci
DEFAULT
NULL
COMMENT
'装备定义名称'
,
`alarm_times`
int
(
11
)
DEFAULT
'
0
'
COMMENT
'报警次数'
,
`alarm_times`
int
(
11
)
DEFAULT
'
1
'
COMMENT
'报警次数'
,
`alarm_type`
varchar
(
50
)
CHARACTER
SET
utf8mb4
COLLATE
utf8mb4_0900_ai_ci
DEFAULT
NULL
COMMENT
'告警类型'
,
`alarm_type`
varchar
(
50
)
CHARACTER
SET
utf8mb4
COLLATE
utf8mb4_0900_ai_ci
DEFAULT
NULL
COMMENT
'告警类型'
,
`alarm_type_name`
varchar
(
255
)
DEFAULT
NULL
COMMENT
'告警类型名称'
,
`alarm_type_name`
varchar
(
255
)
DEFAULT
NULL
COMMENT
'告警类型名称'
,
`create_date`
datetime
DEFAULT
CURRENT_TIMESTAMP
COMMENT
'创建日期'
,
`create_date`
datetime
DEFAULT
CURRENT_TIMESTAMP
COMMENT
'创建日期'
,
...
@@ -36,6 +36,12 @@ CREATE TABLE `asf_fire_alarm_day_statistics` (
...
@@ -36,6 +36,12 @@ CREATE TABLE `asf_fire_alarm_day_statistics` (
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8mb4
COLLATE
=
utf8mb4_0900_ai_ci
COMMENT
=
'换流站告警日统计'
;
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8mb4
COLLATE
=
utf8mb4_0900_ai_ci
COMMENT
=
'换流站告警日统计'
;
-- ----------------------------
-- ----------------------------
-- Records of asf_fire_alarm_day_statistics
-- ----------------------------
INSERT
INTO
`asf_fire_alarm_day_statistics`
VALUES
(
'1'
,
'101'
,
'复龙换流站'
,
'2021-11-11'
,
'1'
,
null
,
'2'
,
null
,
null
,
'2021-11-10 11:59:25'
,
'2021-11-11 16:22:28'
);
INSERT
INTO
`asf_fire_alarm_day_statistics`
VALUES
(
'2'
,
'102'
,
'金华换流站'
,
'2021-11-11'
,
'1'
,
null
,
'1'
,
null
,
null
,
'2021-11-10 11:59:25'
,
'2021-11-11 15:44:31'
);
-- ----------------------------
-- Table structure for asf_fire_danger_day_statistics
-- Table structure for asf_fire_danger_day_statistics
-- ----------------------------
-- ----------------------------
DROP
TABLE
IF
EXISTS
`asf_fire_danger_day_statistics`
;
DROP
TABLE
IF
EXISTS
`asf_fire_danger_day_statistics`
;
...
@@ -44,7 +50,7 @@ CREATE TABLE `asf_fire_danger_day_statistics` (
...
@@ -44,7 +50,7 @@ CREATE TABLE `asf_fire_danger_day_statistics` (
`station_code`
varchar
(
255
)
CHARACTER
SET
utf8mb4
COLLATE
utf8mb4_0900_ai_ci
NOT
NULL
COMMENT
'站点编码'
,
`station_code`
varchar
(
255
)
CHARACTER
SET
utf8mb4
COLLATE
utf8mb4_0900_ai_ci
NOT
NULL
COMMENT
'站点编码'
,
`station_name`
varchar
(
255
)
CHARACTER
SET
utf8mb4
COLLATE
utf8mb4_0900_ai_ci
DEFAULT
NULL
COMMENT
'站点名称'
,
`station_name`
varchar
(
255
)
CHARACTER
SET
utf8mb4
COLLATE
utf8mb4_0900_ai_ci
DEFAULT
NULL
COMMENT
'站点名称'
,
`collect_date`
date
NOT
NULL
COMMENT
'统计日期'
,
`collect_date`
date
NOT
NULL
COMMENT
'统计日期'
,
`danger_times`
int
(
11
)
DEFAULT
'
0
'
COMMENT
'报警次数'
,
`danger_times`
int
(
11
)
DEFAULT
'
1
'
COMMENT
'报警次数'
,
`create_date`
datetime
DEFAULT
CURRENT_TIMESTAMP
COMMENT
'创建日期'
,
`create_date`
datetime
DEFAULT
CURRENT_TIMESTAMP
COMMENT
'创建日期'
,
`syn_date`
datetime
DEFAULT
CURRENT_TIMESTAMP
ON
UPDATE
CURRENT_TIMESTAMP
COMMENT
'同步日期'
,
`syn_date`
datetime
DEFAULT
CURRENT_TIMESTAMP
ON
UPDATE
CURRENT_TIMESTAMP
COMMENT
'同步日期'
,
PRIMARY
KEY
(
`id`
)
USING
BTREE
,
PRIMARY
KEY
(
`id`
)
USING
BTREE
,
...
@@ -52,6 +58,11 @@ CREATE TABLE `asf_fire_danger_day_statistics` (
...
@@ -52,6 +58,11 @@ CREATE TABLE `asf_fire_danger_day_statistics` (
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8mb4
COLLATE
=
utf8mb4_0900_ai_ci
COMMENT
=
'换流站隐患日统计'
;
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8mb4
COLLATE
=
utf8mb4_0900_ai_ci
COMMENT
=
'换流站隐患日统计'
;
-- ----------------------------
-- ----------------------------
-- Records of asf_fire_danger_day_statistics
-- ----------------------------
INSERT
INTO
`asf_fire_danger_day_statistics`
VALUES
(
'1'
,
'101'
,
'复龙换流站'
,
'2021-11-11'
,
'2'
,
'2021-11-11 17:06:27'
,
'2021-11-11 17:06:27'
);
-- ----------------------------
-- Table structure for asf_fire_equipment_alarm
-- Table structure for asf_fire_equipment_alarm
-- ----------------------------
-- ----------------------------
DROP
TABLE
IF
EXISTS
`asf_fire_equipment_alarm`
;
DROP
TABLE
IF
EXISTS
`asf_fire_equipment_alarm`
;
...
@@ -90,6 +101,10 @@ CREATE TABLE `asf_fire_equipment_alarm` (
...
@@ -90,6 +101,10 @@ CREATE TABLE `asf_fire_equipment_alarm` (
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8mb4
COLLATE
=
utf8mb4_0900_ai_ci
ROW_FORMAT
=
DYNAMIC
COMMENT
=
'设备报警信息表'
;
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8mb4
COLLATE
=
utf8mb4_0900_ai_ci
ROW_FORMAT
=
DYNAMIC
COMMENT
=
'设备报警信息表'
;
-- ----------------------------
-- ----------------------------
-- Records of asf_fire_equipment_alarm
-- ----------------------------
-- ----------------------------
-- Table structure for asf_fire_equipment_alarm_log
-- Table structure for asf_fire_equipment_alarm_log
-- ----------------------------
-- ----------------------------
DROP
TABLE
IF
EXISTS
`asf_fire_equipment_alarm_log`
;
DROP
TABLE
IF
EXISTS
`asf_fire_equipment_alarm_log`
;
...
@@ -103,11 +118,13 @@ CREATE TABLE `asf_fire_equipment_alarm_log` (
...
@@ -103,11 +118,13 @@ CREATE TABLE `asf_fire_equipment_alarm_log` (
`fire_equipment_index_key`
varchar
(
255
)
CHARACTER
SET
utf8
COLLATE
utf8_general_ci
DEFAULT
NULL
COMMENT
'指标编码'
,
`fire_equipment_index_key`
varchar
(
255
)
CHARACTER
SET
utf8
COLLATE
utf8_general_ci
DEFAULT
NULL
COMMENT
'指标编码'
,
`fire_equipment_index_value`
varchar
(
500
)
CHARACTER
SET
utf8
COLLATE
utf8_general_ci
DEFAULT
NULL
COMMENT
'报警值'
,
`fire_equipment_index_value`
varchar
(
500
)
CHARACTER
SET
utf8
COLLATE
utf8_general_ci
DEFAULT
NULL
COMMENT
'报警值'
,
`fire_building_mrid`
varchar
(
255
)
CHARACTER
SET
utf8
COLLATE
utf8_general_ci
DEFAULT
NULL
COMMENT
'建筑id(冗余字段)'
,
`fire_building_mrid`
varchar
(
255
)
CHARACTER
SET
utf8
COLLATE
utf8_general_ci
DEFAULT
NULL
COMMENT
'建筑id(冗余字段)'
,
`type`
varchar
(
50
)
CHARACTER
SET
utf8
COLLATE
utf8_general_ci
NOT
NULL
COMMENT
'报警类型:alarm_type_fire(火灾报警)/alarm_type_trouble(故障告警)'
,
`alarm_type`
varchar
(
50
)
CHARACTER
SET
utf8
COLLATE
utf8_general_ci
NOT
NULL
COMMENT
'报警类型:alarm_type_fire(火灾报警)/alarm_type_trouble(故障告警)'
,
`alarm_type_name`
varchar
(
255
)
CHARACTER
SET
utf8mb4
COLLATE
utf8mb4_0900_ai_ci
DEFAULT
NULL
COMMENT
'告警类型名称'
,
`confirm_type`
varchar
(
100
)
DEFAULT
NULL
COMMENT
'确认类型'
,
`confirm_type`
varchar
(
100
)
DEFAULT
NULL
COMMENT
'确认类型'
,
`confirm_type_name`
varchar
(
255
)
CHARACTER
SET
utf8
COLLATE
utf8_general_ci
DEFAULT
NULL
COMMENT
'确认类型名称'
,
`confirm_type_name`
varchar
(
255
)
CHARACTER
SET
utf8
COLLATE
utf8_general_ci
DEFAULT
NULL
COMMENT
'确认类型名称'
,
`alarm_reason`
varchar
(
300
)
CHARACTER
SET
utf8
COLLATE
utf8_general_ci
DEFAULT
NULL
COMMENT
'报警原因'
,
`alarm_reason`
varchar
(
300
)
CHARACTER
SET
utf8
COLLATE
utf8_general_ci
DEFAULT
NULL
COMMENT
'报警原因'
,
`resolve_result`
varchar
(
300
)
CHARACTER
SET
utf8
COLLATE
utf8_general_ci
DEFAULT
NULL
COMMENT
'处理情况'
,
`resolve_result`
varchar
(
300
)
CHARACTER
SET
utf8
COLLATE
utf8_general_ci
DEFAULT
NULL
COMMENT
'处理情况'
,
`confirm_state`
varchar
(
20
)
CHARACTER
SET
utf8mb4
COLLATE
utf8mb4_0900_ai_ci
DEFAULT
NULL
COMMENT
'确认状态: 0-未确认 1-已确认'
,
`confirm_user_name`
varchar
(
255
)
CHARACTER
SET
utf8
COLLATE
utf8_general_ci
DEFAULT
NULL
COMMENT
'确警人员姓名'
,
`confirm_user_name`
varchar
(
255
)
CHARACTER
SET
utf8
COLLATE
utf8_general_ci
DEFAULT
NULL
COMMENT
'确警人员姓名'
,
`confirm_date`
datetime
DEFAULT
NULL
COMMENT
'确警时间'
,
`confirm_date`
datetime
DEFAULT
NULL
COMMENT
'确警时间'
,
`system_mrids`
text
CHARACTER
SET
utf8
COLLATE
utf8_general_ci
COMMENT
'装备所属消防系统code(冗余字段)'
,
`system_mrids`
text
CHARACTER
SET
utf8
COLLATE
utf8_general_ci
COMMENT
'装备所属消防系统code(冗余字段)'
,
...
@@ -124,6 +141,14 @@ CREATE TABLE `asf_fire_equipment_alarm_log` (
...
@@ -124,6 +141,14 @@ CREATE TABLE `asf_fire_equipment_alarm_log` (
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8mb4
COLLATE
=
utf8mb4_0900_ai_ci
COMMENT
=
'设备报警信息日志表'
;
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8mb4
COLLATE
=
utf8mb4_0900_ai_ci
COMMENT
=
'设备报警信息日志表'
;
-- ----------------------------
-- ----------------------------
-- Records of asf_fire_equipment_alarm_log
-- ----------------------------
INSERT
INTO
`asf_fire_equipment_alarm_log`
VALUES
(
'1'
,
'换流站1'
,
'101'
,
'101'
,
'感温'
,
'故障'
,
'FAS_SmokeAlarm_Fault'
,
'true'
,
'101'
,
'FIREALARM'
,
'故障告警'
,
null
,
null
,
null
,
null
,
'0'
,
null
,
null
,
null
,
null
,
null
,
'2021-11-09 11:40:28'
,
'极Ⅰ辅控楼-极1辅控楼二层-火灾报警装置_极1辅控楼二层走道N002L01D011烟感火警状态'
,
null
,
null
,
'2021-11-10 15:42:21'
);
INSERT
INTO
`asf_fire_equipment_alarm_log`
VALUES
(
'2'
,
'换流站1'
,
'101'
,
'101'
,
'感温'
,
'故障'
,
'FAS_SmokeAlarm_Fault'
,
'true'
,
'101'
,
'FIREALARM'
,
'故障告警'
,
null
,
null
,
null
,
null
,
'1'
,
null
,
null
,
null
,
null
,
null
,
'2021-11-10 11:40:28'
,
'极Ⅰ辅控楼-极1辅控楼二层-火灾报警装置_极1辅控楼二层走道N002L01D011烟感火警状态'
,
null
,
null
,
'2021-11-10 15:42:21'
);
INSERT
INTO
`asf_fire_equipment_alarm_log`
VALUES
(
'3'
,
'换流站1'
,
'101'
,
'101'
,
'感温'
,
'故障'
,
'FAS_SmokeAlarm_Fault'
,
'true'
,
'101'
,
'FIREALARM'
,
'故障告警'
,
null
,
null
,
null
,
null
,
'0'
,
null
,
null
,
null
,
null
,
null
,
'2021-11-10 11:40:28'
,
'极Ⅰ辅控楼-极1辅控楼二层-火灾报警装置_极1辅控楼二层走道N002L01D011烟感火警状态'
,
null
,
null
,
'2021-11-10 15:42:21'
);
INSERT
INTO
`asf_fire_equipment_alarm_log`
VALUES
(
'4'
,
'换流站1'
,
'101'
,
'101'
,
'感温'
,
'故障'
,
'FAS_SmokeAlarm_Fault'
,
'true'
,
'101'
,
'FIREALARM'
,
'故障告警'
,
null
,
null
,
null
,
null
,
'0'
,
null
,
null
,
null
,
null
,
null
,
'2021-11-10 11:40:28'
,
'主控楼-主控楼一层-火灾报警装置_极2低端阀组辅助设备室N001L01D001烟感火警状态'
,
null
,
null
,
'2021-11-10 15:42:22'
);
-- ----------------------------
-- Table structure for asf_fire_fmea_statistics
-- Table structure for asf_fire_fmea_statistics
-- ----------------------------
-- ----------------------------
DROP
TABLE
IF
EXISTS
`asf_fire_fmea_statistics`
;
DROP
TABLE
IF
EXISTS
`asf_fire_fmea_statistics`
;
...
@@ -142,6 +167,10 @@ CREATE TABLE `asf_fire_fmea_statistics` (
...
@@ -142,6 +167,10 @@ CREATE TABLE `asf_fire_fmea_statistics` (
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8mb4
COLLATE
=
utf8mb4_0900_ai_ci
COMMENT
=
'发生率/严重度矩阵统计表'
;
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8mb4
COLLATE
=
utf8mb4_0900_ai_ci
COMMENT
=
'发生率/严重度矩阵统计表'
;
-- ----------------------------
-- ----------------------------
-- Records of asf_fire_fmea_statistics
-- ----------------------------
-- ----------------------------
-- Table structure for asf_fire_latent_danger
-- Table structure for asf_fire_latent_danger
-- ----------------------------
-- ----------------------------
DROP
TABLE
IF
EXISTS
`asf_fire_latent_danger`
;
DROP
TABLE
IF
EXISTS
`asf_fire_latent_danger`
;
...
@@ -151,11 +180,12 @@ CREATE TABLE `asf_fire_latent_danger` (
...
@@ -151,11 +180,12 @@ CREATE TABLE `asf_fire_latent_danger` (
`station_name`
varchar
(
255
)
CHARACTER
SET
utf8mb4
COLLATE
utf8mb4_0900_ai_ci
DEFAULT
NULL
COMMENT
'站点名称'
,
`station_name`
varchar
(
255
)
CHARACTER
SET
utf8mb4
COLLATE
utf8mb4_0900_ai_ci
DEFAULT
NULL
COMMENT
'站点名称'
,
`danger_mrid`
varchar
(
32
)
NOT
NULL
COMMENT
'风险点id'
,
`danger_mrid`
varchar
(
32
)
NOT
NULL
COMMENT
'风险点id'
,
`danger_name`
varchar
(
255
)
DEFAULT
NULL
COMMENT
'风险点名称'
,
`danger_name`
varchar
(
255
)
DEFAULT
NULL
COMMENT
'风险点名称'
,
`danger_state
_code
`
varchar
(
20
)
CHARACTER
SET
utf8mb4
COLLATE
utf8mb4_0900_ai_ci
NOT
NULL
COMMENT
'隐患状态:隐患状态(1:待评审;2:待治理;3:安措计划中;4:待验证;5:治理完毕;6:已撤销;7:延期治理中;8:延期治理待车间部门审核;9:延期治理待公司审核
''
'
,
`danger_state`
varchar
(
20
)
CHARACTER
SET
utf8mb4
COLLATE
utf8mb4_0900_ai_ci
NOT
NULL
COMMENT
'隐患状态:隐患状态(1:待评审;2:待治理;3:安措计划中;4:待验证;5:治理完毕;6:已撤销;7:延期治理中;8:延期治理待车间部门审核;9:延期治理待公司审核
''
'
,
`danger_state_name`
varchar
(
255
)
CHARACTER
SET
utf8mb4
COLLATE
utf8mb4_0900_ai_ci
DEFAULT
NULL
COMMENT
'隐患状态名称'
,
`danger_state_name`
varchar
(
255
)
CHARACTER
SET
utf8mb4
COLLATE
utf8mb4_0900_ai_ci
DEFAULT
NULL
COMMENT
'隐患状态名称'
,
`danger_type`
varchar
(
20
)
CHARACTER
SET
utf8mb4
COLLATE
utf8mb4_0900_ai_ci
DEFAULT
''
COMMENT
'隐患类型枚举(1:无码无计划隐患;2:巡检隐患;3:有码无计划隐患;4:随手拍)'
,
`danger_type`
varchar
(
20
)
CHARACTER
SET
utf8mb4
COLLATE
utf8mb4_0900_ai_ci
DEFAULT
''
COMMENT
'隐患类型枚举(1:无码无计划隐患;2:巡检隐患;3:有码无计划隐患;4:随手拍)'
,
`danger_type_name`
varchar
(
255
)
DEFAULT
NULL
COMMENT
'隐患类型名称'
,
`danger_type_name`
varchar
(
255
)
DEFAULT
NULL
COMMENT
'隐患类型名称'
,
`danger_level`
varchar
(
20
)
DEFAULT
NULL
COMMENT
'隐患等级(1:一般隐患;2:重大隐患) '
,
`danger_level`
varchar
(
20
)
DEFAULT
NULL
COMMENT
'隐患等级(1:一般隐患;2:重大隐患) '
,
`danger_level_name`
varchar
(
255
)
CHARACTER
SET
utf8mb4
COLLATE
utf8mb4_0900_ai_ci
DEFAULT
NULL
COMMENT
'隐患等级名称'
,
`discovery_date`
datetime
DEFAULT
NULL
COMMENT
'隐患提交时间'
,
`discovery_date`
datetime
DEFAULT
NULL
COMMENT
'隐患提交时间'
,
`deal_state`
tinyint
(
4
)
NOT
NULL
COMMENT
'处理状态:1-未完成;2-已完成'
,
`deal_state`
tinyint
(
4
)
NOT
NULL
COMMENT
'处理状态:1-未完成;2-已完成'
,
`deal_date`
datetime
DEFAULT
NULL
COMMENT
'治理日期'
,
`deal_date`
datetime
DEFAULT
NULL
COMMENT
'治理日期'
,
...
@@ -168,6 +198,21 @@ CREATE TABLE `asf_fire_latent_danger` (
...
@@ -168,6 +198,21 @@ CREATE TABLE `asf_fire_latent_danger` (
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8mb4
COLLATE
=
utf8mb4_0900_ai_ci
COMMENT
=
'隐患信息'
;
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8mb4
COLLATE
=
utf8mb4_0900_ai_ci
COMMENT
=
'隐患信息'
;
-- ----------------------------
-- ----------------------------
-- Records of asf_fire_latent_danger
-- ----------------------------
INSERT
INTO
`asf_fire_latent_danger`
VALUES
(
'101'
,
'101'
,
'换流站1'
,
'10101'
,
'隐患1'
,
'1'
,
'待评审'
,
'2'
,
'巡检隐患'
,
'1'
,
'一般隐患'
,
'2021-11-10 11:06:42'
,
'1'
,
null
,
'2021-11-10 11:06:47'
,
null
,
null
,
'2021-11-11 10:08:26'
);
INSERT
INTO
`asf_fire_latent_danger`
VALUES
(
'102'
,
'102'
,
'换流站2'
,
'10102'
,
'隐患1'
,
'2'
,
'待治理'
,
'2'
,
'巡检隐患'
,
'1'
,
'一般隐患'
,
'2021-11-09 11:06:42'
,
'1'
,
null
,
'2021-11-10 11:06:47'
,
null
,
null
,
'2021-11-11 17:29:26'
);
INSERT
INTO
`asf_fire_latent_danger`
VALUES
(
'103'
,
'101'
,
'换流站1'
,
'10103'
,
'隐患1'
,
'4'
,
'待验证'
,
'2'
,
'巡检隐患'
,
'1'
,
'一般隐患'
,
'2021-11-04 11:06:42'
,
'1'
,
null
,
'2021-11-10 11:06:47'
,
null
,
null
,
'2021-11-11 17:31:36'
);
INSERT
INTO
`asf_fire_latent_danger`
VALUES
(
'104'
,
'101'
,
'换流站1'
,
'10104'
,
'隐患1'
,
'5'
,
'治理完毕'
,
'2'
,
'巡检隐患'
,
'1'
,
'一般隐患'
,
'2021-11-09 11:06:42'
,
'1'
,
null
,
'2021-11-10 11:06:47'
,
null
,
null
,
'2021-11-11 17:31:44'
);
INSERT
INTO
`asf_fire_latent_danger`
VALUES
(
'105'
,
'101'
,
'换流站1'
,
'10105'
,
'隐患1'
,
'6'
,
'已撤销'
,
'2'
,
'巡检隐患'
,
'1'
,
'一般隐患'
,
'2021-11-08 11:06:42'
,
'1'
,
null
,
'2021-11-10 11:06:47'
,
null
,
null
,
'2021-11-11 17:32:00'
);
INSERT
INTO
`asf_fire_latent_danger`
VALUES
(
'106'
,
'101'
,
'换流站1'
,
'10106'
,
'隐患1'
,
'7'
,
'延期治理中'
,
'2'
,
'巡检隐患'
,
'1'
,
'一般隐患'
,
'2021-11-07 11:06:42'
,
'1'
,
null
,
'2021-11-10 11:06:47'
,
null
,
null
,
'2021-11-11 17:32:14'
);
INSERT
INTO
`asf_fire_latent_danger`
VALUES
(
'107'
,
'101'
,
'换流站1'
,
'10107'
,
'隐患1'
,
'2'
,
'待治理'
,
'2'
,
'巡检隐患'
,
'1'
,
'一般隐患'
,
'2021-11-06 11:06:42'
,
'1'
,
null
,
'2021-11-10 11:06:47'
,
null
,
null
,
'2021-11-11 17:33:30'
);
INSERT
INTO
`asf_fire_latent_danger`
VALUES
(
'108'
,
'101'
,
'换流站1'
,
'10108'
,
'隐患1'
,
'1'
,
'待评审'
,
'2'
,
'巡检隐患'
,
'1'
,
'一般隐患'
,
'2021-11-04 11:06:42'
,
'1'
,
null
,
'2021-11-10 11:06:47'
,
null
,
null
,
'2021-11-11 10:08:53'
);
INSERT
INTO
`asf_fire_latent_danger`
VALUES
(
'109'
,
'101'
,
'换流站1'
,
'10109'
,
'隐患1'
,
'1'
,
'待评审'
,
'2'
,
'巡检隐患'
,
'1'
,
'一般隐患'
,
'2021-11-02 11:06:42'
,
'1'
,
null
,
'2021-11-10 11:06:47'
,
null
,
null
,
'2021-11-11 10:08:55'
);
INSERT
INTO
`asf_fire_latent_danger`
VALUES
(
'110'
,
'101'
,
'换流站1'
,
'10110'
,
'隐患1'
,
'1'
,
'待评审'
,
'2'
,
'巡检隐患'
,
'1'
,
'一般隐患'
,
'2021-11-01 11:06:42'
,
'1'
,
null
,
'2021-11-10 11:06:47'
,
null
,
null
,
'2021-11-11 10:08:57'
);
INSERT
INTO
`asf_fire_latent_danger`
VALUES
(
'111'
,
'101'
,
'换流站1'
,
'10111'
,
'隐患1'
,
'1'
,
'待评审'
,
'2'
,
'巡检隐患'
,
'1'
,
'一般隐患'
,
'2021-11-05 11:06:42'
,
'1'
,
null
,
'2021-11-10 11:06:47'
,
null
,
null
,
'2021-11-11 10:09:01'
);
-- ----------------------------
-- Table structure for asf_fire_risk_source
-- Table structure for asf_fire_risk_source
-- ----------------------------
-- ----------------------------
DROP
TABLE
IF
EXISTS
`asf_fire_risk_source`
;
DROP
TABLE
IF
EXISTS
`asf_fire_risk_source`
;
...
@@ -193,6 +238,10 @@ CREATE TABLE `asf_fire_risk_source` (
...
@@ -193,6 +238,10 @@ CREATE TABLE `asf_fire_risk_source` (
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8mb4
COLLATE
=
utf8mb4_0900_ai_ci
ROW_FORMAT
=
DYNAMIC
COMMENT
=
'风险点表'
;
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8mb4
COLLATE
=
utf8mb4_0900_ai_ci
ROW_FORMAT
=
DYNAMIC
COMMENT
=
'风险点表'
;
-- ----------------------------
-- ----------------------------
-- Records of asf_fire_risk_source
-- ----------------------------
-- ----------------------------
-- Table structure for asf_fire_rpn_change_log
-- Table structure for asf_fire_rpn_change_log
-- ----------------------------
-- ----------------------------
DROP
TABLE
IF
EXISTS
`asf_fire_rpn_change_log`
;
DROP
TABLE
IF
EXISTS
`asf_fire_rpn_change_log`
;
...
@@ -213,6 +262,10 @@ CREATE TABLE `asf_fire_rpn_change_log` (
...
@@ -213,6 +262,10 @@ CREATE TABLE `asf_fire_rpn_change_log` (
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8mb4
COLLATE
=
utf8mb4_0900_ai_ci
COMMENT
=
'风险点变化流水'
;
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8mb4
COLLATE
=
utf8mb4_0900_ai_ci
COMMENT
=
'风险点变化流水'
;
-- ----------------------------
-- ----------------------------
-- Records of asf_fire_rpn_change_log
-- ----------------------------
-- ----------------------------
-- Table structure for asf_fire_station_info
-- Table structure for asf_fire_station_info
-- ----------------------------
-- ----------------------------
DROP
TABLE
IF
EXISTS
`asf_fire_station_info`
;
DROP
TABLE
IF
EXISTS
`asf_fire_station_info`
;
...
@@ -224,6 +277,7 @@ CREATE TABLE `asf_fire_station_info` (
...
@@ -224,6 +277,7 @@ CREATE TABLE `asf_fire_station_info` (
`use_type_name`
varchar
(
255
)
CHARACTER
SET
utf8mb4
COLLATE
utf8mb4_0900_ai_ci
DEFAULT
NULL
COMMENT
'用途类型'
,
`use_type_name`
varchar
(
255
)
CHARACTER
SET
utf8mb4
COLLATE
utf8mb4_0900_ai_ci
DEFAULT
NULL
COMMENT
'用途类型'
,
`safety_index`
decimal
(
4
,
1
)
DEFAULT
NULL
COMMENT
'安全指数'
,
`safety_index`
decimal
(
4
,
1
)
DEFAULT
NULL
COMMENT
'安全指数'
,
`safety_status`
tinyint
(
4
)
DEFAULT
NULL
COMMENT
'安全状态:1-重大风险、2-较大风险、3-一般风险、4-低风险'
,
`safety_status`
tinyint
(
4
)
DEFAULT
NULL
COMMENT
'安全状态:1-重大风险、2-较大风险、3-一般风险、4-低风险'
,
`safety_status_name`
varchar
(
255
)
CHARACTER
SET
utf8mb4
COLLATE
utf8mb4_0900_ai_ci
DEFAULT
NULL
COMMENT
'安全状态名称'
,
`safety_status_color`
varchar
(
20
)
CHARACTER
SET
utf8mb4
COLLATE
utf8mb4_0900_ai_ci
DEFAULT
NULL
COMMENT
'状态对应颜色'
,
`safety_status_color`
varchar
(
20
)
CHARACTER
SET
utf8mb4
COLLATE
utf8mb4_0900_ai_ci
DEFAULT
NULL
COMMENT
'状态对应颜色'
,
`status`
bit
(
1
)
NOT
NULL
DEFAULT
b
'0'
COMMENT
'0-启用;1-停用'
,
`status`
bit
(
1
)
NOT
NULL
DEFAULT
b
'0'
COMMENT
'0-启用;1-停用'
,
`position`
varchar
(
255
)
DEFAULT
NULL
COMMENT
'位置描述'
,
`position`
varchar
(
255
)
DEFAULT
NULL
COMMENT
'位置描述'
,
...
@@ -235,13 +289,29 @@ CREATE TABLE `asf_fire_station_info` (
...
@@ -235,13 +289,29 @@ CREATE TABLE `asf_fire_station_info` (
`safety_person_phone`
varchar
(
20
)
DEFAULT
NULL
COMMENT
'安全负责人联系电话'
,
`safety_person_phone`
varchar
(
20
)
DEFAULT
NULL
COMMENT
'安全负责人联系电话'
,
`create_date`
datetime
DEFAULT
CURRENT_TIMESTAMP
COMMENT
'创建日期'
,
`create_date`
datetime
DEFAULT
CURRENT_TIMESTAMP
COMMENT
'创建日期'
,
`syn_date`
datetime
DEFAULT
CURRENT_TIMESTAMP
ON
UPDATE
CURRENT_TIMESTAMP
COMMENT
'同步日期'
,
`syn_date`
datetime
DEFAULT
CURRENT_TIMESTAMP
ON
UPDATE
CURRENT_TIMESTAMP
COMMENT
'同步日期'
,
`fire_captain_phone`
varchar
(
20
)
CHARACTER
SET
utf8mb4
COLLATE
utf8mb4_0900_ai_ci
DEFAULT
NULL
COMMENT
'驻站消防队队长电话'
,
`fire_captain_person`
varchar
(
50
)
CHARACTER
SET
utf8mb4
COLLATE
utf8mb4_0900_ai_ci
DEFAULT
NULL
COMMENT
'驻站消防队队长名称'
,
`fire_captain_person`
varchar
(
50
)
CHARACTER
SET
utf8mb4
COLLATE
utf8mb4_0900_ai_ci
DEFAULT
NULL
COMMENT
'驻站消防队队长名称'
,
`fire_captain_phone`
varchar
(
20
)
CHARACTER
SET
utf8mb4
COLLATE
utf8mb4_0900_ai_ci
DEFAULT
NULL
COMMENT
'驻站消防队队长电话'
,
PRIMARY
KEY
(
`id`
)
USING
BTREE
,
PRIMARY
KEY
(
`id`
)
USING
BTREE
,
UNIQUE
KEY
`uniq_code`
(
`code`
)
USING
BTREE
UNIQUE
KEY
`uniq_code`
(
`code`
)
USING
BTREE
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8mb4
COLLATE
=
utf8mb4_0900_ai_ci
COMMENT
=
'站端信息表'
;
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8mb4
COLLATE
=
utf8mb4_0900_ai_ci
COMMENT
=
'站端信息表'
;
-- ----------------------------
-- ----------------------------
-- Records of asf_fire_station_info
-- ----------------------------
INSERT
INTO
`asf_fire_station_info`
VALUES
(
'1'
,
'复龙换流站'
,
'101'
,
'输电'
,
'公用换流变电站'
,
'90.1'
,
'3'
,
'一般风险'
,
'yellow'
,
'
\0
'
,
null
,
'104.414832500'
,
'28.5443453333'
,
'张三风'
,
'17792961611'
,
'姚明'
,
'17792961621'
,
'2021-11-10 10:37:18'
,
'2021-11-10 16:15:46'
,
'队长'
,
'177936945612'
);
INSERT
INTO
`asf_fire_station_info`
VALUES
(
'10'
,
'中州换流站'
,
'110'
,
'输电'
,
'公用换流变电站'
,
'92.8'
,
'3'
,
'一般风险'
,
'blue'
,
'
\0
'
,
null
,
'113.625351'
,
'34.746303'
,
'张三风'
,
'17792961611'
,
'姚明'
,
'17792961621'
,
'2021-11-10 10:37:18'
,
'2021-11-10 15:36:49'
,
'队长'
,
'177936945612'
);
INSERT
INTO
`asf_fire_station_info`
VALUES
(
'11'
,
'龙泉换流站'
,
'111'
,
'输电'
,
'公用换流变电站'
,
'90.1'
,
'3'
,
'一般风险'
,
'yellow'
,
'
\0
'
,
null
,
'119.14126'
,
'28.074916'
,
'张三风'
,
'17792961611'
,
'姚明'
,
'17792961621'
,
'2021-11-10 10:37:18'
,
'2021-11-10 15:37:42'
,
'队长'
,
'177936945612'
);
INSERT
INTO
`asf_fire_station_info`
VALUES
(
'12'
,
'政平换流站'
,
'112'
,
'输电'
,
'公用换流变电站'
,
'90.1'
,
'3'
,
'一般风险'
,
'yellow'
,
'
\0
'
,
null
,
'117.419823'
,
'25.290481'
,
'张三风'
,
'17792961611'
,
'姚明'
,
'17792961621'
,
'2021-11-10 10:37:18'
,
'2021-11-10 15:38:14'
,
'队长'
,
'177936945612'
);
INSERT
INTO
`asf_fire_station_info`
VALUES
(
'2'
,
'金华换流站'
,
'102'
,
'输电'
,
'公用换流变电站'
,
'30.0'
,
'1'
,
'重大风险'
,
'red'
,
'
\0
'
,
null
,
'119.647265'
,
'29.079195'
,
'张三风'
,
'17792961611'
,
'姚明'
,
'17792961621'
,
'2021-11-10 10:37:18'
,
'2021-11-10 15:38:39'
,
'队长'
,
'177936945612'
);
INSERT
INTO
`asf_fire_station_info`
VALUES
(
'3'
,
'锦屏换流站'
,
'103'
,
'输电'
,
'公用换流变电站'
,
'85.0'
,
'2'
,
'较大风险'
,
'orange'
,
'
\0
'
,
null
,
'116.042546'
,
'39.878325'
,
'张三风'
,
'17792961611'
,
'姚明'
,
'17792961621'
,
'2021-11-10 10:37:18'
,
'2021-11-10 15:39:09'
,
'队长'
,
'177936945612'
);
INSERT
INTO
`asf_fire_station_info`
VALUES
(
'4'
,
'苏州换流站'
,
'104'
,
'输电'
,
'公用换流变电站'
,
'96.0'
,
'4'
,
'较低风险'
,
'blue'
,
'
\0
'
,
null
,
'120.585294'
,
'31.299758'
,
'张三风'
,
'17792961611'
,
'姚明'
,
'17792961621'
,
'2021-11-10 10:37:18'
,
'2021-11-10 15:39:31'
,
'队长'
,
'177936945612'
);
INSERT
INTO
`asf_fire_station_info`
VALUES
(
'5'
,
'灵州换流站'
,
'105'
,
'输电'
,
'公用换流变电站'
,
'90.1'
,
'3'
,
'一般风险'
,
'blue'
,
'
\0
'
,
null
,
'114.990321'
,
'38.516746'
,
'张三风'
,
'17792961611'
,
'姚明'
,
'17792961621'
,
'2021-11-10 10:37:18'
,
'2021-11-10 15:39:52'
,
'队长'
,
'177936945612'
);
INSERT
INTO
`asf_fire_station_info`
VALUES
(
'6'
,
'绍兴换流站'
,
'106'
,
'输电'
,
'公用换流变电站'
,
'92.3'
,
'3'
,
'一般风险'
,
'blue'
,
'
\0
'
,
null
,
'120.22120'
,
'29.94020'
,
'张三风'
,
'17792961611'
,
'姚明'
,
'17792961621'
,
'2021-11-10 10:37:18'
,
'2021-11-12 09:40:44'
,
'队长'
,
'177936945612'
);
INSERT
INTO
`asf_fire_station_info`
VALUES
(
'7'
,
'祁连换流站'
,
'107'
,
'输电'
,
'公用换流变电站'
,
'91.6'
,
'3'
,
'一般风险'
,
'blue'
,
'
\0
'
,
null
,
'121.614786'
,
'38.913962'
,
'张三风'
,
'17792961611'
,
'姚明'
,
'17792961621'
,
'2021-11-10 10:37:18'
,
'2021-11-10 15:40:35'
,
'队长'
,
'177936945612'
);
INSERT
INTO
`asf_fire_station_info`
VALUES
(
'8'
,
'韶山换流站'
,
'108'
,
'输电'
,
'公用换流变电站'
,
'92.8'
,
'3'
,
'一般风险'
,
'blue'
,
'
\0
'
,
null
,
'112.525364'
,
'27.914796'
,
'张三风'
,
'17792961611'
,
'姚明'
,
'17792961621'
,
'2021-11-10 10:37:18'
,
'2021-11-10 15:58:02'
,
'队长'
,
'177936945612'
);
INSERT
INTO
`asf_fire_station_info`
VALUES
(
'9'
,
'天山换流站'
,
'109'
,
'输电'
,
'公用换流变电站'
,
'92.8'
,
'3'
,
'一般风险'
,
'blue'
,
'
\0
'
,
null
,
'116.111818'
,
'40.003718'
,
'张三风'
,
'17792961611'
,
'姚明'
,
'17792961621'
,
'2021-11-10 10:37:18'
,
'2021-11-10 15:41:25'
,
'队长'
,
'177936945612'
);
-- ----------------------------
-- Table structure for ast_fire_building
-- Table structure for ast_fire_building
-- ----------------------------
-- ----------------------------
DROP
TABLE
IF
EXISTS
`ast_fire_building`
;
DROP
TABLE
IF
EXISTS
`ast_fire_building`
;
...
@@ -253,7 +323,9 @@ CREATE TABLE `ast_fire_building` (
...
@@ -253,7 +323,9 @@ CREATE TABLE `ast_fire_building` (
`name`
varchar
(
255
)
DEFAULT
NULL
COMMENT
'名称'
,
`name`
varchar
(
255
)
DEFAULT
NULL
COMMENT
'名称'
,
`classify`
varchar
(
100
)
CHARACTER
SET
utf8mb4
COLLATE
utf8mb4_0900_ai_ci
DEFAULT
NULL
COMMENT
'建筑类别'
,
`classify`
varchar
(
100
)
CHARACTER
SET
utf8mb4
COLLATE
utf8mb4_0900_ai_ci
DEFAULT
NULL
COMMENT
'建筑类别'
,
`floor_number`
varchar
(
32
)
DEFAULT
NULL
COMMENT
'楼层数量'
,
`floor_number`
varchar
(
32
)
DEFAULT
NULL
COMMENT
'楼层数量'
,
`equipment_number`
int
(
11
)
DEFAULT
NULL
COMMENT
'包含装备数量'
,
`parent_mrid`
varchar
(
32
)
CHARACTER
SET
utf8mb4
COLLATE
utf8mb4_0900_ai_ci
DEFAULT
NULL
COMMENT
'父级mrid'
,
`parent_mrid`
varchar
(
32
)
CHARACTER
SET
utf8mb4
COLLATE
utf8mb4_0900_ai_ci
DEFAULT
NULL
COMMENT
'父级mrid'
,
`tree_mrids`
text
CHARACTER
SET
utf8mb4
COLLATE
utf8mb4_0900_ai_ci
COMMENT
'树形mrids,包括自己,冗余用于树形查询'
,
`type`
varchar
(
20
)
DEFAULT
NULL
COMMENT
'类型(建筑、楼层、房间)'
,
`type`
varchar
(
20
)
DEFAULT
NULL
COMMENT
'类型(建筑、楼层、房间)'
,
`photo_url`
text
COMMENT
'建筑图片'
,
`photo_url`
text
COMMENT
'建筑图片'
,
`lng`
varchar
(
20
)
DEFAULT
NULL
COMMENT
'经度'
,
`lng`
varchar
(
20
)
DEFAULT
NULL
COMMENT
'经度'
,
...
@@ -265,6 +337,21 @@ CREATE TABLE `ast_fire_building` (
...
@@ -265,6 +337,21 @@ CREATE TABLE `ast_fire_building` (
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8mb4
COLLATE
=
utf8mb4_0900_ai_ci
COMMENT
=
'消防建筑表'
;
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8mb4
COLLATE
=
utf8mb4_0900_ai_ci
COMMENT
=
'消防建筑表'
;
-- ----------------------------
-- ----------------------------
-- Records of ast_fire_building
-- ----------------------------
INSERT
INTO
`ast_fire_building`
VALUES
(
'12101'
,
'101'
,
'复龙换流站'
,
'1301'
,
'建筑1'
,
'高层厂房'
,
'5'
,
'1805'
,
'0'
,
'1301'
,
'building'
,
null
,
'104.414832500'
,
'28.5443453333'
,
'2021-11-08 10:34:03'
,
'2021-11-11 14:58:25'
);
INSERT
INTO
`ast_fire_building`
VALUES
(
'12102'
,
'101'
,
'复龙换流站'
,
'1302'
,
'建筑2'
,
'高层厂房'
,
'6'
,
'1806'
,
'0'
,
'1302'
,
'building'
,
null
,
'113.625351'
,
'34.746303'
,
'2021-11-10 10:34:03'
,
'2021-11-11 14:58:29'
);
INSERT
INTO
`ast_fire_building`
VALUES
(
'12103'
,
'101'
,
'复龙换流站'
,
'1303'
,
'建筑3'
,
'高层厂房'
,
'7'
,
'1807'
,
'0'
,
'1303'
,
'building'
,
null
,
'119.14126'
,
'28.074916'
,
'2021-11-10 10:34:03'
,
'2021-11-11 14:58:33'
);
INSERT
INTO
`ast_fire_building`
VALUES
(
'12104'
,
'101'
,
'复龙换流站'
,
'130101'
,
'楼层1'
,
'高层厂房'
,
'0'
,
'1800'
,
'1301'
,
'1301,130101'
,
'floor'
,
null
,
'117.419823'
,
'25.290481'
,
'2021-11-05 10:34:03'
,
'2021-11-11 11:14:55'
);
INSERT
INTO
`ast_fire_building`
VALUES
(
'12105'
,
'101'
,
'复龙换流站'
,
'130102'
,
'楼层2'
,
'高层厂房'
,
'0'
,
'1800'
,
'1301'
,
'1301,130102'
,
'floor'
,
null
,
'119.647265'
,
'29.079195'
,
'2021-11-09 10:34:03'
,
'2021-11-11 11:14:58'
);
INSERT
INTO
`ast_fire_building`
VALUES
(
'12106'
,
'101'
,
'复龙换流站'
,
'13010101'
,
'房间1'
,
'高层厂房'
,
'0'
,
'1800'
,
'130101'
,
'1301,130101,13010101'
,
'room'
,
null
,
'116.042546'
,
'39.878325'
,
'2021-11-05 10:34:03'
,
'2021-11-11 11:15:01'
);
INSERT
INTO
`ast_fire_building`
VALUES
(
'12107'
,
'101'
,
'复龙换流站'
,
'13010201'
,
'房间1'
,
'高层厂房'
,
'0'
,
'1800'
,
'130102'
,
'1301,130102,13010201'
,
'room'
,
null
,
'120.585294'
,
'31.299758'
,
'2021-11-01 10:34:03'
,
'2021-11-11 11:15:06'
);
INSERT
INTO
`ast_fire_building`
VALUES
(
'12108'
,
'101'
,
'复龙换流站'
,
'130201'
,
'房间1'
,
'高层厂房'
,
'0'
,
'1800'
,
'1302'
,
'1302,130201'
,
'room'
,
null
,
'114.990321'
,
'38.516746'
,
'2021-11-04 10:34:03'
,
'2021-11-11 11:15:11'
);
INSERT
INTO
`ast_fire_building`
VALUES
(
'12109'
,
'101'
,
'复龙换流站'
,
'130301'
,
'楼层1'
,
'高层厂房'
,
'0'
,
'1800'
,
'1303'
,
'1303,130301'
,
'floor'
,
null
,
'120.582886'
,
'30.051549'
,
'2021-11-05 10:34:03'
,
'2021-11-11 11:15:16'
);
INSERT
INTO
`ast_fire_building`
VALUES
(
'12110'
,
'101'
,
'复龙换流站'
,
'13030101'
,
'房间1'
,
'高层厂房'
,
'0'
,
'1800'
,
'130301'
,
'1303,130301,13030101'
,
'room'
,
null
,
'121.614786'
,
'38.913962'
,
'2021-11-05 10:34:03'
,
'2021-11-11 11:15:19'
);
INSERT
INTO
`ast_fire_building`
VALUES
(
'12111'
,
'101'
,
'复龙换流站'
,
'13030102'
,
'房间2'
,
'高层厂房'
,
'0'
,
'1800'
,
'130301'
,
'1303,130301,13030102'
,
'room'
,
null
,
'112.525364'
,
'27.914796'
,
'2021-10-28 10:34:03'
,
'2021-11-11 11:15:25'
);
-- ----------------------------
-- Table structure for ast_fire_equipment
-- Table structure for ast_fire_equipment
-- ----------------------------
-- ----------------------------
DROP
TABLE
IF
EXISTS
`ast_fire_equipment`
;
DROP
TABLE
IF
EXISTS
`ast_fire_equipment`
;
...
@@ -299,6 +386,10 @@ CREATE TABLE `ast_fire_equipment` (
...
@@ -299,6 +386,10 @@ CREATE TABLE `ast_fire_equipment` (
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8mb4
COLLATE
=
utf8mb4_0900_ai_ci
COMMENT
=
'消防设备资产'
;
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8mb4
COLLATE
=
utf8mb4_0900_ai_ci
COMMENT
=
'消防设备资产'
;
-- ----------------------------
-- ----------------------------
-- Records of ast_fire_equipment
-- ----------------------------
-- ----------------------------
-- Table structure for ast_fire_equipment_info
-- Table structure for ast_fire_equipment_info
-- ----------------------------
-- ----------------------------
DROP
TABLE
IF
EXISTS
`ast_fire_equipment_info`
;
DROP
TABLE
IF
EXISTS
`ast_fire_equipment_info`
;
...
@@ -320,6 +411,10 @@ CREATE TABLE `ast_fire_equipment_info` (
...
@@ -320,6 +411,10 @@ CREATE TABLE `ast_fire_equipment_info` (
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8mb4
COLLATE
=
utf8mb4_0900_ai_ci
COMMENT
=
'消防资产参数信息'
;
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8mb4
COLLATE
=
utf8mb4_0900_ai_ci
COMMENT
=
'消防资产参数信息'
;
-- ----------------------------
-- ----------------------------
-- Records of ast_fire_equipment_info
-- ----------------------------
-- ----------------------------
-- Table structure for ast_fire_fighting_system
-- Table structure for ast_fire_fighting_system
-- ----------------------------
-- ----------------------------
DROP
TABLE
IF
EXISTS
`ast_fire_fighting_system`
;
DROP
TABLE
IF
EXISTS
`ast_fire_fighting_system`
;
...
@@ -347,6 +442,10 @@ CREATE TABLE `ast_fire_fighting_system` (
...
@@ -347,6 +442,10 @@ CREATE TABLE `ast_fire_fighting_system` (
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8mb4
COLLATE
=
utf8mb4_0900_ai_ci
COMMENT
=
'消防系统信息'
;
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8mb4
COLLATE
=
utf8mb4_0900_ai_ci
COMMENT
=
'消防系统信息'
;
-- ----------------------------
-- ----------------------------
-- Records of ast_fire_fighting_system
-- ----------------------------
-- ----------------------------
-- Table structure for ast_fire_vehicle
-- Table structure for ast_fire_vehicle
-- ----------------------------
-- ----------------------------
DROP
TABLE
IF
EXISTS
`ast_fire_vehicle`
;
DROP
TABLE
IF
EXISTS
`ast_fire_vehicle`
;
...
@@ -382,6 +481,21 @@ CREATE TABLE `ast_fire_vehicle` (
...
@@ -382,6 +481,21 @@ CREATE TABLE `ast_fire_vehicle` (
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8mb4
COLLATE
=
utf8mb4_0900_ai_ci
COMMENT
=
'消防车辆信息'
;
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8mb4
COLLATE
=
utf8mb4_0900_ai_ci
COMMENT
=
'消防车辆信息'
;
-- ----------------------------
-- ----------------------------
-- Records of ast_fire_vehicle
-- ----------------------------
INSERT
INTO
`ast_fire_vehicle`
VALUES
(
'108'
,
'10801'
,
'复龙换流站'
,
'101'
,
'车辆1'
,
'陕99999'
,
'泡沫消防车'
,
null
,
null
,
null
,
null
,
null
,
null
,
null
,
''
,
'启动'
,
'2021-11-11 11:39:48'
,
null
,
null
,
null
,
null
,
null
,
'2021-11-11 11:39:56'
,
null
,
null
,
'2021-11-11 11:39:56'
);
INSERT
INTO
`ast_fire_vehicle`
VALUES
(
'10801'
,
'10802'
,
'复龙换流站'
,
'101'
,
'车辆2'
,
'陕99999'
,
'泡沫消防车'
,
null
,
null
,
null
,
null
,
null
,
null
,
null
,
''
,
'启动'
,
'2021-11-11 11:39:48'
,
null
,
null
,
null
,
null
,
null
,
'2021-11-11 11:42:44'
,
null
,
null
,
'2021-11-11 11:42:44'
);
INSERT
INTO
`ast_fire_vehicle`
VALUES
(
'10803'
,
'10803'
,
'复龙换流站'
,
'101'
,
'车辆3'
,
'陕99999'
,
'泡沫消防车'
,
null
,
null
,
null
,
null
,
null
,
null
,
null
,
''
,
'启动'
,
'2021-11-11 11:39:48'
,
null
,
null
,
null
,
null
,
null
,
'2021-11-11 11:42:47'
,
null
,
null
,
'2021-11-11 11:42:47'
);
INSERT
INTO
`ast_fire_vehicle`
VALUES
(
'10804'
,
'10804'
,
'复龙换流站'
,
'101'
,
'车辆4'
,
'陕99999'
,
'泡沫消防车'
,
null
,
null
,
null
,
null
,
null
,
null
,
null
,
''
,
'启动'
,
'2021-11-11 11:39:48'
,
null
,
null
,
null
,
null
,
null
,
'2021-11-11 11:42:49'
,
null
,
null
,
'2021-11-11 11:42:49'
);
INSERT
INTO
`ast_fire_vehicle`
VALUES
(
'10805'
,
'10805'
,
'复龙换流站'
,
'101'
,
'车辆5'
,
'陕99999'
,
'泡沫消防车'
,
null
,
null
,
null
,
null
,
null
,
null
,
null
,
''
,
'启动'
,
'2021-11-11 11:39:48'
,
null
,
null
,
null
,
null
,
null
,
'2021-11-11 11:42:51'
,
null
,
null
,
'2021-11-11 11:42:51'
);
INSERT
INTO
`ast_fire_vehicle`
VALUES
(
'10806'
,
'10806'
,
'复龙换流站'
,
'101'
,
'车辆6'
,
'陕99999'
,
'泡沫消防车'
,
null
,
null
,
null
,
null
,
null
,
null
,
null
,
''
,
'启动'
,
'2021-11-11 11:39:48'
,
null
,
null
,
null
,
null
,
null
,
'2021-11-11 11:42:53'
,
null
,
null
,
'2021-11-11 11:42:53'
);
INSERT
INTO
`ast_fire_vehicle`
VALUES
(
'10807'
,
'10807'
,
'复龙换流站'
,
'101'
,
'车辆7'
,
'陕99999'
,
'泡沫消防车'
,
null
,
null
,
null
,
null
,
null
,
null
,
null
,
''
,
'启动'
,
'2021-11-11 11:39:48'
,
null
,
null
,
null
,
null
,
null
,
'2021-11-11 11:42:57'
,
null
,
null
,
'2021-11-11 11:42:57'
);
INSERT
INTO
`ast_fire_vehicle`
VALUES
(
'10808'
,
'10808'
,
'复龙换流站'
,
'101'
,
'车辆8'
,
'陕99999'
,
'泡沫消防车'
,
null
,
null
,
null
,
null
,
null
,
null
,
null
,
''
,
'启动'
,
'2021-11-11 11:39:48'
,
null
,
null
,
null
,
null
,
null
,
'2021-11-11 11:43:01'
,
null
,
null
,
'2021-11-11 11:43:01'
);
INSERT
INTO
`ast_fire_vehicle`
VALUES
(
'10809'
,
'10809'
,
'复龙换流站'
,
'101'
,
'车辆9'
,
'陕99999'
,
'泡沫消防车'
,
null
,
null
,
null
,
null
,
null
,
null
,
null
,
''
,
'启动'
,
'2021-11-11 11:39:48'
,
null
,
null
,
null
,
null
,
null
,
'2021-11-11 11:43:04'
,
null
,
null
,
'2021-11-11 11:43:04'
);
INSERT
INTO
`ast_fire_vehicle`
VALUES
(
'10810'
,
'10810'
,
'复龙换流站'
,
'101'
,
'车辆10'
,
'陕99999'
,
'泡沫消防车'
,
null
,
null
,
null
,
null
,
null
,
null
,
null
,
''
,
'启动'
,
'2021-11-11 11:39:48'
,
null
,
null
,
null
,
null
,
null
,
'2021-11-11 11:43:08'
,
null
,
null
,
'2021-11-11 11:43:08'
);
INSERT
INTO
`ast_fire_vehicle`
VALUES
(
'10811'
,
'10811'
,
'复龙换流站'
,
'101'
,
'车辆1'
,
'陕99999'
,
'泡沫消防车'
,
null
,
null
,
null
,
null
,
null
,
null
,
null
,
''
,
'启动'
,
'2021-11-11 11:39:48'
,
null
,
null
,
null
,
null
,
null
,
'2021-11-11 11:39:56'
,
null
,
null
,
'2021-11-11 11:39:56'
);
-- ----------------------------
-- Table structure for ast_fire_vehicle_info
-- Table structure for ast_fire_vehicle_info
-- ----------------------------
-- ----------------------------
DROP
TABLE
IF
EXISTS
`ast_fire_vehicle_info`
;
DROP
TABLE
IF
EXISTS
`ast_fire_vehicle_info`
;
...
@@ -403,6 +517,10 @@ CREATE TABLE `ast_fire_vehicle_info` (
...
@@ -403,6 +517,10 @@ CREATE TABLE `ast_fire_vehicle_info` (
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8mb4
COLLATE
=
utf8mb4_0900_ai_ci
COMMENT
=
'消防资产参数信息'
;
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8mb4
COLLATE
=
utf8mb4_0900_ai_ci
COMMENT
=
'消防资产参数信息'
;
-- ----------------------------
-- ----------------------------
-- Records of ast_fire_vehicle_info
-- ----------------------------
-- ----------------------------
-- Table structure for ast_fire_video
-- Table structure for ast_fire_video
-- ----------------------------
-- ----------------------------
DROP
TABLE
IF
EXISTS
`ast_fire_video`
;
DROP
TABLE
IF
EXISTS
`ast_fire_video`
;
...
@@ -427,6 +545,21 @@ CREATE TABLE `ast_fire_video` (
...
@@ -427,6 +545,21 @@ CREATE TABLE `ast_fire_video` (
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8mb4
COLLATE
=
utf8mb4_0900_ai_ci
COMMENT
=
'消防视频表'
;
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8mb4
COLLATE
=
utf8mb4_0900_ai_ci
COMMENT
=
'消防视频表'
;
-- ----------------------------
-- ----------------------------
-- Records of ast_fire_video
-- ----------------------------
INSERT
INTO
`ast_fire_video`
VALUES
(
'10901'
,
'101'
,
'复龙换流站'
,
'10901'
,
'摄像头1'
,
'枪机'
,
'墙角'
,
null
,
'1301'
,
'建筑1'
,
null
,
null
,
null
,
'2021-11-11 11:50:13'
,
'2021-11-11 13:43:37'
);
INSERT
INTO
`ast_fire_video`
VALUES
(
'10902'
,
'101'
,
'复龙换流站'
,
'10902'
,
'摄像头2'
,
'枪机'
,
'墙角'
,
null
,
'1302'
,
'建筑2'
,
null
,
null
,
null
,
'2021-11-12 11:50:13'
,
'2021-11-11 14:44:22'
);
INSERT
INTO
`ast_fire_video`
VALUES
(
'10903'
,
'101'
,
'复龙换流站'
,
'10903'
,
'摄像头3'
,
'枪机'
,
'墙角'
,
null
,
'1303'
,
'建筑3'
,
null
,
null
,
null
,
'2021-11-13 11:50:13'
,
'2021-11-11 14:44:26'
);
INSERT
INTO
`ast_fire_video`
VALUES
(
'10904'
,
'101'
,
'复龙换流站'
,
'10904'
,
'摄像头4'
,
'枪机'
,
'墙角'
,
null
,
'130101'
,
'楼层1'
,
null
,
null
,
null
,
'2021-11-11 11:50:13'
,
'2021-11-11 11:52:26'
);
INSERT
INTO
`ast_fire_video`
VALUES
(
'10905'
,
'101'
,
'复龙换流站'
,
'10905'
,
'摄像头5'
,
'枪机'
,
'墙角'
,
null
,
'130102'
,
'楼层2'
,
null
,
null
,
null
,
'2021-11-11 11:50:13'
,
'2021-11-11 13:43:37'
);
INSERT
INTO
`ast_fire_video`
VALUES
(
'10906'
,
'101'
,
'复龙换流站'
,
'10906'
,
'摄像头6'
,
'枪机'
,
'墙角'
,
null
,
'13010101'
,
'房间1'
,
null
,
null
,
null
,
'2021-11-11 11:50:13'
,
'2021-11-11 13:43:37'
);
INSERT
INTO
`ast_fire_video`
VALUES
(
'10907'
,
'101'
,
'复龙换流站'
,
'10907'
,
'摄像头7'
,
'枪机'
,
'墙角'
,
null
,
'13010201'
,
'房间1'
,
null
,
null
,
null
,
'2021-11-11 11:50:13'
,
'2021-11-11 13:43:37'
);
INSERT
INTO
`ast_fire_video`
VALUES
(
'10908'
,
'101'
,
'复龙换流站'
,
'10908'
,
'摄像头8'
,
'枪机'
,
'墙角'
,
null
,
'130201'
,
'房间1'
,
null
,
null
,
null
,
'2021-11-11 11:50:13'
,
'2021-11-11 13:43:37'
);
INSERT
INTO
`ast_fire_video`
VALUES
(
'10909'
,
'101'
,
'复龙换流站'
,
'10909'
,
'摄像头9'
,
'枪机'
,
'墙角'
,
null
,
'130301'
,
'楼层1'
,
null
,
null
,
null
,
'2021-11-11 11:50:13'
,
'2021-11-11 13:43:20'
);
INSERT
INTO
`ast_fire_video`
VALUES
(
'10910'
,
'101'
,
'复龙换流站'
,
'10910'
,
'摄像头10'
,
'枪机'
,
'墙角'
,
null
,
'13030101'
,
'房间1'
,
null
,
null
,
null
,
'2021-11-11 11:50:13'
,
'2021-11-11 13:43:37'
);
INSERT
INTO
`ast_fire_video`
VALUES
(
'10911'
,
'101'
,
'复龙换流站'
,
'10911'
,
'摄像头11'
,
'枪机'
,
'墙角'
,
null
,
'13030102'
,
'房间2'
,
null
,
null
,
null
,
'2021-11-11 11:50:13'
,
'2021-11-11 13:43:38'
);
-- ----------------------------
-- Table structure for ast_fire_water
-- Table structure for ast_fire_water
-- ----------------------------
-- ----------------------------
DROP
TABLE
IF
EXISTS
`ast_fire_water`
;
DROP
TABLE
IF
EXISTS
`ast_fire_water`
;
...
@@ -451,6 +584,21 @@ CREATE TABLE `ast_fire_water` (
...
@@ -451,6 +584,21 @@ CREATE TABLE `ast_fire_water` (
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8mb4
COLLATE
=
utf8mb4_0900_ai_ci
COMMENT
=
'消防水源表'
;
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8mb4
COLLATE
=
utf8mb4_0900_ai_ci
COMMENT
=
'消防水源表'
;
-- ----------------------------
-- ----------------------------
-- Records of ast_fire_water
-- ----------------------------
INSERT
INTO
`ast_fire_water`
VALUES
(
'101'
,
'101'
,
'复龙换流站'
,
'10701'
,
'消防水池1'
,
'高层厂房'
,
'消防水池'
,
'10.2'
,
'苏慧光'
,
'17792961611'
,
null
,
'104.414832500'
,
'28.5443453333'
,
'2021-11-11 11:26:10'
,
'2021-11-11 11:29:25'
);
INSERT
INTO
`ast_fire_water`
VALUES
(
'102'
,
'101'
,
'复龙换流站'
,
'10702'
,
'消防栓1'
,
'高层厂房'
,
'消防栓'
,
'10.2'
,
'苏慧光'
,
'17792961611'
,
null
,
'113.625351'
,
'34.746303'
,
'2021-11-11 11:26:10'
,
'2021-11-11 11:29:30'
);
INSERT
INTO
`ast_fire_water`
VALUES
(
'103'
,
'101'
,
'复龙换流站'
,
'10703'
,
'消防栓2'
,
'高层厂房'
,
'消防栓'
,
'10.2'
,
'苏慧光'
,
'17792961611'
,
null
,
'119.14126'
,
'28.074916'
,
'2021-11-11 11:26:10'
,
'2021-11-11 11:29:30'
);
INSERT
INTO
`ast_fire_water`
VALUES
(
'104'
,
'101'
,
'复龙换流站'
,
'10704'
,
'消防栓3'
,
'高层厂房'
,
'消防栓'
,
'10.2'
,
'苏慧光'
,
'17792961611'
,
null
,
'117.419823'
,
'25.290481'
,
'2021-11-11 11:26:10'
,
'2021-11-11 11:29:30'
);
INSERT
INTO
`ast_fire_water`
VALUES
(
'105'
,
'101'
,
'复龙换流站'
,
'10705'
,
'消防水鹤1'
,
'高层厂房'
,
'消防水鹤'
,
'10.2'
,
'苏慧光'
,
'17792961611'
,
null
,
'119.647265'
,
'29.079195'
,
'2021-11-11 11:26:10'
,
'2021-11-11 11:29:30'
);
INSERT
INTO
`ast_fire_water`
VALUES
(
'106'
,
'101'
,
'复龙换流站'
,
'10706'
,
'消防水鹤2'
,
'高层厂房'
,
'消防水鹤'
,
'10.2'
,
'苏慧光'
,
'17792961611'
,
null
,
'116.042546'
,
'39.878325'
,
'2021-11-11 11:26:10'
,
'2021-11-11 11:29:31'
);
INSERT
INTO
`ast_fire_water`
VALUES
(
'107'
,
'101'
,
'复龙换流站'
,
'10707'
,
'消防水鹤3'
,
'高层厂房'
,
'消防水鹤'
,
'10.2'
,
'苏慧光'
,
'17792961611'
,
null
,
'120.585294'
,
'31.299758'
,
'2021-11-11 11:26:10'
,
'2021-11-11 11:29:31'
);
INSERT
INTO
`ast_fire_water`
VALUES
(
'108'
,
'101'
,
'复龙换流站'
,
'10708'
,
'天然水源1'
,
'高层厂房'
,
'天然水源'
,
'10.2'
,
'苏慧光'
,
'17792961611'
,
null
,
'114.990321'
,
'38.516746'
,
'2021-11-11 11:26:10'
,
'2021-11-11 11:29:31'
);
INSERT
INTO
`ast_fire_water`
VALUES
(
'109'
,
'101'
,
'复龙换流站'
,
'10709'
,
'天然水源2'
,
'高层厂房'
,
'天然水源'
,
'10.2'
,
'苏慧光'
,
'17792961611'
,
null
,
'120.582886'
,
'30.051549'
,
'2021-11-11 11:26:10'
,
'2021-11-11 11:29:31'
);
INSERT
INTO
`ast_fire_water`
VALUES
(
'110'
,
'101'
,
'复龙换流站'
,
'10710'
,
'天然水源3'
,
'高层厂房'
,
'天然水源'
,
'10.2'
,
'苏慧光'
,
'17792961611'
,
null
,
'121.614786'
,
'38.913962'
,
'2021-11-11 11:26:10'
,
'2021-11-11 11:29:31'
);
INSERT
INTO
`ast_fire_water`
VALUES
(
'111'
,
'101'
,
'复龙换流站'
,
'10711'
,
'天然水源4'
,
'高层厂房'
,
'天然水源'
,
'10.2'
,
'苏慧光'
,
'17792961611'
,
null
,
'112.525364'
,
'27.914796'
,
'2021-11-11 11:26:10'
,
'2021-11-11 11:29:31'
);
-- ----------------------------
-- Table structure for DATABASECHANGELOG
-- Table structure for DATABASECHANGELOG
-- ----------------------------
-- ----------------------------
DROP
TABLE
IF
EXISTS
`DATABASECHANGELOG`
;
DROP
TABLE
IF
EXISTS
`DATABASECHANGELOG`
;
...
@@ -472,6 +620,10 @@ CREATE TABLE `DATABASECHANGELOG` (
...
@@ -472,6 +620,10 @@ CREATE TABLE `DATABASECHANGELOG` (
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8mb4
COLLATE
=
utf8mb4_0900_ai_ci
;
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8mb4
COLLATE
=
utf8mb4_0900_ai_ci
;
-- ----------------------------
-- ----------------------------
-- Records of DATABASECHANGELOG
-- ----------------------------
-- ----------------------------
-- Table structure for DATABASECHANGELOGLOCK
-- Table structure for DATABASECHANGELOGLOCK
-- ----------------------------
-- ----------------------------
DROP
TABLE
IF
EXISTS
`DATABASECHANGELOGLOCK`
;
DROP
TABLE
IF
EXISTS
`DATABASECHANGELOGLOCK`
;
...
@@ -482,4 +634,9 @@ CREATE TABLE `DATABASECHANGELOGLOCK` (
...
@@ -482,4 +634,9 @@ CREATE TABLE `DATABASECHANGELOGLOCK` (
`LOCKEDBY`
varchar
(
255
)
DEFAULT
NULL
,
`LOCKEDBY`
varchar
(
255
)
DEFAULT
NULL
,
PRIMARY
KEY
(
`ID`
)
PRIMARY
KEY
(
`ID`
)
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8mb4
COLLATE
=
utf8mb4_0900_ai_ci
;
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8mb4
COLLATE
=
utf8mb4_0900_ai_ci
;
SET
FOREIGN_KEY_CHECKS
=
1
;
\ No newline at end of file
-- ----------------------------
-- Records of DATABASECHANGELOGLOCK
-- ----------------------------
INSERT
INTO
`DATABASECHANGELOGLOCK`
VALUES
(
'1'
,
'
\0
'
,
null
,
null
);
SET
FOREIGN_KEY_CHECKS
=
1
;
amos-boot-system-tzs/src/main/java/com/yeejoin/amos/AmosTzsApplication.java
View file @
3eec8871
...
@@ -42,8 +42,7 @@ import java.net.UnknownHostException;
...
@@ -42,8 +42,7 @@ import java.net.UnknownHostException;
"org.typroject.tyboot.face.*.orm.dao*"
,
"org.typroject.tyboot.face.*.orm.dao*"
,
"org.typroject.tyboot.core.auth.face.orm.dao*"
,
"org.typroject.tyboot.core.auth.face.orm.dao*"
,
"org.typroject.tyboot.component.*.face.orm.dao*"
,
"org.typroject.tyboot.component.*.face.orm.dao*"
,
"com.yeejoin.amos.boot.module.*.api.mapper"
,
"com.yeejoin.amos.boot.module.**.api.mapper"
,
"com.yeejoin.amos.boot.module.*.*.api.mapper"
,
"com.yeejoin.amos.boot.biz.common.dao.mapper"
})
"com.yeejoin.amos.boot.biz.common.dao.mapper"
})
@ComponentScan
(
basePackages
=
{
"org.typroject"
,
"com.yeejoin.amos"
})
@ComponentScan
(
basePackages
=
{
"org.typroject"
,
"com.yeejoin.amos"
})
public
class
AmosTzsApplication
{
public
class
AmosTzsApplication
{
...
...
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