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

Add claimed_budget and utilised_budget to model and ui #149

Merged
merged 8 commits into from
Oct 13, 2023

Conversation

pxwxnvermx
Copy link
Contributor

@pxwxnvermx pxwxnvermx commented Oct 5, 2023

@pxwxnvermx pxwxnvermx self-assigned this Oct 5, 2023
Copy link
Collaborator

@calellowitz calellowitz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nothing blocking, but I think there is a redundant clause in one of the queries

@property
def approved_visits(self):
approved_user_visits = (
UserVisit.objects.filter(opportunity=self, status=VisitValidationStatus.approved)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this is redundant. It counts only approved visits and excludes over_limit, but since a visit can't be both, we don't need the exclude statement.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Removed. 76ef45b

@pxwxnvermx pxwxnvermx merged commit cd91f26 into main Oct 13, 2023
2 checks passed
@pxwxnvermx pxwxnvermx deleted the pkv/web-ui-budget-tracking branch October 13, 2023 04:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants