33 lines
861 B
C#
33 lines
861 B
C#
namespace LaaProduction.Services.Models
|
|
{
|
|
using System.Collections.Generic;
|
|
using System.Linq;
|
|
|
|
public class BatchPrintModel
|
|
{
|
|
private readonly PalletsBatchModel batchModel;
|
|
|
|
public BatchPrintModel(PalletsBatchModel batchModel)
|
|
=> this.batchModel = batchModel;
|
|
|
|
public string ClientName
|
|
=> this.batchModel.Customer;
|
|
|
|
public int OrderNr
|
|
=> this.batchModel.OrderNr;
|
|
|
|
public int PalletNr
|
|
=> this.batchModel
|
|
.Positions
|
|
?.FirstOrDefault()
|
|
?.Items
|
|
?.FirstOrDefault()
|
|
?.PalletNr ?? 0;
|
|
|
|
public int ProductionOrderNr
|
|
=> this.batchModel.ProductionOrderNr;
|
|
|
|
public IEnumerable<PalletPosition> Positions
|
|
=> this.batchModel.Positions;
|
|
}
|
|
} |