增加数据库结构以及接口

This commit is contained in:
648540858
2024-11-20 22:33:21 +08:00
parent 2dcbee74b0
commit 0cacdb5928
14 changed files with 356 additions and 19 deletions

View File

@@ -93,6 +93,9 @@ public interface DeviceChannelMapper {
@SelectProvider(type = DeviceChannelProvider.class, method = "queryChannelsByDeviceDbId")
List<DeviceChannel> queryChannelsByDeviceDbId(@Param("deviceDbId") int deviceDbId);
@Select("select id from wvp_device_channel where device_db_id = #{deviceDbId}")
List<Integer> queryChaneIdListByDeviceDbId(@Param("deviceDbId") int deviceDbId);
@Delete("DELETE FROM wvp_device_channel WHERE device_db_id=#{deviceId}")
int cleanChannelsByDeviceId(@Param("deviceId") int deviceId);

View File

@@ -122,4 +122,7 @@ public interface IDeviceChannelService {
DeviceChannel getOneBySourceId(int deviceDbId, String channelId);
List<DeviceChannel> queryChaneListByDeviceDbId(Integer deviceDbId);
List<Integer> queryChaneIdListByDeviceDbId(Integer deviceDbId);
}

View File

@@ -350,6 +350,16 @@ public class DeviceChannelServiceImpl implements IDeviceChannelService {
return channelMapper.queryChannelsByDeviceDbId(device.getId());
}
@Override
public List<DeviceChannel> queryChaneListByDeviceDbId(Integer deviceDbId) {
return channelMapper.queryChannelsByDeviceDbId(deviceDbId);
}
@Override
public List<Integer> queryChaneIdListByDeviceDbId(Integer deviceDbId) {
return channelMapper.queryChaneIdListByDeviceDbId(deviceDbId);
}
@Override
public void updateChannelGPS(Device device, DeviceChannel deviceChannel, MobilePosition mobilePosition) {
if (userSetting.getSavePositionHistory()) {

View File

@@ -94,4 +94,6 @@ public class BroadcastResponseMessageHandler extends SIPRequestProcessorParent i
public void handForPlatform(RequestEvent evt, Platform parentPlatform, Element element) {
}
}