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
a3d2aa39
Commit
a3d2aa39
authored
Dec 30, 2022
by
tianyiming
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
直流中心bug修改
parent
16127e5c
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
107 additions
and
0 deletions
+107
-0
DCenterController.java
...com/yeejoin/equipmanage/controller/DCenterController.java
+38
-0
EquipmentSpecificAlarmMapper.java
...join/equipmanage/mapper/EquipmentSpecificAlarmMapper.java
+2
-0
IEquipmentSpecificAlarmService.java
...n/equipmanage/service/IEquipmentSpecificAlarmService.java
+3
-0
EquipmentSpecificAlarmServiceImpl.java
...anage/service/impl/EquipmentSpecificAlarmServiceImpl.java
+10
-0
EquipmentSpecificAlarmMapper.xml
...rc/main/resources/mapper/EquipmentSpecificAlarmMapper.xml
+54
-0
No files found.
amos-boot-module/amos-boot-module-biz/amos-boot-module-equip-biz/src/main/java/com/yeejoin/equipmanage/controller/DCenterController.java
View file @
a3d2aa39
...
...
@@ -15,6 +15,7 @@ import io.swagger.annotations.ApiOperation;
import
org.apache.commons.lang3.StringUtils
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.http.MediaType
;
import
org.springframework.util.ObjectUtils
;
import
org.springframework.web.bind.annotation.*
;
import
org.typroject.tyboot.core.foundation.enumeration.UserType
;
import
org.typroject.tyboot.core.foundation.utils.ValidationUtil
;
...
...
@@ -74,6 +75,43 @@ public class DCenterController extends AbstractBaseController {
return
CommonResponseUtil
.
success
(
list
);
}
@PersonIdentify
@RequestMapping
(
value
=
"/station-info"
,
method
=
RequestMethod
.
GET
)
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"站点信息查询"
,
produces
=
"application/json;charset=UTF-8"
,
notes
=
"站点信息查询"
)
public
ResponseModel
stationInfo
()
{
return
CommonResponseUtil
.
success
(
equipmentSpecificAlarmService
.
stationInfo
());
}
@PersonIdentify
@RequestMapping
(
value
=
"/fireAlarmLogPage"
,
method
=
RequestMethod
.
GET
)
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"消防报警列表分页查询"
,
produces
=
"application/json;charset=UTF-8"
,
notes
=
"消防报警列表分页查询"
)
public
ResponseModel
pageQuery
(
@RequestParam
(
required
=
false
)
String
code
,
@RequestParam
(
required
=
false
)
String
typeCode
,
@RequestParam
(
required
=
false
)
String
bizOrgCode
,
CommonPageable
commonPageable
)
{
if
(
commonPageable
.
getPageNumber
()
==
0
)
{
commonPageable
.
setPageNumber
(
1
);
}
ReginParams
reginParams
=
getSelectedOrgInfo
();
List
<
CommonRequest
>
queryRequests
=
new
ArrayList
<>();
CommonRequest
request7
=
new
CommonRequest
();
request7
.
setName
(
"system"
);
request7
.
setValue
(
StringUtil
.
isNotEmpty
(
code
)
?
StringUtils
.
trimToNull
(
code
)
:
null
);
queryRequests
.
add
(
request7
);
CommonRequest
request8
=
new
CommonRequest
();
request8
.
setName
(
"specificIndexKey"
);
request8
.
setValue
(
StringUtil
.
isNotEmpty
(
typeCode
)
?
StringUtils
.
trimToNull
(
typeCode
)
:
null
);
queryRequests
.
add
(
request8
);
CommonRequest
request13
=
new
CommonRequest
();
request13
.
setName
(
"bizOrgCode"
);
request13
.
setValue
(
ObjectUtils
.
isEmpty
(
bizOrgCode
)
?
reginParams
.
getPersonIdentity
().
getBizOrgCode
()
:
bizOrgCode
);
queryRequests
.
add
(
request13
);
CommonPageInfoParam
param
=
CommonPageParamUtil
.
fillCommonPageInfoParam
(
queryRequests
,
commonPageable
);
return
CommonResponseUtil
.
success
(
equipmentSpecificAlarmService
.
dcFireAlarmLogPage
(
param
));
}
/**
* 消防系统运行状态分页查询
* @param bizOrgCode
...
...
amos-boot-module/amos-boot-module-biz/amos-boot-module-equip-biz/src/main/java/com/yeejoin/equipmanage/mapper/EquipmentSpecificAlarmMapper.java
View file @
a3d2aa39
...
...
@@ -223,6 +223,8 @@ public interface EquipmentSpecificAlarmMapper extends BaseMapper<EquipmentSpecif
,
@Param
(
"endTime"
)
String
endTime
);
Page
<
Map
<
String
,
Object
>>
fireAlarmLogPage
(
Page
page
,
@Param
(
"param"
)
CommonPageInfoParam
param
);
Page
<
Map
<
String
,
Object
>>
dcFireAlarmLogPage
(
Page
page
,
@Param
(
"param"
)
CommonPageInfoParam
param
);
List
<
Map
<
String
,
Object
>>
alarmTrend
(
String
bizOrgCode
);
List
<
Map
<
String
,
Object
>>
stationInfo
();
}
amos-boot-module/amos-boot-module-biz/amos-boot-module-equip-biz/src/main/java/com/yeejoin/equipmanage/service/IEquipmentSpecificAlarmService.java
View file @
a3d2aa39
...
...
@@ -96,6 +96,9 @@ public interface IEquipmentSpecificAlarmService extends IService<EquipmentSpecif
Page
<
Map
<
String
,
Object
>>
fireAlarmLogPage
(
CommonPageInfoParam
param
);
Page
<
Map
<
String
,
Object
>>
dcFireAlarmLogPage
(
CommonPageInfoParam
param
);
List
<
Map
<
String
,
Object
>>
stationInfo
();
List
<
Map
<
String
,
Object
>>
alarmTrend
(
String
bizOrgCode
);
List
<
Map
<
String
,
Object
>>
allList
(
CommonPageInfoParam
param
);
...
...
amos-boot-module/amos-boot-module-biz/amos-boot-module-equip-biz/src/main/java/com/yeejoin/equipmanage/service/impl/EquipmentSpecificAlarmServiceImpl.java
View file @
a3d2aa39
...
...
@@ -765,9 +765,19 @@ public class EquipmentSpecificAlarmServiceImpl extends ServiceImpl<EquipmentSpec
}
@Override
public
Page
<
Map
<
String
,
Object
>>
dcFireAlarmLogPage
(
CommonPageInfoParam
param
)
{
Page
result
=
new
Page
<>(
param
.
getPageNumber
(),
param
.
getPageSize
());
return
this
.
baseMapper
.
dcFireAlarmLogPage
(
result
,
param
);
}
@Override
public
List
<
Map
<
String
,
Object
>>
alarmTrend
(
String
bizOrgCode
)
{
return
this
.
baseMapper
.
alarmTrend
(
bizOrgCode
);
}
@Override
public
List
<
Map
<
String
,
Object
>>
stationInfo
()
{
return
this
.
baseMapper
.
stationInfo
();
}
@Override
public
List
<
Map
<
String
,
Object
>>
allList
(
CommonPageInfoParam
param
)
{
...
...
amos-boot-system-equip/src/main/resources/mapper/EquipmentSpecificAlarmMapper.xml
View file @
a3d2aa39
...
...
@@ -1394,6 +1394,32 @@
ORDER BY
`wlesal`.`create_date` DESC
</select>
<select
id=
"dcFireAlarmLogPage"
resultType=
"java.util.HashMap"
>
SELECT
`wlesal`.equipment_specific_index_name type,
`wlesal`.equipment_specific_name alamContent,
DATE_FORMAT(`wlesal`.`create_date`,'%m-%d %H:%i:%s') createDate,
wlesal.location
FROM
`wl_equipment_specific_alarm_log` `wlesal`
LEFT JOIN `wl_equipment_specific_alarm` wesa ON wesa.id = wlesal.equipment_specific_alarm_id
LEFT JOIN `wl_equipment_specific` `wles` ON `wlesal`.`equipment_specific_id` = `wles`.`id`
<where>
wesa.`status` = 1
<if
test=
"param.system != null and param.system != ''"
>
AND find_in_set( #{param.system}, `wlesal`.`system_codes` )
</if>
<if
test=
"param.fireEquipmentSpecificIndexKey != null and param.fireEquipmentSpecificIndexKey != ''"
>
AND wlesal.type = #{param.fireEquipmentSpecificIndexKey}
</if>
<if
test=
"param.bizOrgCode != null and param.bizOrgCode != ''"
>
AND wlesal.biz_org_code like concat (#{param.bizOrgCode},'%')
</if>
</where>
ORDER BY
`wlesal`.`create_date` DESC
</select>
<select
id=
"alarmTrend"
resultType=
"java.util.Map"
>
SELECT
`result`.`click_date` AS `click_date`,
...
...
@@ -1479,4 +1505,31 @@
ORDER BY
`result`.`click_date`
</select>
<select
id=
"stationInfo"
resultType=
"java.util.Map"
>
SELECT
a.`name`,
a.`code`,
CASE
WHEN a.countAlarmTotal = 0 THEN
SUM( a.NAME ) ELSE count( a.`name` )
END AS alarmEquipTotal,
IFNULL( SUM( a.countAlarmTotal ), 0 ) countAlarmTotal
FROM
(
SELECT
fs.`name`,
fs.`code`,
IFNULL( sum( wesi.`status` ), 0 ) AS countAlarmTotal
FROM
idx_biz_station_info fs
LEFT JOIN wl_equipment_specific_alarm wesi ON wesi.station_code = fs.`code`
AND wesi.`status` = 1
GROUP BY
fs.id,
wesi.equipment_specific_id
) a
GROUP BY
a.`name`
</select>
</mapper>
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment