|
|
@ -14,8 +14,7 @@ module Admin |
|
|
|
@statuses = @account.statuses.where(visibility: [:public, :unlisted]) |
|
|
|
@statuses = @account.statuses.where(visibility: [:public, :unlisted]) |
|
|
|
|
|
|
|
|
|
|
|
if params[:media] |
|
|
|
if params[:media] |
|
|
|
account_media_status_ids = @account.media_attachments.attached.reorder(nil).select(:status_id).group(:status_id) |
|
|
|
@statuses.merge!(Status.joins(:media_attachments).group(:id)) |
|
|
|
@statuses.merge!(Status.where(id: account_media_status_ids)) |
|
|
|
|
|
|
|
end |
|
|
|
end |
|
|
|
|
|
|
|
|
|
|
|
@statuses = @statuses.preload(:media_attachments, :mentions).page(params[:page]).per(PER_PAGE) |
|
|
|
@statuses = @statuses.preload(:media_attachments, :mentions).page(params[:page]).per(PER_PAGE) |
|
|
|