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

SW-261: Return to datatable and change CSV or columns #33

Merged
merged 8 commits into from
Nov 5, 2024
Merged

Conversation

wheelsandcogs
Copy link
Collaborator

@wheelsandcogs wheelsandcogs commented Oct 29, 2024

Users can now return to the datatable summary:

Screenshot 2024-10-30 at 11 58 34

And then choose to either change the upload or the column source assignment:
Screenshot 2024-10-30 at 11 58 39

Other changes:

Dataset is fetched upfront by middleware
There's a new middleware fetchDataset that calls the api to get a dataset with all currently available relations hydrated before each route executes. This simplifies having to worry about what to fetch in most cases. If we find that the response starts becoming too big or slow, we can look at making some of the relations optional, but currently it's like 20-30ms so I'm not expecting this to be an issue.

Most GET/POST routes are now handled by the same controller
e.g.

publish.get('/title', provideTitle);
publish.post('/title', upload.none(), provideTitle);

We generally need the same or similar things for displaying the original page and errors after a form submit, so this reduces the amount of code duplication a fair bit.

@wheelsandcogs wheelsandcogs changed the title WIP: SW-261: Return to datatable and change CSV or columns SW-261: Return to datatable and change CSV or columns Oct 30, 2024
@wheelsandcogs wheelsandcogs merged commit b4a8195 into main Nov 5, 2024
3 of 4 checks passed
@wheelsandcogs wheelsandcogs deleted the SW-261 branch November 5, 2024 11:48
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

Successfully merging this pull request may close these issues.

2 participants