feat: add treasury audit, attachment download, and installment SMS

Let cheque clearance pick a cash account and export income, expense, and installment lists to Excel.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
2026-10-18 19:59:24 +03:30
co-authored by Cursor
parent 8981a552fc
commit 96befd3867
11 changed files with 285 additions and 21 deletions
@@ -51,6 +51,16 @@ async function load() {
accounts.value = acc.data.filter((row) => row.isActive);
}
async function downloadExcel() {
const { data } = await api.get<Blob>('/treasury/receivables/export', { responseType: 'blob' });
const url = URL.createObjectURL(data);
const link = document.createElement('a');
link.href = url;
link.download = 'installments.xlsx';
link.click();
URL.revokeObjectURL(url);
}
async function createContract() {
saving.value = true;
error.value = '';
@@ -148,6 +158,7 @@ onMounted(() => {
<UiButton variant="secondary" @click="customLines.push({ amount: '', dueDate: '' })">قسط دیگر</UiButton>
</div>
<UiButton :loading="saving" @click="createContract">ساخت اقساط</UiButton>
<UiButton variant="secondary" @click="downloadExcel">خروجی اکسل</UiButton>
</UiCard>
<article v-for="row in rows" :key="row.id" class="contract">