RobotApp/RobotApp.Common.Shares/Dtos/RobotConfigDto.cs
Đăng Nguyễn 8736bad3e7 update
2025-11-06 14:14:10 +07:00

48 lines
1.5 KiB
C#

using RobotApp.Common.Shares.Enums;
using System.ComponentModel.DataAnnotations;
namespace RobotApp.Common.Shares.Dtos;
#nullable disable
public record RobotConfigDto
{
public Guid Id { get; set; }
public NavigationType NavigationType { get; set; }
[Range(0.1, 10, ErrorMessage = "Value must be from 0.1 to 10")]
public double RadiusWheel { get; set; }
[Range(0.1, 10, ErrorMessage = "Value must be from 0.1 to 10")]
public double Width { get; set; }
[Range(0.1, 10, ErrorMessage = "Value must be from 0.1 to 10")]
public double Length { get; set; }
[Range(0.1, 10, ErrorMessage = "Value must be from 0.1 to 10")]
public double Height { get; set; }
public DateTime CreatedAt { get; set; }
public DateTime UpdatedAt { get; set; }
public bool IsActive { get; set; }
[Required]
public string ConfigName { get; set; }
public string Description { get; set; }
}
public record UpdateRobotConfigDto
{
public NavigationType NavigationType { get; set; }
public double RadiusWheel { get; set; }
public double Width { get; set; }
public double Length { get; set; }
public double Height { get; set; }
public string Description { get; set; }
}
public record CreateRobotConfigDto
{
public string ConfigName { get; set; }
public string Description { get; set; }
public NavigationType NavigationType { get; set; }
public double RadiusWheel { get; set; }
public double Width { get; set; }
public double Length { get; set; }
public double Height { get; set; }
}