Support Users Directly Uploading Profile Pictures.
* Adds a `picture` attribute to `User`. * Preserves Gravatar as a fallback option. * Now, you should use `user.profile_picturer` instead of `gravatar_url` * TODO: Ensure `profile_picture` handles sizing right for uploaded images.
This commit is contained in:
parent
b66f69599a
commit
3883188dcd
13 changed files with 43 additions and 18 deletions
|
|
@ -4,8 +4,8 @@
|
|||
%meta{ property: "og:description", content: @event.abstract }
|
||||
%meta{ property: "og:site_name", content: (ENV['OSEM_NAME'] || 'OSEM') }
|
||||
- if @speakers_ordered.any?
|
||||
%meta{ property: "og:image", content: @speakers_ordered.first.gravatar_url }
|
||||
%meta{ property: "og:image:secure_url", content: @speakers_ordered.first.gravatar_url }
|
||||
%meta{ property: "og:image", content: @speakers_ordered.first.profile_picture }
|
||||
%meta{ property: "og:image:secure_url", content: @speakers_ordered.first.profile_picture }
|
||||
|
||||
.container
|
||||
.row.page-header
|
||||
|
|
@ -37,7 +37,7 @@
|
|||
.speakerinfo
|
||||
.row
|
||||
.col-md-4
|
||||
= image_tag speaker.gravatar_url(:size => 120), class: 'img-responsive img-rounded'
|
||||
= image_tag speaker.profile_picture(:size => 120), class: 'img-responsive img-rounded'
|
||||
.col-md-8
|
||||
%h4
|
||||
= link_to speaker.name, user_path(speaker.id)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue