diff --git a/app/views/projects/_project.html.erb b/app/views/projects/_project.html.erb index e6c1a7d2..c39e4ce0 100644 --- a/app/views/projects/_project.html.erb +++ b/app/views/projects/_project.html.erb @@ -21,6 +21,9 @@
  • <%= link_to ' '.html_safe + "Install", project.install_url, :target => '_blank' if project.install_url.present? %>
  • <%= link_to ' '.html_safe + "Tasks", project.tasks_url, :target => '_blank' if project.tasks_url.present? %>
  • <%= link_to ' '.html_safe + "Help", project.help_url, :target => '_blank' if project.help_url.present? %>
  • +
  • + <%= render partial: 'project_social', locals: { project: project } %> +
  • diff --git a/app/views/projects/_project_social.html.erb b/app/views/projects/_project_social.html.erb new file mode 100644 index 00000000..ebe4ce0f --- /dev/null +++ b/app/views/projects/_project_social.html.erb @@ -0,0 +1,9 @@ +<% if project.twitter.present? %> + + Share on Twitter + +<% elsif project.organization.twitter.present? %> + + Share on Twitter + +<% end %> \ No newline at end of file diff --git a/app/views/projects/show.html.erb b/app/views/projects/show.html.erb index bdf1f4a0..5877f039 100644 --- a/app/views/projects/show.html.erb +++ b/app/views/projects/show.html.erb @@ -42,6 +42,10 @@
    <%= link_to image_tag(find_logo(@project.organization), :alt => @project.organization.name), @project.organization.url, :target => '_blank' if find_logo?(@project.organization) %> + +
    + <%= render partial: 'project_social', locals: { project: @project } %> +
    Causes