合并 #1626 的修改
parent
f2e3ff2a41
commit
dc3e99fe57
|
@ -2,9 +2,7 @@ package com.genersoft.iot.vmp.gb28181.dao;
|
||||||
|
|
||||||
import com.genersoft.iot.vmp.gb28181.bean.Device;
|
import com.genersoft.iot.vmp.gb28181.bean.Device;
|
||||||
import com.genersoft.iot.vmp.gb28181.bean.DeviceChannel;
|
import com.genersoft.iot.vmp.gb28181.bean.DeviceChannel;
|
||||||
import com.github.pagehelper.PageInfo;
|
|
||||||
import org.apache.ibatis.annotations.*;
|
import org.apache.ibatis.annotations.*;
|
||||||
import org.apache.ibatis.annotations.Param;
|
|
||||||
import org.springframework.stereotype.Repository;
|
import org.springframework.stereotype.Repository;
|
||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
@ -282,6 +280,7 @@ public interface DeviceMapper {
|
||||||
"broadcast_push_after_ack,"+
|
"broadcast_push_after_ack,"+
|
||||||
"geo_coord_sys,"+
|
"geo_coord_sys,"+
|
||||||
"on_line,"+
|
"on_line,"+
|
||||||
|
"stream_mode," +
|
||||||
"media_server_id"+
|
"media_server_id"+
|
||||||
") VALUES (" +
|
") VALUES (" +
|
||||||
"#{deviceId}," +
|
"#{deviceId}," +
|
||||||
|
@ -296,6 +295,7 @@ public interface DeviceMapper {
|
||||||
"#{broadcastPushAfterAck}," +
|
"#{broadcastPushAfterAck}," +
|
||||||
"#{geoCoordSys}," +
|
"#{geoCoordSys}," +
|
||||||
"#{onLine}," +
|
"#{onLine}," +
|
||||||
|
"#{streamMode}," +
|
||||||
"#{mediaServerId}" +
|
"#{mediaServerId}" +
|
||||||
")")
|
")")
|
||||||
void addCustomDevice(Device device);
|
void addCustomDevice(Device device);
|
||||||
|
|
|
@ -413,6 +413,9 @@ public class DeviceServiceImpl implements IDeviceService {
|
||||||
device.setOnLine(false);
|
device.setOnLine(false);
|
||||||
device.setCreateTime(DateUtil.getNow());
|
device.setCreateTime(DateUtil.getNow());
|
||||||
device.setUpdateTime(DateUtil.getNow());
|
device.setUpdateTime(DateUtil.getNow());
|
||||||
|
if(device.getStreamMode() == null) {
|
||||||
|
device.setStreamMode("UDP");
|
||||||
|
}
|
||||||
deviceMapper.addCustomDevice(device);
|
deviceMapper.addCustomDevice(device);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue