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

Eco updates #783

Merged
merged 9 commits into from
Feb 23, 2023
Merged

Eco updates #783

merged 9 commits into from
Feb 23, 2023

Conversation

caseyhans
Copy link
Collaborator

@caseyhans caseyhans commented Feb 3, 2023

Updates to eco:

  • Adjustments to various form fields on cause and result
  • Added filterset for nestedterm. This requires some python processing, but efficiently returns all ancestors and descendants for a search in a single query, or a few additional

Two additional changes beyond the eco form updates:

  • Added a new helper function for MP_Node querysets to get all ancestors and descendants given a queryset (see hawc.apps.common.models.include_related)
  • Refactored hawc.apps.common.views.BaseFilterList to separate all the FilterSet logic into a self-contained FilterSetMixin that isn't tied to an assessment

@caseyhans caseyhans changed the base branch from main to next February 3, 2023 19:39
@caseyhans caseyhans marked this pull request as ready for review February 6, 2023 14:37
Copy link
Owner

@shapiromatron shapiromatron left a comment

Choose a reason for hiding this comment

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

Great job. The only substantive changes I changed were to lift up some of the changes you made into the common modules, since I think they may be useful beyond eco. I added an include_related function so other MP_Node can get ancestors or descendants, and refactored the BaseFilterList to move all the non-assessment specific FilterSet into a FilterSetMixin so we didn't have to duplicate the code in the eco views

@shapiromatron shapiromatron merged commit df40f79 into next Feb 23, 2023
@shapiromatron shapiromatron deleted the eco-updates branch February 23, 2023 20:36
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