Atualizar web/chat.js

This commit is contained in:
2026-08-19 21:51:24 -03:00
parent 43544c4c22
commit 91d835e6f0
+5 -2
View File
@@ -45,17 +45,20 @@ async function importExcel() {
const form = new FormData(); const form = new FormData();
form.append("file", file); form.append("file", file);
await fetch(`/api/import_excel/${conversationId}`, {
const r = await fetch(`/api/import_excel/${conversationId}`, {
method: "POST", method: "POST",
body: form body: form
}); });
const data = await r.json();
console.log("Imported sheets:", data.sheets);
await loadHistory(); await loadHistory();
} }
async function loadConversations() { async function loadConversations() {
const r = await fetch("/api/conversations"); const r = await fetch("/api/conversations");
conversations = await r.json(); conversations = await r.json();