I've already done a bit of work on this but want to know if the change is welcome before I continue.
There are links between and within pages (e.g graph points) that go to the transaction. Sadly the transactions are reference by their date rather than their unique id. See that link below.
The whole thing isn't an issue as the transactions are well-ordered by date on every single report page I've seen, but I'm keen to add a table sorter plugin to allow sorting by columns other than date. And then the non-unique links will be a massiv issue.
As I said, I've done a bit of work to make use of the unique ids resulting in links like this one:
http://localhost:5000/register?q=inacct%3AExpenses#351 with 351 being the transaction id.
Now my question, is this change welcome by everyone or are there url-hackers out there who insist on putting the date stamp into the url manually (in my eyes the only reason why not to do this change)?
One side note, the in-page-links use the id attribute on tags and those are required to be unique as per the HTML standard.
Dates were used only because we don't have a good story for transaction ids yet.
What will you use.. the transaction's position in the parse stream ? (Remember there may be multiple files).
I'm a haskell noob but found tindex Transaction which (for a ruby dev) looked good enough. But a quick check, yes multiple files lead to same ids. I won't be getting access to the journal (id or name) from the transaction, right?
Something like 1-23 and 2-23 for item 23 on journals 1 and 2 could be a decent unique id.
wouldn't it be smarter to use metadata tags like
2015-12-20 * Tom's Tractor Service ; uuid: 762563-786727-uy2362-2i3u39
those do exist? how can I access them?
they don't exist outta-the-box, but there are many arguments for a unique-identifier per-txn.
For this to work, some uuid generator/tester would have to be added
this would work well for taskwarrior --> *ledger workflow, adopting the tw uuid.
Those exist if you add them manually, and would be stored in Transaction's ttags field.
The tindex field is our current approximation of a unique transaction id that's always availiable. As you can see it's currently just an index and can change due to file edits. Still, even this kind of weak id is quite helpful. So far, it's used by hledger-ui for next/prev transaction.
tindex is supposed to be unique across included files, and this should be fixed.
web: use transaction indexes instead of the date for html tag ids #308