43 lines
1.6 KiB
C#
43 lines
1.6 KiB
C#
/*
|
||
*代码由框架生成,任何更改都可能导致被代码生成器覆盖
|
||
*如果数据库字段发生变化,请在代码生器重新生成此Model
|
||
*/
|
||
using System;
|
||
using System.Collections.Generic;
|
||
using SqlSugar;
|
||
using VolPro.Entity.SystemModels;
|
||
|
||
namespace VolPro.Entity.DomainModels
|
||
{
|
||
public partial class base_device
|
||
{
|
||
/// <summary>导航属性:关联视频通道扩展记录(一对一)</summary>
|
||
[Navigate(NavigateType.OneToOne, nameof(DeviceId), nameof(video_channel.DeviceId))]
|
||
public video_channel? VideoChannel { get; set; }
|
||
|
||
/// <summary>导航属性:关联告警记录(一对多)</summary>
|
||
[Navigate(NavigateType.OneToMany, nameof(DeviceId), nameof(iot_alarm.DeviceId))]
|
||
public List<iot_alarm>? Alarms { get; set; }
|
||
|
||
/// <summary>导航属性:关联数据归档(一对多)</summary>
|
||
[Navigate(NavigateType.OneToMany, nameof(DeviceId), nameof(iot_devicedata.DeviceId))]
|
||
public List<iot_devicedata>? DeviceData { get; set; }
|
||
|
||
/// <summary>
|
||
/// 网关字段白名单。网关同步时,只有此集合中的字段会被覆盖,
|
||
/// 其他字段(DeviceName/DeviceCategory/DeviceGroup/Location/MapModelId等)
|
||
/// 由管理员在管理端维护,同步不覆盖。
|
||
/// </summary>
|
||
public static readonly HashSet<string> GatewayFields = new()
|
||
{
|
||
nameof(IsOnline),
|
||
nameof(IsParent),
|
||
nameof(ParentDeviceId),
|
||
nameof(ExtraData),
|
||
nameof(IpAddress),
|
||
nameof(Port),
|
||
nameof(LastSyncTime)
|
||
};
|
||
}
|
||
}
|