mirror of
https://github.com/Comfy-Org/ComfyUI_frontend.git
synced 2026-02-04 23:20:07 +00:00
## Summary Active jobs (pending/running) in the media assets panel now display in FIFO order - oldest jobs first (first to be processed at top). This matches the queue processing order and the old queue panel behavior. ## Changes - **AssetsSidebarListView.vue**: Add `.toReversed()` to `activeJobItems` computed to reverse job order for display - **AssetsSidebarGridView.vue**: Same change for grid view consistency - **AssetsSidebarListView.test.ts**: Unit test verifying oldest-first ordering ## Root Cause PR #8225 changed sorting from `queueIndex` to `createTime` descending in `useJobList.ts`, which placed newest jobs first. For active jobs, users expect oldest first (FIFO - first to be processed appears at top). ## Solution Rather than modifying the shared `useJobList` composable (which serves both the assets panel and queue overlay), the fix applies `.toReversed()` at the view layer for the active jobs section only. This: - Preserves the newest-first order for completed/history jobs - Displays active jobs in oldest-first order - Maintains backward compatibility with the queue overlay ## Testing - Unit test added to verify FIFO ordering of active jobs - All existing `useJobList` tests pass Fixes COM-14151 <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **Bug Fixes** * Corrected the display order of active jobs in the sidebar to show jobs in oldest-first (FIFO) sequence. * **Tests** * Added unit tests for the assets sidebar list view to verify job ordering and filtering behavior. <!-- end of auto-generated comment: release notes by coderabbit.ai --> ┆Issue is synchronized with this [Notion page](https://www.notion.so/PR-8561-fix-display-active-jobs-in-oldest-first-order-in-media-assets-panel-2fc6d73d365081c6bf31cb076a8d6014) by [Unito](https://www.unito.io)