Skip to content
Permalink
Browse files

FIX: Loading more broken on groups page.

Regressed in 1f17d52.
  • Loading branch information...
tgxworld committed Apr 30, 2019
1 parent 75a6c44 commit dca7f8ecf23286f72f8347509eb4e1a2464e02ae
@@ -23,11 +23,11 @@

{{#if model}}
{{#conditional-loading-spinner condition=model.loading}}
{{#load-more selector=".groups-table .groups-table-row" action=(action "loadMore")}}
{{#load-more selector=".groups-boxes .group-box" action=(action "loadMore")}}
<div class='container'>
<div class="groups-boxes">
{{#each model as |group|}}
{{#link-to "group.members" group.name class="group-box"}}
{{#link-to "group.members" group.name class="group-box"}}
<div class="group-box-inner">
<div class="group-info-wrapper">
{{#if group.flair_url}}
@@ -39,13 +39,13 @@
groupName=group.name}}
</span>
{{/if}}
<span class="group-info">
{{groups-info group=group}}

<div class="group-user-count">{{d-icon "user"}}{{group.user_count}}</div>
</span>
</div>
<span class="group-info">
{{groups-info group=group}}

<div class="group-user-count">{{d-icon "user"}}{{group.user_count}}</div>
</span>
</div>

<div class="group-description">{{{group.bio_excerpt}}}</div>

@@ -77,7 +77,7 @@
{{/group-membership-button}}
</div>
</div>
{{/link-to}}
{{/link-to}}
{{/each}}
</div>
</div>
@@ -1,4 +1,6 @@
class GroupsController < ApplicationController
include ApplicationHelper

requires_login only: [
:set_notifications,
:mentionable,
@@ -42,7 +44,7 @@ def index
raise Discourse::InvalidAccess.new(:enable_group_directory)
end

page_size = 30
page_size = mobile_device? ? 15 : 36
page = params[:page]&.to_i || 0
order = %w{name user_count}.delete(params[:order])
dir = params[:asc] ? 'ASC' : 'DESC'

1 comment on commit dca7f8e

@discoursebot

This comment has been minimized.

Copy link

commented on dca7f8e Apr 30, 2019

This commit has been mentioned on Discourse Meta. There might be relevant details there:

https://meta.discourse.org/t/give-groups-and-tags-some-love/113783/20

Please sign in to comment.
You can’t perform that action at this time.