56 lines
2.0 KiB
C#
56 lines
2.0 KiB
C#
using Apollinare.Domain.Entities.Production;
|
|
|
|
namespace Apollinare.API.Modules.Production.Dtos;
|
|
|
|
public class ProductionOrderDto
|
|
{
|
|
public int Id { get; set; }
|
|
public string Code { get; set; } = string.Empty;
|
|
public int ArticleId { get; set; }
|
|
public string ArticleName { get; set; } = string.Empty;
|
|
public decimal Quantity { get; set; }
|
|
public DateTime StartDate { get; set; }
|
|
public DateTime? EndDate { get; set; }
|
|
public DateTime DueDate { get; set; }
|
|
public ProductionOrderStatus Status { get; set; }
|
|
public string? Notes { get; set; }
|
|
public List<ProductionOrderComponentDto> Components { get; set; } = new();
|
|
public List<ProductionOrderPhaseDto> Phases { get; set; } = new();
|
|
public int? ParentProductionOrderId { get; set; }
|
|
public string? ParentProductionOrderCode { get; set; }
|
|
public List<ProductionOrderDto> ChildOrders { get; set; } = new();
|
|
}
|
|
|
|
public class ProductionOrderPhaseDto
|
|
{
|
|
public int Id { get; set; }
|
|
public int Sequence { get; set; }
|
|
public string Name { get; set; } = string.Empty;
|
|
public int WorkCenterId { get; set; }
|
|
public string WorkCenterName { get; set; } = string.Empty;
|
|
public ProductionPhaseStatus Status { get; set; }
|
|
public DateTime? StartDate { get; set; }
|
|
public DateTime? EndDate { get; set; }
|
|
public decimal QuantityCompleted { get; set; }
|
|
public decimal QuantityScrapped { get; set; }
|
|
public int EstimatedDurationMinutes { get; set; }
|
|
public int ActualDurationMinutes { get; set; }
|
|
}
|
|
|
|
public class ProductionOrderComponentDto
|
|
{
|
|
public int Id { get; set; }
|
|
public int ArticleId { get; set; }
|
|
public string ArticleName { get; set; } = string.Empty;
|
|
public decimal RequiredQuantity { get; set; }
|
|
public decimal ConsumedQuantity { get; set; }
|
|
}
|
|
|
|
public class UpdateProductionOrderPhaseDto
|
|
{
|
|
public ProductionPhaseStatus Status { get; set; }
|
|
public decimal QuantityCompleted { get; set; }
|
|
public decimal QuantityScrapped { get; set; }
|
|
public int ActualDurationMinutes { get; set; }
|
|
}
|