update expense

This commit is contained in:
2026-05-25 13:07:41 -05:00
parent dc3064acc6
commit f535f35eee
5 changed files with 243 additions and 17 deletions

View File

@@ -169,6 +169,12 @@ const API = {
body: JSON.stringify(data)
}).then(r => r.json()),
updateExpense: (id, data) => fetch(`/api/accounting/expenses/${id}`, {
method: 'PUT',
headers: { 'Content-Type': 'application/json' },
body: JSON.stringify(data)
}).then(r => r.json()),
attachToExpense: (expenseId, file, note) => {
const fd = new FormData();
fd.append('file', file);