-
Notifications
You must be signed in to change notification settings - Fork 65
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
Fixes #27331 - Fix pagination on policy dashboard #401
Conversation
rubocop needs some updates, feel free to add additional commit to this PR, I'll merge at once |
There were the following issues with the commit message:
If you don't have a ticket number, please create an issue in Redmine. More guidelines are available in Coding Standards or on the Foreman wiki. This message was auto-generated by Foreman's prprocessor |
There are still some rubocop failures :-(
|
There were the following issues with the commit message:
If you don't have a ticket number, please create an issue in Redmine. More guidelines are available in Coding Standards or on the Foreman wiki. This message was auto-generated by Foreman's prprocessor |
@@ -11,7 +11,7 @@ | |||
<th><%= _("Other") %></th> | |||
<th><%= _('Actions') %></th> | |||
</tr> | |||
<% @policy.arf_reports.latest.each do |arf_report| %> | |||
<% @latest_reports.each do |arf_report| %> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
doesn't this reintroduce the behavior changed by #377 ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It does revert this particular line, but I cannot remember why it was changed in the first place. It should return the same results though as it calls latest
scope for the reports belonging to a policy, I added a test. The only difference is @policy.arf_reports.latest
gives me undefined method 'total_entries' for #<ForemanOpenscap::ArfReport::ActiveRecord_AssociationRelation:0x007efd8d475b58>
so I cannot paginate on that.
There were the following issues with the commit message:
If you don't have a ticket number, please create an issue in Redmine. More guidelines are available in Coding Standards or on the Foreman wiki. This message was auto-generated by Foreman's prprocessor |
Thanks make sense, fixes the issue. Merging! |
No description provided.