Files
front-AT/app/lib/postReceipt.ts
T

16 lines
390 B
TypeScript
Raw Normal View History

2025-09-19 17:20:05 -06:00
import apiClient from "./apiClient";
export async function PostReceipt(data: any) {
try {
const response = await apiClient.post("/recibo", data);
console.log(response.data);
return response.data;
} catch (error: any) {
const msg =
error.response?.data?.message ||
error.message ||
"Error desconocido al crear recibo";
return { error: msg };
}
}