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 ability to show only collection applicable nodes in tree #4023

Merged
merged 12 commits into from
Mar 7, 2024

Conversation

CarolineDenis
Copy link
Contributor

Fixes #2051

Copy link
Member

@maxpatiiuk maxpatiiuk left a comment

Choose a reason for hiding this comment

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

Overal good, but in the future I would discourage you from making changes to the same component at the same time in different PRs (this and split tree) - that causes merge conflicts, which are not fan to resolve

@CarolineDenis
Copy link
Contributor Author

@grantfitzsimmons , when you have time could you take a look at this PR on the test panel please?

@CarolineDenis CarolineDenis marked this pull request as ready for review September 21, 2023 13:42
@CarolineDenis CarolineDenis requested a review from a team September 21, 2023 13:42
@CarolineDenis CarolineDenis added this to the 7.9.1 milestone Sep 21, 2023
@grantfitzsimmons grantfitzsimmons changed the base branch from v7.9-dev to production September 26, 2023 02:33
Copy link

@bronwyncombs bronwyncombs left a comment

Choose a reason for hiding this comment

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

With the checkbox selected, the tree still shows nodes that don't have associated objects.

Screen.Recording.2023-10-02.at.10.22.58.AM.mov

URL

@realVinayak
Copy link
Collaborator

@bronwyncombs they are different queries, that's why the result are different. the tree count in tree viewer check for preferred taxon. The query builder (the one you opened in new tab), checks for taxon.

@realVinayak
Copy link
Collaborator

Can this also be tested on some bigger trees like herb_rbge?

@realVinayak
Copy link
Collaborator

Based on #2051, looks like collections want to hide phylums (which is a very high rank). A bit concerned about performance since the query will be more expensive for it. Would need to have performance testing for it. @grantfitzsimmons do you know any other institutions which requested this, on which we can test?

If it becomes a problem,

  1. Merge changes with Begin adding recursive CTE to tree queries #3613
  2. Or make a faster query. In this case, this is possible. Because you don't care how many nodes a particular node, you can modify the stats end-point to use an exists() clause to the sql generated. This would be faster (likely a LOT) since MySQL is smart enough to do a semi-join https://dev.mysql.com/doc/refman/8.0/en/semijoins.html

@grantfitzsimmons
Copy link
Member

grantfitzsimmons commented Oct 2, 2023

Conclusion: Make this run queries on the entire tree once Vinny's count query rework is implemented.

Moving to v7.9.2

@grantfitzsimmons grantfitzsimmons modified the milestones: 7.9.1, 7.9.2 Oct 2, 2023
Copy link
Contributor

@pashiav pashiav left a comment

Choose a reason for hiding this comment

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

issue-2051.mov

Nodes with count 0 are hidden when box is checked. Looks good!

@CarolineDenis CarolineDenis modified the milestones: 7.9.2, 7.9.x Nov 13, 2023
@grantfitzsimmons
Copy link
Member

@CarolineDenis Can this be in 7.9.3?

@grantfitzsimmons grantfitzsimmons modified the milestones: 7.9.x, 7.9.3 Dec 13, 2023
@grantfitzsimmons
Copy link
Member

  1. In the trees, a button for quick filtering of only the nodes with any associated collection object (as indicated by the number in parentheses near the nodes).

Requested By: Eyal at The Hebrew University of Jerusalem

Copy link
Collaborator

@emenslin emenslin left a comment

Choose a reason for hiding this comment

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

Works as expected, looks good.

20231220133522.mp4

Copy link
Member

@grantfitzsimmons grantfitzsimmons left a comment

Choose a reason for hiding this comment

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

Conclusion: Make this run queries on the entire tree once Vinny's count query rework is implemented.

We still haven't implemented this yet, right? In @emenslin's video, counts aren't showing for every node in the tree. I still see this as a requirement (as discussed in our group weeks ago).

@CarolineDenis CarolineDenis modified the milestones: 7.9.3, 7.9.5 Dec 22, 2023
Copy link
Member

@grantfitzsimmons grantfitzsimmons left a comment

Choose a reason for hiding this comment

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

After meeting with @CarolineDenis today, I feel the current implementation is satisfactory. While there may be a request in the future to run the count for all nodes, the behavior is understandable and resolving it is easy. I need to make a note in the documentation before release to clarify behavior to the users.

⚡ Nice work!! Thanks for talking with me about it @CarolineDenis 😄

@CarolineDenis CarolineDenis merged commit 2e3fe4b into production Mar 7, 2024
9 checks passed
@CarolineDenis CarolineDenis deleted the issue-2051 branch March 7, 2024 21:02
@CarolineDenis CarolineDenis modified the milestones: 7.9.5, 7.9.4 Mar 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

Add the ability to only show tree nodes applicable to the selected collection
8 participants