Пример #1
0
 public InvoiceDetail(Code productCode,
                      Name description,
                      int qty,
                      decimal amount,
                      decimal taxPercent,
                      InvoiceHeader invoiceHeader) : this()
     => (ProductCode, Description, Qty, Amount, TaxPercent, InvoiceHeader)
Пример #2
0
 public static InvoiceHeaderDto FromEntity(InvoiceHeader entity)
 => new InvoiceHeaderDto(entity.Id
                         , entity.Code.Value
                         , entity.Ncf
                         , entity.NumberSequenceId
                         , entity.Rnc
                         , entity.Client.Id
                         , entity.Client
                         , entity.InvoiceDate
                         , entity.DueDate
                         , entity.PaymentTerm.Id
                         , entity.PaymentTerm
                         , entity.Notes.Value
                         , entity.TermAndConditions.Value
                         , entity.Footer.Value
                         , entity.Discount
                         , entity.SubTotal
                         , entity.TaxTotal
                         , entity.Total
                         , entity.InvoiceDetails.Select(c => FromEntity(c)).ToImmutableList()
                         , entity.Created
                         , entity.Modified
                         , entity.Status);