Battery-Intelligence-Lab / galv

An open-source platform for automated storage of battery data with advanced metadata support
https://battery-intelligence-lab.github.io/galv/
Other
33 stars 8 forks source link

Tiered frontend dataset management #117

Closed BradyPlanden closed 1 year ago

BradyPlanden commented 1 year ago

At the moment, the datasets for all monitored paths are displayed in a flat orientation. This makes it quite difficult to navigate between datasets in addition to losing directory context that is attached to the monitored path (i.e. BradyData/ would be lost to the user).

I'm proposing we migrate to a tiered structure that mirrors the monitored path directories like the following:

I took a quick look at the frontend src/ - I think the changes would centre around Datasets.tsx (although I am unfamiliar with React). How does this sound @mjaquiery @martinjrobins @davidhowey?

martinjrobins commented 1 year ago

The datasets are currently viewed as a table, implemented here (https://github.com/Battery-Intelligence-Lab/galv/blob/main/frontend/src/AsyncTable.tsx). Would it be useful to implement sorting by individual columns, something like this: https://mui.com/material-ui/react-table/#system-EnhancedTable.tsx

That way the user can just pick how they want the datasets sorted, either via path directory, or file name, or something else

BradyPlanden commented 1 year ago

Thanks for the information Martin. I think that could do the trick, specifically looking at the collapsible table functionality. If each major row could be the monitored path directory with the datasets collapsible, that would provide the user with an easy way to filter and sort the datasets.

I'm not sure I follow the sorting by individual columns, would each column contain metadata from the dataset or monitored path information?

martinjrobins commented 1 year ago

I just mean you click on the title of the column, to sort the table by that column: e.g. this demo, try clicking on any of the column headers. I forget what all our headers are, but some of them could be "monitored path", "file type" "cell" etc.

mjaquiery commented 1 year ago

A consequence of the reshuffle where we took Monitored Paths out of the data heirarchy is that a Dataset is no longer guaranteed to have one and only one Monitored Path. Any sorting solution will have to work with that.

Filtering by name is something we can implement, for example, as is moving datasets to inside Monitored Paths (or, more realisitically, to inside Observed Files, so that you can 'inspect' an Observed File to see its dataset). The issues there are redundancy (if we keep the current Dataset browser page as well) or difficulty going from login to the dataset you're looking for (if we remove the current Dataset page).

We could have a quick online meeting to hash out some ideas, perhaps, or @BradyPlanden could ask around colleagues in the lab to get some preferences on how they'd actually want to use the site and we'll alter it accordingly :)

P.S. Currently, we mimic collapsible tables by injecting table rows that has one column spread over the whole row and contains whatever child data we want to inject. It's the subrow part of the AsyncTable and it's used for pretty much all of those 'inspect' actions. It's a workaround to stop you having to scroll to the bottom to see the details on the thing you selected!

mjaquiery commented 1 year ago

Covered by #118