Fixes #37827 - Bring back sync status progress bars on initial page load #11156
+14
−10
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
What are the changes introduced in this pull request?
Seems the code in
app/assets/javascripts/katello/sync_management/sync_management.js
to populate the sync status progress bars was running prematurely, beforeapp/views/katello/sync_management/index.html.erb
had a chance to populate the data. I moved it into a function and now run it right when we need it. The effect should be that the progress bars return to the page, even on initial page load. The second effect is that the "Active only" checkbox becomes useful again, because its function is to show you only the rows that have those progress bars.Considerations taken when implementing this change?
I barely understand any of this ancient code so please tell me if I did something wrong lol
What are the testing steps for this pull request?
Get some really big, slow-syncing repos
Go to the sync_management page
Hit Select All (and optionally Expand All, if you want to see what you've selected)
Click Synchronize Now and immediately refresh the browser page
On page load, you should now see the progress bars (before you'd just see the task status - "Running" etc.)
Also, the "Active only" checkbox should work.