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

feat: browse queue history #697

Merged
merged 1 commit into from
Dec 26, 2024
Merged

feat: browse queue history #697

merged 1 commit into from
Dec 26, 2024

Conversation

henrychoy
Copy link
Collaborator

In the edit queue dialog, add view history toggle to browse snapshots. Latest snapshot will be selected by default. Click or tab over to the list, and then you can use up/down arrow keys. Submit button will be disabled when viewing history.

Timestamps are currently all the same because snapshots inherit timestamp from the parent resource, this will be fixed separately.

Copy link
Collaborator

@keithmanville keithmanville left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I believe the GET for snapshots is only retrieving a single page of results, so if you have more than 10 snapshots, you only get the 10 oldest ones in the list.

Is it possible to retrieve the first page ordered by date descending, and then if the user scrolls down, it retrieves additional pages as needed?

@henrychoy
Copy link
Collaborator Author

I believe the GET for snapshots is only retrieving a single page of results, so if you have more than 10 snapshots, you only get the 10 oldest ones in the list.

Is it possible to retrieve the first page ordered by date descending, and then if the user scrolls down, it retrieves additional pages as needed?

Thanks for catching this. As discussed on the call, we're going to have the snapshot list GET ALL results for now, and in a future task I can look into adding a sort option and/or loading more on scroll.

This commit adds a new UI element that allows the user to browse the history of a queue resource.
In the edit queue dialog, click the view history toggle to browse snapshots.  The Latest snapshot
will be selected by default. Click or tab over to the list, and then you can use up/down arrow
keys. Submit button will be disabled when viewing history.

feat: simplify snapshot list

fix: hide history toggle for drafts

fix: form edits should be cleared when toggling on history

fix: widen width of history column

fix: use snapshotCreatedOn for timestamp

fix: getSnapshots should get all results, not just first page
@keithmanville keithmanville merged commit b0b7a25 into dev Dec 26, 2024
11 checks passed
@keithmanville keithmanville deleted the queue-history branch December 26, 2024 18:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants