Skip to content

Support for structured payee-based links in the memo field of transactions

Ralf Habacker requested to merge work/437481-payee-link-support into master

With the commits from this merge request, parts of the memo field of a transaction can be linked to a remote or local URL with invoices or other documents.

For this purpose, payees are extended with a new tab called "Link Matching", which contains input fields to link parts of the memo text to remote or local URLs.

grafik

The parts of the memo field are extracted via regular expressions and incorporated into the URL template, which are then displayed in the general ledger for matching transactions

grafik

and accessed via a transaction's context menu or keyboard shortcuts.

grafik

For accounts that are queried online, for example, this automatically provides a link to the corresponding invoice or other documents, and for the rest of the accounts after entering a corresponding invoice number or identification text in the memo field.

For linking to locally stored documents, the corresponding URL templates can contain regular expressions and variables to allow finding files whose full filename cannot be easily determined. The variable currently available is the year from the transaction.

Fixes https://bugs.kde.org/show_bug.cgi?id=437481

Hints

  1. Recognized links for transactions in the ledger are visible if "View"->"Show transaction detail" is activated in the menu.

Extensions

  1. Since working with regular expressions is often too complicated for end users, an extension is being considered that provides predefined invoice sources that can be selected by users instead. If a source does not fit, there is the possibility to adjust it manually. These predefined invoice sources could be managed centrally so that users receive changes automatically.
  2. Caching of generated urls to reduce the number of processed regular expressions (proposal by @tbaumgart) - there is a remaining issue how to show the link in the ledger without regular expressions as the link tag(s) needs to be inserted into the memo field. (Thomas has found a another way for this)
Edited by Ralf Habacker

Merge request reports