Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
Z
zh-baseversion-project
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
王浩
zh-baseversion-project
Commits
002fc467
Commit
002fc467
authored
Jul 13, 2024
by
wanghao
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1 大屏端 全局搜素 设备,场站,用户信息,监控 ,以及点击查看 详情功能初步实现,待跟前段界面联调测试。
parent
68628511
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
11 changed files
with
453 additions
and
24 deletions
+453
-24
TDeviceInfoController.java
...ehong/web/controller/supervise/TDeviceInfoController.java
+27
-8
TYehuaqiDeviceController.java
...ehong/web/controller/system/TYehuaqiDeviceController.java
+1
-1
PipeInterfaceMapper.java
...in/java/com/zehong/system/mapper/PipeInterfaceMapper.java
+7
-0
TDeviceInfoMapper.java
...main/java/com/zehong/system/mapper/TDeviceInfoMapper.java
+8
-0
IPipeInterfaceService.java
...java/com/zehong/system/service/IPipeInterfaceService.java
+2
-0
ITDeviceInfoService.java
...n/java/com/zehong/system/service/ITDeviceInfoService.java
+14
-0
PipeInterfaceServiceImpl.java
.../zehong/system/service/impl/PipeInterfaceServiceImpl.java
+5
-0
TDeviceInfoServiceImpl.java
...om/zehong/system/service/impl/TDeviceInfoServiceImpl.java
+300
-4
TYehuaqiUserServiceImpl.java
...m/zehong/system/service/impl/TYehuaqiUserServiceImpl.java
+6
-11
PipeInterfaceMapper.xml
.../src/main/resources/mapper/system/PipeInterfaceMapper.xml
+8
-0
TDeviceInfoMapper.xml
...em/src/main/resources/mapper/system/TDeviceInfoMapper.xml
+75
-0
No files found.
zh-baseversion-admin/src/main/java/com/zehong/web/controller/supervise/TDeviceInfoController.java
View file @
002fc467
...
...
@@ -10,25 +10,22 @@ import com.zehong.common.core.domain.model.LoginUser;
import
com.zehong.common.utils.SecurityUtils
;
import
com.zehong.common.utils.ServletUtils
;
import
com.zehong.framework.web.service.TokenService
;
import
com.zehong.system.domain.Listaw
;
import
com.zehong.system.domain.TDetailInfoList
;
import
com.zehong.system.domain.TDeviceInfoS
;
import
com.zehong.system.service.ITDetectorInfoService
;
import
com.zehong.system.service.ITDetectorUserService
;
import
com.zehong.system.service.ITEmployedPeopleInfoService
;
import
com.zehong.system.domain.*
;
import
com.zehong.system.service.*
;
import
com.zehong.web.codeconfig.CodeConFig
;
import
org.apache.commons.collections.CollectionUtils
;
import
org.aspectj.weaver.loadtime.Aj
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.web.bind.annotation.*
;
import
com.zehong.common.annotation.Log
;
import
com.zehong.common.core.controller.BaseController
;
import
com.zehong.common.core.domain.AjaxResult
;
import
com.zehong.common.enums.BusinessType
;
import
com.zehong.system.domain.TDeviceInfo
;
import
com.zehong.system.service.ITDeviceInfoService
;
import
com.zehong.common.utils.poi.ExcelUtil
;
import
com.zehong.common.core.page.TableDataInfo
;
import
javax.annotation.Resource
;
/**
* 设备信息Controller
*
...
...
@@ -52,6 +49,9 @@ public class TDeviceInfoController extends BaseController
@Autowired
private
TokenService
tokenService
;
@Resource
private
ITDeviceUserService
tDeviceUserService
;
/**
* 查询设备信息列表
*/
...
...
@@ -65,6 +65,25 @@ public class TDeviceInfoController extends BaseController
List
<
TDeviceInfo
>
list
=
tDeviceInfoService
.
selectTDeviceInfoList
(
tDeviceInfo
);
return
getDataTable
(
list
);
}
/**
*
* 大屏端 全局搜素 设备,场站,用户信息,监控 步骤一
* */
@GetMapping
(
"/queryBasicInforByNameForBigWindows"
)
public
AjaxResult
queryBasicInforByNameForBigWindows
(
String
name
)
{
return
AjaxResult
.
success
(
tDeviceInfoService
.
queryBasicInforByNameForBigWindows
(
name
));
}
/**
*
* 大屏端 全局搜素 设备,场站,用户信息,监控 步骤二
* */
@GetMapping
(
"/queryBasicInforByNameForBigWindows"
)
public
AjaxResult
queryBasicInforByTypeAndIdForBigWindows
(
String
type
,
String
id
)
{
return
AjaxResult
.
success
(
tDeviceInfoService
.
queryBasicInforByTypeAndIdForBigWindows
(
type
,
id
));
}
@GetMapping
(
"/alllist"
)
public
AjaxResult
alllist
(
TDeviceInfo
tDeviceInfo
)
{
...
...
zh-baseversion-admin/src/main/java/com/zehong/web/controller/system/TYehuaqiDeviceController.java
View file @
002fc467
...
...
@@ -27,7 +27,7 @@ import com.zehong.common.core.page.TableDataInfo;
* @date 2022-09-14
*/
@RestController
@RequestMapping
(
"/system/yehuaqiDevice"
)
@RequestMapping
(
"/
system/yehuaqiDevice"
)
public
class
TYehuaqiDeviceController
extends
BaseController
{
...
...
zh-baseversion-system/src/main/java/com/zehong/system/mapper/PipeInterfaceMapper.java
View file @
002fc467
...
...
@@ -25,6 +25,13 @@ public interface PipeInterfaceMapper {
*/
List
<
PipeDate
>
getPipeForSelect
(
String
enterId
);
/**
* 按照企业id he
* @param pipeId
* @return
*/
PipeDate
getPipeBypipeId
(
@Param
(
"pipeId"
)
String
pipeId
);
/**
* 获取分组数据
* @return
...
...
zh-baseversion-system/src/main/java/com/zehong/system/mapper/TDeviceInfoMapper.java
View file @
002fc467
...
...
@@ -6,6 +6,7 @@ import java.util.Map;
import
com.zehong.system.domain.TDeviceInfo
;
import
com.zehong.system.domain.TDeviceInfoS
;
import
com.zehong.system.domain.vo.TDetectorUserVO
;
import
org.apache.ibatis.annotations.MapKey
;
import
org.apache.ibatis.annotations.Param
;
/**
...
...
@@ -38,6 +39,13 @@ public interface TDeviceInfoMapper
* @return 设备信息集合
*/
public
List
<
TDeviceInfo
>
selectTDeviceInfoList
(
TDeviceInfo
tDeviceInfo
);
/**
*
* 大屏端 全局搜素 设备,场站,用户信息,监控 步骤一
* */
@MapKey
(
value
=
"id"
)
public
List
<
Map
<
String
,
Object
>>
queryBasicInforByNameForBigWindows
(
@Param
(
value
=
"name"
)
String
name
);
public
List
<
TDeviceInfo
>
selectDeviceList
(
TDeviceInfo
tDeviceInfo
);
/**
...
...
zh-baseversion-system/src/main/java/com/zehong/system/service/IPipeInterfaceService.java
View file @
002fc467
...
...
@@ -21,6 +21,8 @@ public interface IPipeInterfaceService {
*/
List
<
PipeDate
>
getPipeForSelect
(
String
enterId
);
PipeDate
getPipeBypipeId
(
String
pipeId
);
/**
* 获取分组数据
* @return
...
...
zh-baseversion-system/src/main/java/com/zehong/system/service/ITDeviceInfoService.java
View file @
002fc467
...
...
@@ -30,6 +30,20 @@ public interface ITDeviceInfoService
* @return 设备信息集合
*/
public
List
<
TDeviceInfo
>
selectTDeviceInfoList
(
TDeviceInfo
tDeviceInfo
);
/**
*
* 大屏端 全局搜素 设备,场站,用户信息,监控 步骤一
* */
public
Map
<
Object
,
List
<
Map
<
String
,
Object
>>>
queryBasicInforByNameForBigWindows
(
String
name
);
/**
*
* 大屏端 全局搜素 设备,场站,用户信息,监控 步骤二
* */
public
Object
queryBasicInforByTypeAndIdForBigWindows
(
String
type
,
String
id
);
public
List
<
TDeviceInfo
>
selectDeviceList
(
TDeviceInfo
tDeviceInfo
);
/**
...
...
zh-baseversion-system/src/main/java/com/zehong/system/service/impl/PipeInterfaceServiceImpl.java
View file @
002fc467
...
...
@@ -36,6 +36,11 @@ public class PipeInterfaceServiceImpl implements IPipeInterfaceService {
return
pipeDates
;
}
@Override
public
PipeDate
getPipeBypipeId
(
String
pipeId
)
{
return
pipeInterfaceMapper
.
getPipeBypipeId
(
pipeId
);
}
/**
* 获取分组数据
* @return
...
...
zh-baseversion-system/src/main/java/com/zehong/system/service/impl/TDeviceInfoServiceImpl.java
View file @
002fc467
This diff is collapsed.
Click to expand it.
zh-baseversion-system/src/main/java/com/zehong/system/service/impl/TYehuaqiUserServiceImpl.java
View file @
002fc467
package
com
.
zehong
.
system
.
service
.
impl
;
import
java.util.ArrayList
;
import
java.util.List
;
import
com.zehong.common.utils.DateUtils
;
import
com.zehong.system.domain.TDetectorUser
;
import
com.zehong.system.domain.TYehuaqiDevice
;
import
com.zehong.system.domain.vo.TDetectorUserVO
;
import
com.zehong.system.domain.vo.TYehuaqiUserVO
;
import
com.zehong.system.mapper.TYehuaqiDeviceMapper
;
import
org.springframework.beans.BeanUtils
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
com.zehong.system.mapper.TYehuaqiUserMapper
;
...
...
@@ -56,12 +51,12 @@ public class TYehuaqiUserServiceImpl implements ITYehuaqiUserService
public
List
<
TYehuaqiUser
>
selectAllUserList
(
TYehuaqiUser
tYehuaqiUser
)
{
List
<
TYehuaqiUser
>
list
=
tYehuaqiUserMapper
.
selectTYehuaqiUserListTwo
(
tYehuaqiUser
);
//
for (TYehuaqiUser user : list){
//
TYehuaqiDevice d = new TYehuaqiDevice();
//
d.setUserId(user.getUserId());
//
List<TYehuaqiDevice> devices = tYehuaqiDeviceMapper.selectTYehuaqiDeviceList(d);
//
user.setDeviceNum(devices.size());
//
}
for
(
TYehuaqiUser
user
:
list
){
TYehuaqiDevice
d
=
new
TYehuaqiDevice
();
d
.
setUserId
(
user
.
getUserId
());
List
<
TYehuaqiDevice
>
devices
=
tYehuaqiDeviceMapper
.
selectTYehuaqiDeviceList
(
d
);
user
.
setDeviceNum
(
devices
.
size
());
}
return
list
;
}
...
...
zh-baseversion-system/src/main/resources/mapper/system/PipeInterfaceMapper.xml
View file @
002fc467
...
...
@@ -135,6 +135,14 @@
</if>
</select>
<select
id=
"getPipeBypipeId"
parameterType=
"PipeDate"
resultMap=
"PipeDateResult"
>
select format(pipe_length,2)pipe_length,pipe_pressure,beyond_enterprise_id,pipe_id,pipe_diameter,pipe_material,
buried_depth,pipe_trend,build_date,pipe_addr,coordinates,remarks,build_unit,beyond_enterprise_name,
pipe_name,detaild_address,ind_reg_auth,ind_reg_auth_per,ind_reg_auth_per_con,key_areas_gas_usage,
aff_gas_com,aff_gas_com_sec_per,aff_gas_com_sec_per_con,sec_check_time,unit_gas_user_res,unit_gas_user_res_con from t_pipe_info
where pipe_id = #{pipeId}
</select>
<!--获取分组数据-->
<select
id=
"selectGroupPipeData"
parameterType=
"PipeDate"
resultMap=
"PipeDateResult"
>
select beyond_enterprise_id,pipe_id,pipe_diameter,pipe_material,buried_depth,pipe_trend,build_date,pipe_addr,coordinates,remarks,build_unit,beyond_enterprise_name from t_pipe_info
...
...
zh-baseversion-system/src/main/resources/mapper/system/TDeviceInfoMapper.xml
View file @
002fc467
...
...
@@ -59,6 +59,81 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
</where>
order by a.device_id desc
</select>
<select
id=
"queryBasicInforByNameForBigWindows"
resultType=
"map"
>
SELECT
device_id AS id,
device_name AS NAME,
CONCAT( '[[', longitude, ', ', latitude, ']]' ) AS coordinates,
device_type AS type
FROM
t_device_info
WHERE
<if
test=
"name != null and name != ''"
>
device_name like concat('%', #{name}, '%') AND
</if>
longitude IS NOT NULL
AND latitude IS NOT NULL UNION
SELECT
site_station_id AS id,
site_station_name AS NAME,
CONCAT( '[[', longitude, ', ', latitude, ']]' ) AS coordinates,
'3' AS type
FROM
t_site_station_info
WHERE
<if
test=
"name != null and name != ''"
>
site_station_name like concat('%', #{name}, '%') AND
</if>
longitude IS NOT NULL
AND latitude IS NOT NULL UNION
SELECT
user_id AS id,
nick_name AS NAME,
CONCAT( '[[', longitude, ', ', latitude, ']]' ) AS coordinates,
CASE
user_type
WHEN '1' THEN
'4'
WHEN '2' THEN
'5'
WHEN '3' THEN
'6'
END AS type
FROM
t_detector_user
WHERE
<if
test=
"name != null and name != ''"
>
nick_name like concat('%', #{name}, '%') AND
</if>
longitude IS NOT NULL
AND latitude IS NOT NULL UNION
SELECT
video_manager_id AS id,
video_name AS NAME,
CONCAT( '[[', longitude, ', ', latitude, ']]' ) AS coordinates,
'7' AS type
FROM
t_video_manager
WHERE
<if
test=
"name != null and name != ''"
>
video_name like concat('%', #{name}, '%') AND
</if>
longitude IS NOT NULL
AND latitude IS NOT NULL UNION
SELECT
user_id AS id,
nick_name AS NAME,
CONCAT( '[[', longitude, ', ', latitude, ']]' ) AS coordinates,
'8' AS type
FROM
t_yehuaqi_user
WHERE
<if
test=
"name != null and name != ''"
>
nick_name like concat('%', #{name}, '%') AND
</if>
longitude IS NOT NULL
AND latitude IS NOT NULL UNION
SELECT
pipe_id AS id,
pipe_addr AS NAME,
coordinates,
'9' AS type
FROM
t_pipe_info
WHERE
<if
test=
"name != null and name != ''"
>
pipe_addr like concat('%', #{name}, '%') AND
</if>
coordinates IS NOT NULL
</select>
<select
id=
"selectDeviceList"
parameterType=
"TDeviceInfo"
resultMap=
"TDeviceInfoResult"
>
SELECT * FROM t_device_info WHERE device_name like concat('%', #{deviceName}, '%')
</select>
...
...
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