feat: añado Dtos para el invoices{id}
para que pueda devolver todas sus lineas de factura. Tambien las respectivas Respuestas de Dolibarr que hay que sanear.
This commit is contained in:
parent
5081d71f69
commit
b2427a3276
|
|
@ -0,0 +1,7 @@
|
|||
namespace DoliMiddlewareApi.Dtos.Dolibarr;
|
||||
|
||||
public class InvoiceDetailResponse : InvoiceResponse
|
||||
{
|
||||
public List<InvoiceLineResponse>? Lines { get; set; }
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,12 @@
|
|||
namespace DoliMiddlewareApi.Dtos.Dolibarr;
|
||||
|
||||
public class InvoiceLineResponse
|
||||
{
|
||||
public string? id { get; set; }
|
||||
public string? desc { get; set; }
|
||||
public string? description { get; set; }
|
||||
public string? qty { get; set; }
|
||||
public string? subprice { get; set; }
|
||||
public string? tva_tx { get; set; }
|
||||
public string? total_ttc { get; set; }
|
||||
}
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
namespace DoliMiddlewareApi.Services;
|
||||
namespace DoliMiddlewareApi.Dtos.Dolibarr;
|
||||
|
||||
public class InvoiceResponse
|
||||
{
|
||||
|
|
@ -0,0 +1,14 @@
|
|||
namespace DoliMiddlewareApi.Dtos;
|
||||
|
||||
public class InvoiceDetailDto
|
||||
{
|
||||
public int Id { get; set; }
|
||||
public string Number { get; set; }
|
||||
public DateTime? Date { get; set; }
|
||||
public DateTime? ExpireDate { get; set; }
|
||||
public int ClientId { get; set; }
|
||||
public decimal? Total { get; set; }
|
||||
public decimal? RemainToPay { get; set; }
|
||||
public string Status { get; set; }
|
||||
public List<InvoiceLineDto>? Lines { get; set; }
|
||||
}
|
||||
|
|
@ -0,0 +1,11 @@
|
|||
namespace DoliMiddlewareApi.Dtos;
|
||||
|
||||
public class InvoiceLineDto
|
||||
{
|
||||
public int Id { get; set; }
|
||||
public string Description { get; set; }
|
||||
public decimal Quantity { get; set; }
|
||||
public decimal UnitPrice { get; set; }
|
||||
public decimal TaxRate { get; set; }
|
||||
public decimal Total { get; set; }
|
||||
}
|
||||
Loading…
Reference in New Issue