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

Display recursive search result #2

Closed
qtipee opened this issue Oct 29, 2019 · 5 comments
Closed

Display recursive search result #2

qtipee opened this issue Oct 29, 2019 · 5 comments
Assignees

Comments

@qtipee
Copy link
Collaborator

qtipee commented Oct 29, 2019

Display the files in a tree form so that the user can check the uploaded content. This view will then be useful to add some properties to specific files : e.g. add external link (if the file is hosted on another server), auto-download this file (in the cache), ...

@qtipee qtipee added the todo Something to implement label Oct 29, 2019
@qtipee qtipee self-assigned this Oct 29, 2019
@qtipee
Copy link
Collaborator Author

qtipee commented Oct 29, 2019

For now, the « tree » is just a list of the uploaded files with their webkitRelativePath ; need to find a solution to generate the tree structure.

@qtipee
Copy link
Collaborator Author

qtipee commented Oct 30, 2019

Maybe found the solution : when uploading a root folder containing some audio files and subfolders also containing audio files, it seems that the FileList is hierarchically sorted ; this property could be used to build the tree structure in the app.

Screenshot 2019-10-30 at 16 33 57

@qtipee
Copy link
Collaborator Author

qtipee commented Oct 30, 2019

I managed to store all the uploaded files in a Map, where they key is the webkitRelativePath and the value an array of files ; every file with the same webkitRelativePath is stored in the same key.

Screenshot 2019-10-30 at 20 20 10

@qtipee
Copy link
Collaborator Author

qtipee commented Nov 4, 2019

Managed to build a map with the uploaded files that keeps the tree structure. However, I'm not sure I implemented it the better way ; I will open an issue for this possible improvement.

@qtipee
Copy link
Collaborator Author

qtipee commented Nov 5, 2019

The application can now rebuild the hierarchical tree structure of the uploaded files. See issue #3 for possible improvement.

@qtipee qtipee closed this as completed Nov 5, 2019
@qtipee qtipee removed the todo Something to implement label Nov 6, 2019
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

No branches or pull requests

1 participant