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
2856d284
Commit
2856d284
authored
Sep 19, 2024
by
张森
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
30546 运行趋势页签接口开发
parent
fb999bba
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
120 additions
and
1 deletion
+120
-1
EquipTrendInfoVo.java
...eejoin/equipmanage/common/entity/vo/EquipTrendInfoVo.java
+13
-0
EquipTrendResultVo.java
...join/equipmanage/common/entity/vo/EquipTrendResultVo.java
+14
-0
SupervisionConfigureController.java
...quipmanage/controller/SupervisionConfigureController.java
+50
-0
IotFeign.java
...src/main/java/com/yeejoin/equipmanage/fegin/IotFeign.java
+1
-1
EquipmentSpecificMapper.java
...m/yeejoin/equipmanage/mapper/EquipmentSpecificMapper.java
+1
-0
IEquipmentSpecificSerivce.java
...eejoin/equipmanage/service/IEquipmentSpecificSerivce.java
+4
-0
EquipmentSpecificSerivceImpl.java
...quipmanage/service/impl/EquipmentSpecificSerivceImpl.java
+0
-0
EquipmentSpecificMapper.xml
...uip/src/main/resources/mapper/EquipmentSpecificMapper.xml
+37
-0
No files found.
amos-boot-module/amos-boot-module-api/amos-boot-module-equip-api/src/main/java/com/yeejoin/equipmanage/common/entity/vo/EquipTrendInfoVo.java
0 → 100644
View file @
2856d284
package
com
.
yeejoin
.
equipmanage
.
common
.
entity
.
vo
;
import
lombok.Data
;
@Data
public
class
EquipTrendInfoVo
{
private
String
id
;
private
String
iotCode
;
private
String
name
;
private
String
maxNum
;
private
String
minNum
;
private
String
unit
;
}
amos-boot-module/amos-boot-module-api/amos-boot-module-equip-api/src/main/java/com/yeejoin/equipmanage/common/entity/vo/EquipTrendResultVo.java
0 → 100644
View file @
2856d284
package
com
.
yeejoin
.
equipmanage
.
common
.
entity
.
vo
;
import
lombok.Data
;
import
java.util.List
;
@Data
public
class
EquipTrendResultVo
{
private
List
<
String
>
legends
;
private
String
yAxisName
;
private
List
<
String
>
xAxisData
;
private
List
<
List
<
String
>>
yAxisData
;
private
List
<
List
<
String
>>
threshold
;
}
amos-boot-module/amos-boot-module-biz/amos-boot-module-equip-biz/src/main/java/com/yeejoin/equipmanage/controller/SupervisionConfigureController.java
View file @
2856d284
...
@@ -8,6 +8,7 @@ import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
...
@@ -8,6 +8,7 @@ import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import
com.yeejoin.amos.boot.biz.common.bo.ReginParams
;
import
com.yeejoin.amos.boot.biz.common.bo.ReginParams
;
import
com.yeejoin.equipmanage.common.entity.EquipmentSpecificIndex
;
import
com.yeejoin.equipmanage.common.entity.EquipmentSpecificIndex
;
import
com.yeejoin.equipmanage.common.entity.FormInstanceEquip
;
import
com.yeejoin.equipmanage.common.entity.FormInstanceEquip
;
import
com.yeejoin.equipmanage.common.entity.vo.EquipTrendResultVo
;
import
com.yeejoin.equipmanage.common.enums.IndexStatusEnum
;
import
com.yeejoin.equipmanage.common.enums.IndexStatusEnum
;
import
com.yeejoin.equipmanage.common.utils.*
;
import
com.yeejoin.equipmanage.common.utils.*
;
import
com.yeejoin.equipmanage.config.PersonIdentify
;
import
com.yeejoin.equipmanage.config.PersonIdentify
;
...
@@ -72,6 +73,9 @@ public class SupervisionConfigureController extends AbstractBaseController {
...
@@ -72,6 +73,9 @@ public class SupervisionConfigureController extends AbstractBaseController {
@Autowired
@Autowired
private
FormInstanceEquipMapper
formInstanceEquipMapper
;
private
FormInstanceEquipMapper
formInstanceEquipMapper
;
@Autowired
private
IEquipmentSpecificSerivce
equipmentSpecificService
;
@PersonIdentify
@PersonIdentify
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
...
@@ -823,4 +827,50 @@ public class SupervisionConfigureController extends AbstractBaseController {
...
@@ -823,4 +827,50 @@ public class SupervisionConfigureController extends AbstractBaseController {
Map
<
String
,
Object
>
list
=
supervisionVideoService
.
getPressurePumpPage
(
bizOrgCode
,
id
,
startTime
,
endTime
,
pageNum
,
pageSize
,
timeSort
,
stateSort
);
Map
<
String
,
Object
>
list
=
supervisionVideoService
.
getPressurePumpPage
(
bizOrgCode
,
id
,
startTime
,
endTime
,
pageNum
,
pageSize
,
timeSort
,
stateSort
);
return
CommonResponseUtil
.
success
(
list
);
return
CommonResponseUtil
.
success
(
list
);
}
}
@PersonIdentify
@RequestMapping
(
value
=
"/operatingTrendIot"
,
method
=
RequestMethod
.
GET
)
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"设备平台运行趋势 设备相关API"
,
produces
=
"application/json;charset=UTF-8"
,
notes
=
"设备平台运行趋势 设备相关API"
)
public
ResponseModel
operatingTrendIot
(
@RequestParam
(
value
=
"startTime"
,
required
=
false
)
String
startTime
,
@RequestParam
(
value
=
"endTime"
,
required
=
false
)
String
endTime
,
@RequestParam
(
value
=
"bizOrgCode"
,
required
=
false
)
String
bizOrgCode
,
@RequestParam
(
value
=
"equipCode"
,
required
=
false
)
String
equipCode
,
@RequestParam
(
value
=
"indexKey"
,
required
=
false
)
String
indexKey
)
{
if
(
ObjectUtils
.
isEmpty
(
bizOrgCode
))
{
ReginParams
reginParams
=
getSelectedOrgInfo
();
ReginParams
.
PersonIdentity
personIdentity
=
reginParams
.
getPersonIdentity
();
if
(!
ValidationUtil
.
isEmpty
(
personIdentity
))
{
bizOrgCode
=
personIdentity
.
getBizOrgCode
();
if
(
bizOrgCode
==
null
)
{
return
CommonResponseUtil
.
success
(
null
);
}
}
}
EquipTrendResultVo
equipTrendResultVo
=
equipmentSpecificService
.
operatingTrendIot
(
startTime
,
endTime
,
bizOrgCode
,
equipCode
,
indexKey
);
return
CommonResponseUtil
.
success
(
equipTrendResultVo
);
}
@PersonIdentify
@RequestMapping
(
value
=
"/operatingTrendWater"
,
method
=
RequestMethod
.
GET
)
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@ApiOperation
(
httpMethod
=
"GET"
,
value
=
"设备平台运行趋势 稳压泵启动频次趋势API"
,
produces
=
"application/json;charset=UTF-8"
,
notes
=
"设备平台运行趋势 稳压泵启动频次趋势API"
)
public
ResponseModel
operatingTrendPressurePump
(
@RequestParam
(
value
=
"startTime"
,
required
=
false
)
String
startTime
,
@RequestParam
(
value
=
"endTime"
,
required
=
false
)
String
endTime
,
@RequestParam
(
value
=
"bizOrgCode"
,
required
=
false
)
String
bizOrgCode
,
@RequestParam
(
value
=
"equipCode"
,
required
=
false
)
String
equipCode
,
@RequestParam
(
value
=
"indexKey"
,
required
=
false
)
String
indexKey
)
{
if
(
ObjectUtils
.
isEmpty
(
bizOrgCode
))
{
ReginParams
reginParams
=
getSelectedOrgInfo
();
ReginParams
.
PersonIdentity
personIdentity
=
reginParams
.
getPersonIdentity
();
if
(!
ValidationUtil
.
isEmpty
(
personIdentity
))
{
bizOrgCode
=
personIdentity
.
getBizOrgCode
();
if
(
bizOrgCode
==
null
)
{
return
CommonResponseUtil
.
success
(
null
);
}
}
}
EquipTrendResultVo
equipTrendResultVo
=
equipmentSpecificService
.
operatingTrendPressurePump
(
startTime
,
endTime
,
bizOrgCode
,
equipCode
,
indexKey
);
return
CommonResponseUtil
.
success
(
equipTrendResultVo
);
}
}
}
amos-boot-module/amos-boot-module-biz/amos-boot-module-equip-biz/src/main/java/com/yeejoin/equipmanage/fegin/IotFeign.java
View file @
2856d284
...
@@ -15,7 +15,7 @@ import java.util.Map;
...
@@ -15,7 +15,7 @@ import java.util.Map;
* @author DELL
* @author DELL
*/
*/
//@FeignClient(name = "${iot.vehicle.track}", path = "iot", configuration = {FeignConfiguration.class})
//@FeignClient(name = "${iot.vehicle.track}", path = "iot", configuration = {FeignConfiguration.class})
@FeignClient
(
name
=
"AMOS-API-IOT"
,
path
=
"iot"
,
configuration
=
{
FeignConfiguration
.
class
})
@FeignClient
(
name
=
"AMOS-API-IOT
-ZS
"
,
path
=
"iot"
,
configuration
=
{
FeignConfiguration
.
class
})
public
interface
IotFeign
{
public
interface
IotFeign
{
@RequestMapping
(
value
=
"/v1/livedata/list"
,
method
=
RequestMethod
.
GET
,
consumes
=
"application/json"
)
@RequestMapping
(
value
=
"/v1/livedata/list"
,
method
=
RequestMethod
.
GET
,
consumes
=
"application/json"
)
...
...
amos-boot-module/amos-boot-module-biz/amos-boot-module-equip-biz/src/main/java/com/yeejoin/equipmanage/mapper/EquipmentSpecificMapper.java
View file @
2856d284
...
@@ -346,4 +346,5 @@ public interface EquipmentSpecificMapper extends BaseMapper<EquipmentSpecific> {
...
@@ -346,4 +346,5 @@ public interface EquipmentSpecificMapper extends BaseMapper<EquipmentSpecific> {
Integer
selectEquipmentCountBySystemId
(
@Param
(
"systemId"
)
Long
systemId
);
Integer
selectEquipmentCountBySystemId
(
@Param
(
"systemId"
)
Long
systemId
);
List
<
EquipTrendInfoVo
>
getEquipListByCode
(
@Param
(
"code"
)
String
code
,
@Param
(
"indexKey"
)
String
indexKey
,
@Param
(
"bizOrgCode"
)
String
bizOrgCode
);
}
}
amos-boot-module/amos-boot-module-biz/amos-boot-module-equip-biz/src/main/java/com/yeejoin/equipmanage/service/IEquipmentSpecificSerivce.java
View file @
2856d284
...
@@ -329,4 +329,8 @@ public interface IEquipmentSpecificSerivce extends IService<EquipmentSpecific> {
...
@@ -329,4 +329,8 @@ public interface IEquipmentSpecificSerivce extends IService<EquipmentSpecific> {
Page
<
Map
<
String
,
Object
>>
getFireEquipListByDefineCode
(
String
code
,
String
equipStatus
,
String
bizOrgCode
,
Page
<
Map
<
String
,
Object
>>
pageBean
);
Page
<
Map
<
String
,
Object
>>
getFireEquipListByDefineCode
(
String
code
,
String
equipStatus
,
String
bizOrgCode
,
Page
<
Map
<
String
,
Object
>>
pageBean
);
void
updateCarStatus
(
String
status
,
String
carId
);
void
updateCarStatus
(
String
status
,
String
carId
);
EquipTrendResultVo
operatingTrendIot
(
String
startTime
,
String
endTime
,
String
bizOrgCode
,
String
equipCode
,
String
indexKey
);
EquipTrendResultVo
operatingTrendPressurePump
(
String
startTime
,
String
endTime
,
String
bizOrgCode
,
String
equipCode
,
String
indexKey
);
}
}
amos-boot-module/amos-boot-module-biz/amos-boot-module-equip-biz/src/main/java/com/yeejoin/equipmanage/service/impl/EquipmentSpecificSerivceImpl.java
View file @
2856d284
This diff is collapsed.
Click to expand it.
amos-boot-system-equip/src/main/resources/mapper/EquipmentSpecificMapper.xml
View file @
2856d284
...
@@ -2997,4 +2997,40 @@
...
@@ -2997,4 +2997,40 @@
</if>
</if>
</select>
</select>
<select
id=
"getEquipListByCode"
resultType=
"com.yeejoin.equipmanage.common.entity.vo.EquipTrendInfoVo"
>
SELECT
a.id,
a.iot_code AS iotCode,
a.`name` AS `name`,
<if
test=
"equipCode == '92011000'"
>
max( CASE WHEN b.field_name = 'maxPressure' THEN b.field_value END ) AS maxNum,
max( CASE WHEN b.field_name = 'minPressure' THEN b.field_value END ) AS minNum,
concat('压力(', ifnull(c.unit, 'Mpa'), ')') as unit
</if>
<if
test=
"(equipCode == '92032000' and indexKey == 'CAFS_WaterTank_WaterTankLevel') or (equipCode == '92031900')"
>
max( CASE WHEN b.field_name = 'maxLevel' THEN b.field_value END ) AS maxNum,
max( CASE WHEN b.field_name = 'minLevel' THEN b.field_value END ) AS minNum,
concat('液位(', ifnull(c.unit, 'M'), ')') as unit
</if>
<if
test=
"equipCode == '92032000' and indexKey == 'CAFS_WaterTank_EffluentFlow'"
>
max( CASE WHEN b.field_name = 'maxLevel' THEN b.field_value END ) AS maxNum,
max( CASE WHEN b.field_name = 'minLevel' THEN b.field_value END ) AS minNum,
concat('出口流量(', ifnull(c.unit, 'L/S'), ')') as unit
</if>
<if
test=
"equipCode == '92010800'"
>
'频次(次/小时)' as unit
</if>
FROM
`wl_equipment_specific` AS a
LEFT JOIN wl_form_instance_equip b ON a.id = b.instance_id
LEFT JOIN ( SELECT * FROM wl_equipment_specific_index WHERE equipment_index_key = #{indexKey} ) c ON a.id = c.equipment_specific_id
<where>
a.`equipment_code` LIKE concat(#{code}, '%')
<if
test=
"bizOrgCode != null and bizOrgCode != ''"
>
AND a.biz_org_code LIKE concat(#{bizOrgCode}, '%')
</if>
</where>
GROUP BY
a.id
</select>
</mapper>
</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