You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

62 lines
1.5 KiB

using CellularManagement.Domain.Common;
using MediatR;
using System.ComponentModel.DataAnnotations;
namespace CellularManagement.Application.Features.ProtocolVersions.Commands.UpdateProtocolVersion;
/// <summary>
/// 更新协议版本命令
/// </summary>
public class UpdateProtocolVersionCommand : IRequest<OperationResult<UpdateProtocolVersionResponse>>
{
/// <summary>
/// 协议版本ID
/// </summary>
[Required]
public string ProtocolVersionId { get; set; } = null!;
/// <summary>
/// 版本名称
/// </summary>
[Required]
[MaxLength(50)]
public string Name { get; set; } = null!;
/// <summary>
/// 版本号
/// </summary>
[Required]
[MaxLength(20)]
public string Version { get; set; } = null!;
/// <summary>
/// 版本描述
/// </summary>
[MaxLength(500)]
public string? Description { get; set; }
/// <summary>
/// 是否启用
/// </summary>
public bool IsEnabled { get; set; } = true;
/// <summary>
/// 发布日期
/// </summary>
public DateTime? ReleaseDate { get; set; }
/// <summary>
/// 最低支持版本
/// </summary>
[MaxLength(20)]
public string? MinimumSupportedVersion { get; set; }
/// <summary>
/// 设备序列号
/// </summary>
[Required(ErrorMessage = "设备序列号不能为空")]
[MaxLength(50, ErrorMessage = "设备序列号不能超过50个字符")]
public string SerialNumber { get; set; } = null!;
}