fix(api): mapeia campos completos de OrderSummary no DashboardService

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-05-28 00:46:32 +00:00
parent 93bf906eec
commit a9c15ac4ec

View File

@@ -92,9 +92,13 @@ export class DashboardService {
clientName: o.client.name,
repId: o.repId,
status: o.status,
subtotal: String(o.subtotal),
total: String(o.total),
discountPct: String(o.discountPct),
issuedAt: o.issuedAt.toISOString(),
approvedAt: o.approvedAt?.toISOString() ?? null,
invoicedAt: o.invoicedAt?.toISOString() ?? null,
cancelledAt: o.cancelledAt?.toISOString() ?? null,
})),
clientesInativos: inactiveClients.map((c) => ({
id: c.id,
@@ -162,9 +166,13 @@ export class DashboardService {
clientName: o.client.name,
repId: o.repId,
status: o.status,
subtotal: String(o.subtotal),
total: String(o.total),
discountPct: String(o.discountPct),
issuedAt: o.issuedAt.toISOString(),
approvedAt: o.approvedAt?.toISOString() ?? null,
invoicedAt: o.invoicedAt?.toISOString() ?? null,
cancelledAt: o.cancelledAt?.toISOString() ?? null,
});
return {