设备及摄像头绑定功能接口
正在显示
16 个修改的文件
包含
357 行增加
和
15 行删除
... | @@ -2,6 +2,7 @@ | ... | @@ -2,6 +2,7 @@ |
2 | <project version="4"> | 2 | <project version="4"> |
3 | <component name="CompilerConfiguration"> | 3 | <component name="CompilerConfiguration"> |
4 | <annotationProcessing> | 4 | <annotationProcessing> |
5 | <profile default="true" name="Default" enabled="true" /> | ||
5 | <profile name="Maven default annotation processors profile" enabled="true"> | 6 | <profile name="Maven default annotation processors profile" enabled="true"> |
6 | <sourceOutputDir name="target/generated-sources/annotations" /> | 7 | <sourceOutputDir name="target/generated-sources/annotations" /> |
7 | <sourceTestOutputDir name="target/generated-test-sources/test-annotations" /> | 8 | <sourceTestOutputDir name="target/generated-test-sources/test-annotations" /> | ... | ... |
... | @@ -4,12 +4,11 @@ import com.alibaba.fastjson.JSONArray; | ... | @@ -4,12 +4,11 @@ import com.alibaba.fastjson.JSONArray; |
4 | import com.alibaba.fastjson.JSONObject; | 4 | import com.alibaba.fastjson.JSONObject; |
5 | import com.skua.core.api.vo.Result; | 5 | import com.skua.core.api.vo.Result; |
6 | import com.skua.core.aspect.annotation.AutoLog; | 6 | import com.skua.core.aspect.annotation.AutoLog; |
7 | import com.skua.modules.twin.entity.FmTwinCamera; | ||
8 | import com.skua.modules.twin.entity.FmTwinEquip; | ||
7 | import com.skua.modules.twin.entity.FmTwinManage; | 9 | import com.skua.modules.twin.entity.FmTwinManage; |
8 | import com.skua.modules.twin.service.IFmTwinService; | 10 | import com.skua.modules.twin.service.IFmTwinService; |
9 | import com.skua.modules.twin.vo.FmTwinLocationEntity; | 11 | import com.skua.modules.twin.vo.*; |
10 | import com.skua.modules.twin.vo.FmTwinQueryVO; | ||
11 | import com.skua.modules.twin.vo.FmTwinResultVO; | ||
12 | import com.skua.modules.twin.vo.FmTwinVO; | ||
13 | import io.swagger.annotations.Api; | 12 | import io.swagger.annotations.Api; |
14 | import io.swagger.annotations.ApiOperation; | 13 | import io.swagger.annotations.ApiOperation; |
15 | import lombok.extern.slf4j.Slf4j; | 14 | import lombok.extern.slf4j.Slf4j; |
... | @@ -90,20 +89,54 @@ public class FmTwinController { | ... | @@ -90,20 +89,54 @@ public class FmTwinController { |
90 | return result; | 89 | return result; |
91 | } | 90 | } |
92 | 91 | ||
92 | @AutoLog(value = "孪生体绑定视频") | ||
93 | @ApiOperation(value="孪生体绑定视频", notes="孪生体绑定视频") | ||
94 | @PostMapping(value = "/boundCamera") | ||
95 | public Result<FmTwinCamera> boundCamera(@RequestBody FmTwinCamera fmTwinCamera) { | ||
96 | Result<FmTwinCamera> result = new Result<FmTwinCamera>(); | ||
97 | boolean ok = fmTwinService.boundCamera(fmTwinCamera); | ||
98 | if(ok) { | ||
99 | result.setResult(fmTwinCamera); | ||
100 | result.success("绑定成功!"); | ||
101 | } else { | ||
102 | result.error500("绑定失败"); | ||
103 | } | ||
104 | return result; | ||
105 | } | ||
106 | |||
93 | @AutoLog(value = "获取孪生体绑定的摄像头信息") | 107 | @AutoLog(value = "获取孪生体绑定的摄像头信息") |
94 | @ApiOperation(value="获取孪生体绑定的摄像头信息", notes="获取孪生体绑定的摄像头信息") | 108 | @ApiOperation(value="获取孪生体绑定的摄像头信息", notes="获取孪生体绑定的摄像头信息") |
95 | @GetMapping(value = "/getCameraInfo") | 109 | @GetMapping(value = "/getCameraInfo") |
96 | public Result<?> getCameraInfo(String twinId) { | 110 | public Result<FmTwinCameraResultVO> getCameraInfo(String twinId) { |
97 | Result result = new Result(); | 111 | Result<FmTwinCameraResultVO> result = new Result<FmTwinCameraResultVO>(); |
112 | FmTwinCameraResultVO twinCameraResultVO = fmTwinService.getCameraInfoByTwinId(twinId); | ||
113 | result.setResult(twinCameraResultVO); | ||
98 | result.success("获取成功!"); | 114 | result.success("获取成功!"); |
99 | return result; | 115 | return result; |
100 | } | 116 | } |
101 | 117 | ||
118 | @AutoLog(value = "孪生体绑定设备") | ||
119 | @ApiOperation(value="孪生体绑定设备", notes="孪生体绑定设备") | ||
120 | @PostMapping(value = "/boundEquip") | ||
121 | public Result<FmTwinEquip> boundEquip(@RequestBody FmTwinEquip fmTwinEquip) { | ||
122 | Result<FmTwinEquip> result = new Result<FmTwinEquip>(); | ||
123 | boolean ok = fmTwinService.boundEquip(fmTwinEquip); | ||
124 | if(ok) { | ||
125 | result.setResult(fmTwinEquip); | ||
126 | result.success("绑定成功!"); | ||
127 | } else { | ||
128 | result.error500("绑定失败"); | ||
129 | } | ||
130 | return result; | ||
131 | } | ||
132 | |||
102 | @AutoLog(value = "获取孪生体绑定的设备信息") | 133 | @AutoLog(value = "获取孪生体绑定的设备信息") |
103 | @ApiOperation(value="获取孪生体绑定的设备信息", notes="获取孪生体绑定的设备信息") | 134 | @ApiOperation(value="获取孪生体绑定的设备信息", notes="获取孪生体绑定的设备信息") |
104 | @GetMapping(value = "/getEquipInfo") | 135 | @GetMapping(value = "/getEquipInfo") |
105 | public Result<?> getEquipInfo(String twinId) { | 136 | public Result<FmTwinEquipResultVO> getEquipInfo(String twinId) { |
106 | Result result = new Result(); | 137 | Result<FmTwinEquipResultVO> result = new Result<FmTwinEquipResultVO>(); |
138 | FmTwinEquipResultVO twinEquipResultVO = fmTwinService.getEquipInfoByTwinId(twinId); | ||
139 | result.setResult(twinEquipResultVO); | ||
107 | result.success("获取成功!"); | 140 | result.success("获取成功!"); |
108 | return result; | 141 | return result; |
109 | } | 142 | } | ... | ... |
... | @@ -2,6 +2,7 @@ package com.skua.modules.twin.mapper; | ... | @@ -2,6 +2,7 @@ package com.skua.modules.twin.mapper; |
2 | 2 | ||
3 | import java.util.List; | 3 | import java.util.List; |
4 | 4 | ||
5 | import com.skua.modules.twin.vo.FmTwinCameraSqlResult; | ||
5 | import org.apache.ibatis.annotations.Param; | 6 | import org.apache.ibatis.annotations.Param; |
6 | import com.skua.modules.twin.entity.FmTwinCamera; | 7 | import com.skua.modules.twin.entity.FmTwinCamera; |
7 | import com.baomidou.mybatisplus.core.mapper.BaseMapper; | 8 | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
... | @@ -11,4 +12,7 @@ import com.baomidou.mybatisplus.core.mapper.BaseMapper; | ... | @@ -11,4 +12,7 @@ import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
11 | */ | 12 | */ |
12 | public interface FmTwinCameraMapper extends BaseMapper<FmTwinCamera> { | 13 | public interface FmTwinCameraMapper extends BaseMapper<FmTwinCamera> { |
13 | 14 | ||
15 | FmTwinCameraSqlResult getCameraInfoByTwinId(@Param("twinId") String twinId); | ||
16 | |||
17 | FmTwinCamera getOneCameraByTwinId(@Param("twinId") String twinId); | ||
14 | } | 18 | } | ... | ... |
... | @@ -2,6 +2,7 @@ package com.skua.modules.twin.mapper; | ... | @@ -2,6 +2,7 @@ package com.skua.modules.twin.mapper; |
2 | 2 | ||
3 | import java.util.List; | 3 | import java.util.List; |
4 | 4 | ||
5 | import com.skua.modules.twin.vo.FmTwinEquipSqlResult; | ||
5 | import org.apache.ibatis.annotations.Param; | 6 | import org.apache.ibatis.annotations.Param; |
6 | import com.skua.modules.twin.entity.FmTwinEquip; | 7 | import com.skua.modules.twin.entity.FmTwinEquip; |
7 | import com.baomidou.mybatisplus.core.mapper.BaseMapper; | 8 | import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
... | @@ -11,4 +12,8 @@ import com.baomidou.mybatisplus.core.mapper.BaseMapper; | ... | @@ -11,4 +12,8 @@ import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
11 | */ | 12 | */ |
12 | public interface FmTwinEquipMapper extends BaseMapper<FmTwinEquip> { | 13 | public interface FmTwinEquipMapper extends BaseMapper<FmTwinEquip> { |
13 | 14 | ||
15 | FmTwinEquipSqlResult getEquipInfoByTwinId(@Param("twinId") String twinId); | ||
16 | |||
17 | FmTwinEquip getOneEquipByTwinId(@Param("twinId") String twinId); | ||
18 | |||
14 | } | 19 | } | ... | ... |
... | @@ -2,4 +2,27 @@ | ... | @@ -2,4 +2,27 @@ |
2 | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> | 2 | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
3 | <mapper namespace="com.skua.modules.twin.mapper.FmTwinCameraMapper"> | 3 | <mapper namespace="com.skua.modules.twin.mapper.FmTwinCameraMapper"> |
4 | 4 | ||
5 | <select id="getCameraInfoByTwinId" resultType="com.skua.modules.twin.vo.FmTwinCameraSqlResult"> | ||
6 | SELECT | ||
7 | m.twin_id, | ||
8 | m.twin_name, | ||
9 | m.twin_type, | ||
10 | m.project_id, | ||
11 | c.camera_name, | ||
12 | c.camera_type, | ||
13 | c.camera_rtsp, | ||
14 | c.camera_index, | ||
15 | c.camera_ip_port | ||
16 | FROM | ||
17 | fm_twin_manage m | ||
18 | LEFT JOIN fm_twin_camera c ON m.twin_id = c.twin_id | ||
19 | WHERE | ||
20 | m.twin_id = #{twinId} | ||
21 | LIMIT 1 | ||
22 | </select> | ||
23 | |||
24 | <select id="getOneCameraByTwinId" resultType="com.skua.modules.twin.entity.FmTwinCamera"> | ||
25 | select * from fm_twin_camera where twin_id = #{twinId} | ||
26 | </select> | ||
27 | |||
5 | </mapper> | 28 | </mapper> |
... | \ No newline at end of file | ... | \ No newline at end of file | ... | ... |
... | @@ -2,4 +2,26 @@ | ... | @@ -2,4 +2,26 @@ |
2 | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> | 2 | <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
3 | <mapper namespace="com.skua.modules.twin.mapper.FmTwinEquipMapper"> | 3 | <mapper namespace="com.skua.modules.twin.mapper.FmTwinEquipMapper"> |
4 | 4 | ||
5 | <select id="getEquipInfoByTwinId" resultType="com.skua.modules.twin.vo.FmTwinEquipSqlResult"> | ||
6 | SELECT | ||
7 | m.twin_id, | ||
8 | m.twin_name, | ||
9 | m.twin_type, | ||
10 | m.project_id, | ||
11 | e.equip_name, | ||
12 | e.equip_id, | ||
13 | e.equip_type, | ||
14 | e.equip_voice | ||
15 | FROM | ||
16 | fm_twin_manage m | ||
17 | LEFT JOIN fm_twin_equip e ON m.twin_id = e.twin_id | ||
18 | WHERE | ||
19 | m.twin_id = #{twinId} | ||
20 | LIMIT 1 | ||
21 | </select> | ||
22 | |||
23 | <select id="getOneEquipByTwinId" resultType="com.skua.modules.twin.entity.FmTwinEquip"> | ||
24 | select * from fm_twin_equip where twin_id = #{twinId} | ||
25 | </select> | ||
26 | |||
5 | </mapper> | 27 | </mapper> |
... | \ No newline at end of file | ... | \ No newline at end of file | ... | ... |
1 | package com.skua.modules.twin.service; | 1 | package com.skua.modules.twin.service; |
2 | 2 | ||
3 | import com.skua.modules.twin.entity.FmTwinCamera; | ||
4 | import com.skua.modules.twin.entity.FmTwinEquip; | ||
3 | import com.skua.modules.twin.entity.FmTwinManage; | 5 | import com.skua.modules.twin.entity.FmTwinManage; |
4 | import com.skua.modules.twin.vo.FmTwinLocationEntity; | 6 | import com.skua.modules.twin.vo.*; |
5 | import com.skua.modules.twin.vo.FmTwinQueryVO; | ||
6 | import com.skua.modules.twin.vo.FmTwinResultVO; | ||
7 | import com.skua.modules.twin.vo.FmTwinVO; | ||
8 | 7 | ||
9 | import java.util.List; | 8 | import java.util.List; |
10 | 9 | ||
... | @@ -20,4 +19,12 @@ public interface IFmTwinService { | ... | @@ -20,4 +19,12 @@ public interface IFmTwinService { |
20 | boolean savePosition(String twinId, FmTwinLocationEntity fmTwinLocation); | 19 | boolean savePosition(String twinId, FmTwinLocationEntity fmTwinLocation); |
21 | 20 | ||
22 | boolean saveNameAndType(FmTwinManage fmTwinManage); | 21 | boolean saveNameAndType(FmTwinManage fmTwinManage); |
22 | |||
23 | FmTwinCameraResultVO getCameraInfoByTwinId(String twinId); | ||
24 | |||
25 | FmTwinEquipResultVO getEquipInfoByTwinId(String twinId); | ||
26 | |||
27 | boolean boundCamera(FmTwinCamera fmTwinCamera); | ||
28 | |||
29 | boolean boundEquip(FmTwinEquip fmTwinEquip); | ||
23 | } | 30 | } | ... | ... |
1 | package com.skua.modules.twin.service.impl; | 1 | package com.skua.modules.twin.service.impl; |
2 | 2 | ||
3 | import com.skua.modules.twin.entity.FmTwinCamera; | ||
4 | import com.skua.modules.twin.entity.FmTwinEquip; | ||
3 | import com.skua.modules.twin.entity.FmTwinManage; | 5 | import com.skua.modules.twin.entity.FmTwinManage; |
6 | import com.skua.modules.twin.mapper.FmTwinCameraMapper; | ||
7 | import com.skua.modules.twin.mapper.FmTwinEquipMapper; | ||
4 | import com.skua.modules.twin.mapper.FmTwinLocationMapper; | 8 | import com.skua.modules.twin.mapper.FmTwinLocationMapper; |
5 | import com.skua.modules.twin.mapper.FmTwinManageMapper; | 9 | import com.skua.modules.twin.mapper.FmTwinManageMapper; |
6 | import com.skua.modules.twin.service.IFmTwinService; | 10 | import com.skua.modules.twin.service.IFmTwinService; |
... | @@ -22,6 +26,10 @@ public class FmTwinServiceImpl implements IFmTwinService { | ... | @@ -22,6 +26,10 @@ public class FmTwinServiceImpl implements IFmTwinService { |
22 | private FmTwinManageMapper fmTwinManageMapper; | 26 | private FmTwinManageMapper fmTwinManageMapper; |
23 | @Autowired | 27 | @Autowired |
24 | private FmTwinLocationMapper fmTwinLocationMapper; | 28 | private FmTwinLocationMapper fmTwinLocationMapper; |
29 | @Autowired | ||
30 | private FmTwinCameraMapper fmTwinCameraMapper; | ||
31 | @Autowired | ||
32 | private FmTwinEquipMapper fmTwinEquipMapper; | ||
25 | 33 | ||
26 | @Override | 34 | @Override |
27 | public boolean updateAndSave(String projectId,List<FmTwinVO> list) { | 35 | public boolean updateAndSave(String projectId,List<FmTwinVO> list) { |
... | @@ -88,7 +96,6 @@ public class FmTwinServiceImpl implements IFmTwinService { | ... | @@ -88,7 +96,6 @@ public class FmTwinServiceImpl implements IFmTwinService { |
88 | }else{ | 96 | }else{ |
89 | return false; | 97 | return false; |
90 | } | 98 | } |
91 | |||
92 | } | 99 | } |
93 | 100 | ||
94 | @Override | 101 | @Override |
... | @@ -103,4 +110,75 @@ public class FmTwinServiceImpl implements IFmTwinService { | ... | @@ -103,4 +110,75 @@ public class FmTwinServiceImpl implements IFmTwinService { |
103 | return false; | 110 | return false; |
104 | } | 111 | } |
105 | } | 112 | } |
113 | |||
114 | @Override | ||
115 | public FmTwinCameraResultVO getCameraInfoByTwinId(String twinId) { | ||
116 | FmTwinCameraSqlResult twinCameraSqlResult = fmTwinCameraMapper.getCameraInfoByTwinId(twinId); | ||
117 | FmTwinCameraResultVO twinCameraResultVO = new FmTwinCameraResultVO(); | ||
118 | CameraEntity twinCameraEntity = new CameraEntity(); | ||
119 | twinCameraResultVO.setTwinId(twinCameraSqlResult.getTwinId()); | ||
120 | twinCameraResultVO.setTwinName(twinCameraSqlResult.getTwinName()); | ||
121 | twinCameraResultVO.setTwinType(twinCameraSqlResult.getTwinType()); | ||
122 | twinCameraResultVO.setProjectId(twinCameraSqlResult.getProjectId()); | ||
123 | twinCameraEntity.setCameraName(twinCameraSqlResult.getCameraName()); | ||
124 | twinCameraEntity.setCameraType(twinCameraSqlResult.getCameraType()); | ||
125 | twinCameraEntity.setCameraRtsp(twinCameraSqlResult.getCameraRtsp()); | ||
126 | twinCameraEntity.setCameraIndex(twinCameraSqlResult.getCameraIndex()); | ||
127 | twinCameraEntity.setCameraIpPort(twinCameraSqlResult.getCameraIpPort()); | ||
128 | twinCameraResultVO.setTwinCamera(twinCameraEntity); | ||
129 | return twinCameraResultVO; | ||
130 | } | ||
131 | |||
132 | @Override | ||
133 | public FmTwinEquipResultVO getEquipInfoByTwinId(String twinId) { | ||
134 | FmTwinEquipSqlResult twinEquipSqlResult = fmTwinEquipMapper.getEquipInfoByTwinId(twinId); | ||
135 | FmTwinEquipResultVO twinEquipResultVO = new FmTwinEquipResultVO(); | ||
136 | twinEquipResultVO.setTwinId(twinEquipSqlResult.getTwinId()); | ||
137 | twinEquipResultVO.setTwinName(twinEquipSqlResult.getTwinName()); | ||
138 | twinEquipResultVO.setTwinType(twinEquipSqlResult.getTwinType()); | ||
139 | twinEquipResultVO.setProjectId(twinEquipSqlResult.getProjectId()); | ||
140 | EquipEntity twinEquipEntity = new EquipEntity(); | ||
141 | twinEquipEntity.setEquipId(twinEquipSqlResult.getEquipId()); | ||
142 | twinEquipEntity.setEquipName(twinEquipSqlResult.getEquipName()); | ||
143 | twinEquipEntity.setEquipType(twinEquipSqlResult.getEquipType()); | ||
144 | twinEquipEntity.setEquipVoice(twinEquipSqlResult.getEquipVoice()); | ||
145 | twinEquipResultVO.setTwinEquip(twinEquipEntity); | ||
146 | return twinEquipResultVO; | ||
147 | } | ||
148 | |||
149 | @Override | ||
150 | public boolean boundCamera(FmTwinCamera fmTwinCamera) { | ||
151 | int count = 0; | ||
152 | String twinId = fmTwinCamera.getTwinId(); | ||
153 | FmTwinCamera fmTwinCameraEntity = fmTwinCameraMapper.getOneCameraByTwinId(twinId); | ||
154 | if(fmTwinCameraEntity!=null){ | ||
155 | fmTwinCamera.setId(fmTwinCameraEntity.getId()); | ||
156 | count = fmTwinCameraMapper.updateById(fmTwinCamera); | ||
157 | }else{ | ||
158 | count = fmTwinCameraMapper.insert(fmTwinCamera); | ||
159 | } | ||
160 | if(count == 1){ | ||
161 | return true; | ||
162 | }else{ | ||
163 | return false; | ||
164 | } | ||
165 | } | ||
166 | |||
167 | @Override | ||
168 | public boolean boundEquip(FmTwinEquip fmTwinEquip) { | ||
169 | int count = 0; | ||
170 | String twinId = fmTwinEquip.getTwinId(); | ||
171 | FmTwinEquip fmTwinEquipEntity = fmTwinEquipMapper.getOneEquipByTwinId(twinId); | ||
172 | if(fmTwinEquipEntity!=null){ | ||
173 | fmTwinEquip.setId(fmTwinEquipEntity.getId()); | ||
174 | count = fmTwinEquipMapper.updateById(fmTwinEquip); | ||
175 | }else{ | ||
176 | count = fmTwinEquipMapper.insert(fmTwinEquip); | ||
177 | } | ||
178 | if(count == 1){ | ||
179 | return true; | ||
180 | }else{ | ||
181 | return false; | ||
182 | } | ||
183 | } | ||
106 | } | 184 | } | ... | ... |
1 | package com.skua.modules.twin.vo; | ||
2 | |||
3 | import com.baomidou.mybatisplus.annotation.IdType; | ||
4 | import com.baomidou.mybatisplus.annotation.TableId; | ||
5 | import com.baomidou.mybatisplus.annotation.TableName; | ||
6 | import com.fasterxml.jackson.annotation.JsonFormat; | ||
7 | import io.swagger.annotations.ApiModel; | ||
8 | import io.swagger.annotations.ApiModelProperty; | ||
9 | import lombok.Data; | ||
10 | import lombok.EqualsAndHashCode; | ||
11 | import lombok.experimental.Accessors; | ||
12 | import org.jeecgframework.poi.excel.annotation.Excel; | ||
13 | import org.springframework.format.annotation.DateTimeFormat; | ||
14 | |||
15 | import java.util.Date; | ||
16 | |||
17 | /** | ||
18 | * 孪生体绑定视频 | ||
19 | */ | ||
20 | @Data | ||
21 | public class CameraEntity { | ||
22 | |||
23 | /**摄像头名称*/ | ||
24 | private String cameraName; | ||
25 | /**摄像头类型(rtsp/isc)*/ | ||
26 | private String cameraType; | ||
27 | /**rtsp路径*/ | ||
28 | private String cameraRtsp; | ||
29 | /**摄像头UUID*/ | ||
30 | private String cameraIndex; | ||
31 | /**安防平台IP端口*/ | ||
32 | private String cameraIpPort; | ||
33 | } |
1 | package com.skua.modules.twin.vo; | ||
2 | |||
3 | import com.baomidou.mybatisplus.annotation.IdType; | ||
4 | import com.baomidou.mybatisplus.annotation.TableId; | ||
5 | import com.baomidou.mybatisplus.annotation.TableName; | ||
6 | import com.fasterxml.jackson.annotation.JsonFormat; | ||
7 | import io.swagger.annotations.ApiModel; | ||
8 | import io.swagger.annotations.ApiModelProperty; | ||
9 | import lombok.Data; | ||
10 | import lombok.EqualsAndHashCode; | ||
11 | import lombok.experimental.Accessors; | ||
12 | import org.jeecgframework.poi.excel.annotation.Excel; | ||
13 | import org.springframework.format.annotation.DateTimeFormat; | ||
14 | |||
15 | import java.util.Date; | ||
16 | |||
17 | /** | ||
18 | * 孪生体绑定设备 | ||
19 | */ | ||
20 | @Data | ||
21 | public class EquipEntity { | ||
22 | |||
23 | /**设备ID*/ | ||
24 | private String equipId; | ||
25 | /**设备名称*/ | ||
26 | private String equipName; | ||
27 | /**设备类型*/ | ||
28 | private String equipType; | ||
29 | /**设备音频*/ | ||
30 | private String equipVoice; | ||
31 | } |
1 | package com.skua.modules.twin.vo; | ||
2 | |||
3 | import lombok.Data; | ||
4 | |||
5 | /** | ||
6 | * 孪生体返回结果 | ||
7 | */ | ||
8 | @Data | ||
9 | public class FmTwinCameraResultVO { | ||
10 | |||
11 | /** 孪生体id */ | ||
12 | private String twinId; | ||
13 | /** 孪生体别名 */ | ||
14 | private String twinName; | ||
15 | /** 类型 */ | ||
16 | private String twinType; | ||
17 | /** 所属项目 */ | ||
18 | private String projectId; | ||
19 | /** 摄像头绑定信息 */ | ||
20 | private CameraEntity twinCamera; | ||
21 | |||
22 | } |
1 | package com.skua.modules.twin.vo; | ||
2 | |||
3 | import lombok.Data; | ||
4 | |||
5 | /** | ||
6 | * 孪生体管理 | ||
7 | */ | ||
8 | @Data | ||
9 | public class FmTwinCameraSqlResult { | ||
10 | |||
11 | /** 孪生体id */ | ||
12 | private String twinId; | ||
13 | /** 孪生体别名 */ | ||
14 | private String twinName; | ||
15 | /** 类型 */ | ||
16 | private String twinType; | ||
17 | /** 所属项目 */ | ||
18 | private String projectId; | ||
19 | /**摄像头名称*/ | ||
20 | private String cameraName; | ||
21 | /**摄像头类型(rtsp/isc)*/ | ||
22 | private String cameraType; | ||
23 | /**rtsp路径*/ | ||
24 | private String cameraRtsp; | ||
25 | /**摄像头UUID*/ | ||
26 | private String cameraIndex; | ||
27 | /**安防平台IP端口*/ | ||
28 | private String cameraIpPort; | ||
29 | |||
30 | |||
31 | } |
1 | package com.skua.modules.twin.vo; | ||
2 | |||
3 | import lombok.Data; | ||
4 | |||
5 | /** | ||
6 | * 孪生体返回结果 | ||
7 | */ | ||
8 | @Data | ||
9 | public class FmTwinEquipResultVO { | ||
10 | |||
11 | /** 孪生体id */ | ||
12 | private String twinId; | ||
13 | /** 孪生体别名 */ | ||
14 | private String twinName; | ||
15 | /** 类型 */ | ||
16 | private String twinType; | ||
17 | /** 所属项目 */ | ||
18 | private String projectId; | ||
19 | /** 位置信息 */ | ||
20 | private EquipEntity twinEquip; | ||
21 | |||
22 | } |
1 | package com.skua.modules.twin.vo; | ||
2 | |||
3 | import lombok.Data; | ||
4 | |||
5 | /** | ||
6 | * 孪生体管理 | ||
7 | */ | ||
8 | @Data | ||
9 | public class FmTwinEquipSqlResult { | ||
10 | |||
11 | /** 孪生体id */ | ||
12 | private String twinId; | ||
13 | /** 孪生体别名 */ | ||
14 | private String twinName; | ||
15 | /** 类型 */ | ||
16 | private String twinType; | ||
17 | /** 所属项目 */ | ||
18 | private String projectId; | ||
19 | /**设备ID*/ | ||
20 | private String equipId; | ||
21 | /**设备名称*/ | ||
22 | private String equipName; | ||
23 | /**设备类型*/ | ||
24 | private String equipType; | ||
25 | /**设备音频*/ | ||
26 | private String equipVoice; | ||
27 | |||
28 | |||
29 | } |
... | @@ -5,7 +5,9 @@ | ... | @@ -5,7 +5,9 @@ |
5 | <configuration> | 5 | <configuration> |
6 | <setting name="validation-enabled" value="true" /> | 6 | <setting name="validation-enabled" value="true" /> |
7 | <setting name="provider-name" value="Hibernate" /> | 7 | <setting name="provider-name" value="Hibernate" /> |
8 | <datasource-mapping /> | 8 | <datasource-mapping> |
9 | <factory-entry name="fm-system" /> | ||
10 | </datasource-mapping> | ||
9 | <naming-strategy-map /> | 11 | <naming-strategy-map /> |
10 | </configuration> | 12 | </configuration> |
11 | </facet> | 13 | </facet> | ... | ... |
-
请 注册 或 登录 后发表评论