Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Track balances between users based on expenses #23

Closed
IsaacCheng9 opened this issue Jun 21, 2022 · 0 comments · Fixed by #34
Closed

Track balances between users based on expenses #23

IsaacCheng9 opened this issue Jun 21, 2022 · 0 comments · Fixed by #34
Assignees
Labels
backend Requires attention on the backend database Requires a database modification enhancement New feature or request high priority Requires immediate attention

Comments

@IsaacCheng9
Copy link
Owner

IsaacCheng9 commented Jun 21, 2022

Specification

  • We must track the amount of money owed from one user to every other user.
  • To start with, we'll track this in a one-to-one relationship, with each document having the format:
    • from: user1
    • to: user2
    • amount: xyz (£)
  • When adding an expense, the API will update an existing document if it already exists. Otherwise, it will create a new document as necessary (see below).
  • This will be used for the list of group members, as it enables calculations for how much each member owes to one another.
    • For now, adding an expense will only ever increase a debt.
    • Debts will only be subtracted when a user pays off what they owe.

image

@IsaacCheng9 IsaacCheng9 added enhancement New feature or request backend Requires attention on the backend database Requires a database modification labels Jun 21, 2022
@IsaacCheng9 IsaacCheng9 added the high priority Requires immediate attention label Jun 21, 2022
@IsaacCheng9 IsaacCheng9 self-assigned this Jun 21, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backend Requires attention on the backend database Requires a database modification enhancement New feature or request high priority Requires immediate attention
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant