don't group by
This commit is contained in:
parent
85da6d340f
commit
1fe4c3c3de
3 changed files with 2 additions and 16 deletions
|
|
@ -16,8 +16,6 @@ class ContactsController < ApplicationController
|
||||||
else
|
else
|
||||||
@contacts = current_user.contacts.includes(:aspects, :person => :profile).order('profiles.last_name ASC').paginate(:page => params[:page], :per_page => 25)
|
@contacts = current_user.contacts.includes(:aspects, :person => :profile).order('profiles.last_name ASC').paginate(:page => params[:page], :per_page => 25)
|
||||||
end
|
end
|
||||||
|
|
||||||
@contacts_grouped = @contacts.group_by{|contact| contact.person.profile.last_name[0,1]}
|
|
||||||
end
|
end
|
||||||
|
|
||||||
def sharing
|
def sharing
|
||||||
|
|
|
||||||
|
|
@ -35,11 +35,7 @@
|
||||||
|
|
||||||
.span-15
|
.span-15
|
||||||
#people_stream.stream
|
#people_stream.stream
|
||||||
- @contacts_grouped.each do |letter, contacts|
|
- for contact in @contacts
|
||||||
.right.letter
|
|
||||||
%h1
|
|
||||||
= letter
|
|
||||||
- for contact in contacts
|
|
||||||
= render :partial => 'people/person', :locals => {:contact => contact, :person => contact.person}
|
= render :partial => 'people/person', :locals => {:contact => contact, :person => contact.person}
|
||||||
|
|
||||||
= will_paginate @contacts
|
= will_paginate @contacts
|
||||||
|
|
|
||||||
|
|
@ -3007,11 +3007,3 @@ ul#left_nav
|
||||||
:margin 0
|
:margin 0
|
||||||
:display none
|
:display none
|
||||||
|
|
||||||
#people_stream
|
|
||||||
:position relative
|
|
||||||
|
|
||||||
.letter
|
|
||||||
:right -80px
|
|
||||||
h1
|
|
||||||
:color #eee
|
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue