tplink接口优化
This commit is contained in:
parent
9723fbb2af
commit
a5d8e8d340
|
|
@ -188,6 +188,18 @@ public class CameraInfoController extends JeecgController<CameraInfo, ICameraInf
|
|||
return service.getIpcCapability(cameraInfo);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取设备详情信息
|
||||
*
|
||||
* @param cameraInfo
|
||||
* @return
|
||||
*/
|
||||
@GetMapping(value = "/getDeviceDetails")
|
||||
public Result<JSONObject> getDeviceDetails(CameraInfo cameraInfo) {
|
||||
return service.getDeviceDetails(cameraInfo);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 获取画面基本信息
|
||||
*
|
||||
|
|
@ -210,6 +222,28 @@ public class CameraInfoController extends JeecgController<CameraInfo, ICameraInf
|
|||
return service.setImageCommon(map);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取画面操作信息
|
||||
*
|
||||
* @param map
|
||||
* @return
|
||||
*/
|
||||
@PostMapping(value = "/getImageSwitch")
|
||||
public Result<JSONObject> getImageSwitch(@RequestBody Map<String,Object> map) {
|
||||
return service.getImageSwitch(map);
|
||||
}
|
||||
|
||||
/**
|
||||
* 设置画面操作信息
|
||||
*
|
||||
* @param map
|
||||
* @return
|
||||
*/
|
||||
@PostMapping(value = "/setImageSwitch")
|
||||
public Result setImageSwitch(@RequestBody Map<String,Object> map) {
|
||||
return service.setImageSwitch(map);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取OSD能力集
|
||||
*
|
||||
|
|
|
|||
|
|
@ -326,6 +326,7 @@ public class CameraInfo implements Serializable {
|
|||
private String remarks;//备注
|
||||
private String izAllocate;//是否分配
|
||||
private String dimension;//设备维度
|
||||
private String channel;//通道号
|
||||
|
||||
@TableField(exist = false)
|
||||
private String routeType;//camera监控设备 network网络设备
|
||||
|
|
|
|||
|
|
@ -41,7 +41,8 @@
|
|||
a.maintain_status,
|
||||
a.remarks,
|
||||
a.iz_allocate,
|
||||
a.dimension
|
||||
a.dimension,
|
||||
a.channel
|
||||
from nu_iot_tplink_camera a left join nu_base_info b on a.nu_id = b.nu_id
|
||||
left join nu_iot_tplink_camera_capability c on a.device_index = c.device_index
|
||||
<where>
|
||||
|
|
@ -126,7 +127,8 @@
|
|||
a.ftp_uploadpath as ftpUploadpath,
|
||||
a.remarks,
|
||||
a.iz_allocate,
|
||||
a.dimension
|
||||
a.dimension,
|
||||
a.channel
|
||||
from nu_iot_tplink_camera a left join nu_base_info b on a.nu_id = b.nu_id
|
||||
<where>
|
||||
<if test="projectId != null and projectId != ''">
|
||||
|
|
@ -173,7 +175,8 @@
|
|||
ftp_uploadpath as ftpUploadpath,
|
||||
a.remarks,
|
||||
a.iz_allocate,
|
||||
a.dimension
|
||||
a.dimension,
|
||||
a.channel
|
||||
from nu_iot_tplink_camera a
|
||||
<where>
|
||||
<if test="deviceType != null and deviceType != ''">
|
||||
|
|
@ -229,7 +232,8 @@
|
|||
a.ftp_uploadpath as ftpUploadpath,
|
||||
a.remarks,
|
||||
a.iz_allocate,
|
||||
a.dimension
|
||||
a.dimension,
|
||||
a.channel
|
||||
from nu_iot_tplink_camera a left join nu_base_info b on a.nu_id = b.id
|
||||
where device_index = #{deviceIndex}
|
||||
</select>
|
||||
|
|
@ -325,7 +329,10 @@
|
|||
|
||||
<update id="updateDeviceStatusByDevId">
|
||||
UPDATE nu_iot_tplink_camera
|
||||
SET device_status = #{deviceStatus}
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="deviceStatus != null">device_status = #{deviceStatus},</if>
|
||||
<if test="channel != null">channel = #{channel},</if>
|
||||
</trim>
|
||||
where device_index = #{deviceIndex}
|
||||
</update>
|
||||
|
||||
|
|
@ -376,7 +383,8 @@
|
|||
a.ftp_uploadpath as ftpUploadpath,
|
||||
a.remarks,
|
||||
a.iz_allocate,
|
||||
a.dimension
|
||||
a.dimension,
|
||||
a.channel
|
||||
from nu_iot_tplink_camera a
|
||||
where device_index = #{deviceIndex}
|
||||
</select>
|
||||
|
|
@ -439,7 +447,8 @@
|
|||
c.area_flag as areaFlag,
|
||||
a.remarks,
|
||||
a.iz_allocate,
|
||||
a.dimension
|
||||
a.dimension,
|
||||
a.channel
|
||||
from nu_iot_tplink_camera a
|
||||
left join nu_base_info c on a.nu_id = c.nu_id
|
||||
<where>
|
||||
|
|
@ -545,7 +554,8 @@
|
|||
c.area_flag as areaFlag,
|
||||
a.remarks,
|
||||
a.iz_allocate,
|
||||
a.dimension
|
||||
a.dimension,
|
||||
a.channel
|
||||
from nu_iot_tplink_camera a
|
||||
left join nu_base_info c on a.nu_id = c.nu_id
|
||||
where a.depart_server_url = #{params.departServerUrl}
|
||||
|
|
|
|||
|
|
@ -31,8 +31,11 @@ public interface ICameraInfoService extends IService<CameraInfo> {
|
|||
Result<String> syncDevicesStatus(CameraInfo cameraInfo);
|
||||
Result<String> syncProjectIpcDevice(CameraInfo cameraInfo);
|
||||
Result<JSONObject> getIpcCapability(CameraInfo cameraInfo);
|
||||
Result<JSONObject> getDeviceDetails(CameraInfo cameraInfo);
|
||||
Result<JSONObject> getImageCommon(Map<String,Object> map);
|
||||
Result setImageCommon(Map<String,Object> map);
|
||||
Result<JSONObject> getImageSwitch(Map<String,Object> map);
|
||||
Result setImageSwitch(Map<String,Object> map);
|
||||
Result<JSONObject> getOsdCapability(Map<String,Object> map);
|
||||
Result<JSONObject> getOsd(Map<String,Object> map);
|
||||
Result<String> setOsd(Map<String,Object> map);
|
||||
|
|
|
|||
File diff suppressed because it is too large
Load Diff
|
|
@ -41,6 +41,7 @@ public enum ApiEnum {
|
|||
QUERY_ALARM_LOG("/tums/logManager/v2/queryAlarmLog","查询告警日志列表"),
|
||||
QUERY_UNREAD_ALARM_MSG("/tums/logManager/v2/queryUnreadAlarmMsg","查询未读告警日志列表"),
|
||||
IPC_GET_IPC_CAPABILITY("/tums/deviceManager/v1/getIpcCapability","获取ipc能力集"),
|
||||
GET_DEVICE_DETAILS("/tums/deviceManager/v2/getDeviceDetails","获取设备详情信息"),
|
||||
IPC_PASSTHROUGH("/tums/devConfig/v1/passthrough","设备配置信息"),
|
||||
|
||||
IPC_ADD_PREVIEW_CHN("/tums/preview/v1/addPreviewChn","添加预览通道"),
|
||||
|
|
|
|||
|
|
@ -333,6 +333,20 @@ public class TumsApi {
|
|||
return jsonResponse;
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取设备详情信息
|
||||
* @param jsonRequest
|
||||
* @return
|
||||
*/
|
||||
public String getDeviceDetails(String jsonRequest){
|
||||
this.createTumsClient();
|
||||
log.info("getDeviceDetails:request:{}",jsonRequest);
|
||||
String jsonResponse = tumsClient.request(jsonRequest, ApiEnum.GET_DEVICE_DETAILS.getValue());
|
||||
log.info("getDeviceDetails:response:{}",jsonResponse);
|
||||
return jsonResponse;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 设备配置信息
|
||||
* @param jsonRequest
|
||||
|
|
|
|||
Loading…
Reference in New Issue