From fe6dcffa8f7ad7c66ea210adf8ed72a7fe4007c2 Mon Sep 17 00:00:00 2001 From: Maxwell Salzberg Date: Mon, 14 May 2012 16:33:56 -0700 Subject: [PATCH] remove cubbies from sidebar, also add invite code directly to sidebar to make even clearer --- app/helpers/invitation_codes_helper.rb | 2 +- app/views/shared/_invitations.haml | 10 +++------- app/views/shared/_right_sections.html.haml | 9 --------- 3 files changed, 4 insertions(+), 17 deletions(-) diff --git a/app/helpers/invitation_codes_helper.rb b/app/helpers/invitation_codes_helper.rb index 574ef66dc..cb7c93cbf 100644 --- a/app/helpers/invitation_codes_helper.rb +++ b/app/helpers/invitation_codes_helper.rb @@ -17,7 +17,7 @@ module InvitationCodesHelper end def invite_link(invite_code) - text_field_tag :invite_code, invite_code_url(@invite_code), :readonly => true + text_field_tag :invite_code, invite_code_url(invite_code), :readonly => true end def invited_by_message diff --git a/app/views/shared/_invitations.haml b/app/views/shared/_invitations.haml index 502f5c423..44df0db2f 100644 --- a/app/views/shared/_invitations.haml +++ b/app/views/shared/_invitations.haml @@ -1,7 +1,3 @@ -- if AppConfig.configured_services.include?('facebook') - - if defined? remote - = link_to t('.from_facebook'), friend_finder_path('facebook', :remote => remote) - -else - = link_to t('.from_facebook'), friend_finder_path('facebook') - %br -= link_to t('.by_email'), new_user_invitation_path, :title => t('.invite_someone'), :rel => 'facebox' +Share this link via email, blog, or favorite social network! += invite_link(current_user.invitation_code) += link_to t('.by_email'), new_user_invitation_path, :title => t('.invite_someone'), :rel => 'facebox' \ No newline at end of file diff --git a/app/views/shared/_right_sections.html.haml b/app/views/shared/_right_sections.html.haml index 3d2c4894d..fe530ffaa 100644 --- a/app/views/shared/_right_sections.html.haml +++ b/app/views/shared/_right_sections.html.haml @@ -12,15 +12,6 @@ .content = render "shared/invitations" -- unless has_connected_cubbies? - .section - .title - = image_tag('icons/cubbies.png') - %h5 - = t('aspects.index.cubbies.heading') - .content - = t('aspects.index.cubbies.explanation') - = link_to t('aspects.index.cubbies.learn_more'), token_path .section .title = image_tag('icons/heart.png')