Link source expense/invoice from account transaction rows
Deploy to LXC / deploy (push) Successful in 1m56s
Validate / validate (push) Successful in 35s

Each transaction that was posted from an expense or invoice now shows
an 'Open expense →' or 'Open invoice →' link to the source record's
detail page. The sourceExpenseId/sourceInvoiceId fields were already
loaded — just needed the UI affordance.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-04-21 14:10:07 +07:00
parent 06ae314b3c
commit b4338c6814
@@ -347,6 +347,22 @@
Counterparty: {txn.counterpartyName}
</div>
{/if}
{#if txn.sourceExpenseId}
<a
href={`/companies/${data.company.id}/expenses/${txn.sourceExpenseId}`}
class="mt-0.5 inline-block text-xs font-medium text-blue-600 hover:text-blue-700 dark:text-blue-400"
>
Open expense →
</a>
{/if}
{#if txn.sourceInvoiceId}
<a
href={`/companies/${data.company.id}/invoices/${txn.sourceInvoiceId}`}
class="mt-0.5 inline-block text-xs font-medium text-blue-600 hover:text-blue-700 dark:text-blue-400"
>
Open invoice →
</a>
{/if}
{#if txn.fxRate && txn.fxAmount}
<div class="text-xs text-amber-600 dark:text-amber-400">
FX: {txn.fxAmount} @ {Number(txn.fxRate).toFixed(4)}