auto.bus_api/SharedModels/DataTransferObjects/VehicleEnrollmentDto.cs
cuqmbr 20def5de44 feat: add "Popular routes" statistics
feat: add financial report generation

feat: add automation task: indirect route search
2022-12-09 11:54:14 +02:00

42 lines
1.1 KiB
C#

using System.ComponentModel.DataAnnotations;
namespace SharedModels.DataTransferObjects;
public class VehicleEnrollmentDto : CreateVehicleEnrollmentDto
{
public int Id { get; set; }
}
public class CreateVehicleEnrollmentDto
{
[Required]
public int VehicleId { get; set; }
[Required]
public int RouteId { get; set; }
[Required]
[DataType(DataType.DateTime)]
public DateTime DepartureDateTimeUtc { get; set; }
}
public class UpdateVehicleEnrollmentDto : CreateVehicleEnrollmentDto
{
[Required]
public int Id { get; set; }
public TimeSpan DelayTimeSpan { get; set; } = TimeSpan.Zero;
public bool IsCanceled { get; set; } = false;
public string CancelationComment { get; set; } = null!;
}
public class CreateVehicleEnrollmentWithDetailsDto : CreateVehicleEnrollmentDto
{
public IList<CreateRouteAddressDetailsInVehicleEnrollmentDto> RouteAddressDetails { get; set; } = null!;
}
public class VehicleEnrollmentWithDetailsDto : VehicleEnrollmentDto
{
public IList<RouteAddressDetailsInVehicleEnrollmentDto> RouteAddressDetails { get; set; } = null!;
}