| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
There was a problem hiding this comment.
Sorry, something went wrong.
There was a problem hiding this comment.
except minor suggestion everything else works well.
Sorry, something went wrong.
| Back | FazBrowse Home | New Git URL |
Aim
To create an option in the file component viewer to only see the files in the current dataset
Methodology
The difficulty behind the task is because the datasetID depends on which dataset the extractor is called from and therefore can not be hardcoded into the extractor_info json. In order to bypass, this we use the property uiSchema (that I have previously misunderstood) and "ui:options".
uiSchema is actually used to format a given input and is dependent on the parameter name. ui:options allows us to pass in the datasetID as a field. Since the uiSchema uses parameter names I use a for loop to iterate through the form's parameters and add to the uiSchema
The rest of the changes are pretty straightforward. It involves passing in the datasetID and a flag to only show the dataset files or the entire filesystem.
How to test
Run an extractor, I used wordcount , locally as in to do the necessary modifications:
When you open the extractor and open the fileselector, you should only see the current folders and files in the dataset

Re-run the extractor but tis time set the field "showOnlyDatasetFiles" to false or remove it
You should then see the complete clowder filesystem
