52 lines
1022 B
C#
52 lines
1022 B
C#
using Dlhis.Entity.Device.Enums;
|
|
using Kurisu.AspNetCore.Utils.Extensions;
|
|
|
|
namespace Dlhis.Basic.Device.Response;
|
|
|
|
public class DeviceGroupTreeResponse
|
|
{
|
|
public long Id { get; set; }
|
|
|
|
|
|
/// <summary>
|
|
/// 上级分组code
|
|
/// </summary>
|
|
public Guid? PCode { get; set; }
|
|
|
|
/// <summary>
|
|
/// 分组code/设备code
|
|
/// </summary>
|
|
public Guid Code { get; set; }
|
|
|
|
/// <summary>
|
|
/// 分组名称/设备名称
|
|
/// </summary>
|
|
public string Name { get; set; }
|
|
|
|
/// <summary>
|
|
/// 设备组类型
|
|
/// </summary>
|
|
public DeviceTypeEnumType? Type { get; set; }
|
|
|
|
/// <summary>
|
|
/// 分组类型描述
|
|
/// </summary>
|
|
public string TypeDesc
|
|
{
|
|
get
|
|
{
|
|
if (!Type.HasValue)
|
|
{
|
|
return string.Empty;
|
|
}
|
|
|
|
return Type.Value.GetDescription();
|
|
}
|
|
}
|
|
|
|
/// <summary>
|
|
/// 下级
|
|
/// </summary>
|
|
public List<DeviceGroupTreeResponse> Next { get; set; } = new();
|
|
}
|