-
Notifications
You must be signed in to change notification settings - Fork 6
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
fix(study-tree-ui): fix several bugs and major refactoring #2348
Open
smailio
wants to merge
22
commits into
dev
Choose a base branch
from
fix/615-refactor-folder-logic
base: dev
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+80
−340
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Fix all bugs that are fixed in this PR #2325
Fix a minor bug that wasn't fixed by the former PR : when the user move a study in a default workspace from one folder to the other, the old folder wasn't removed from the UI even if it became empty.
Major refactoring
The flow of the updates changed. There're two ways to receive updates about the tree strcture, either by calling the explorer API or when the state of the backend changed, for instance if a study was added or moved and we receive the new state from the backend. Before this PR these two events were handled differently with different logic.
This PR unify the way we handle new data :
Other major refactoring, we don't use the explorer API to fetch workspaces anymore, we only rely on the study list to compute the workspaces like we used to do a few months ago before the dynamic loading feature.
Before this PR at the loading of the component or when the user click on "root" we would call the explorer API to fetch the list of workspaces, however this never were anything new, because the workspaces don't change often. There's one case where fetching workspace would be usefull :
Handling this case add a lots of complexity to the code and doesn't add much value.