Closed djudjuu closed 3 years ago
This pull request is being automatically deployed with Vercel (learn more).
To see the status of your deployment, click below or on the icon next to each commit.
🔍 Inspect: https://vercel.com/arboreum/frontend/r5q2ynowj
✅ Preview: https://frontend-git-dju-transactions.arboreum.vercel.app
[update in progress for 5841b2c]
Looks good to merge once we resolve the id column issue
closes #44
[x] a table to store transactions
[x] deposit & withdraw functions that adjist user-balances and create a matching transaction in the same mutation
[x] adjusted helper function that does batch updates to also create batch-transactions
[x] adding queries to display transaction history (loan, deposit, withdraw related) in lender and borrower dashboards
[x] tests
[x] #62 should be reviewed & merged first
context for design decisions
the PK for the tx-table is an int...and not a uuid... I thought it would be nice if we could very easily see which transaction came first and it would be handy to impose an ordering on the txs a user does....a little later I realized that the same could be achieved with created_at...I dont see a downside of having the PK be a tx though....
Open question: