feature/reporte-bak
This commit is contained in:
@@ -586,8 +586,9 @@ export const invoicesApi = {
|
||||
}>(`/v1/a76/factura-cove/invoices/${invoiceId}/cove/eligibility?${params.toString()}`);
|
||||
},
|
||||
|
||||
getCoveReceipt: (invoiceId: number, companyId: number): Promise<Blob> => {
|
||||
getCoveReceipt: (invoiceId: number, companyId: number, forceRefresh = false): Promise<Blob> => {
|
||||
const params = new URLSearchParams({ company_id: companyId.toString() });
|
||||
if (forceRefresh) params.set('force_refresh', 'true');
|
||||
return api.getBlob(
|
||||
`/v1/a76/factura-cove/invoices/${invoiceId}/cove/acuse?${params.toString()}`
|
||||
);
|
||||
|
||||
@@ -1332,7 +1332,8 @@
|
||||
try {
|
||||
const blob = await invoicesApi.getCoveReceipt(
|
||||
selectedInvoice.id,
|
||||
companyStore.activeCompany.id
|
||||
companyStore.activeCompany.id,
|
||||
true
|
||||
);
|
||||
const url = URL.createObjectURL(blob);
|
||||
const a = document.createElement('a');
|
||||
|
||||
Reference in New Issue
Block a user