Sha256: 0ff1838a67521e58634ffb41da575ec104b8f04597f8bdc657e4b0cbe030e220

Contents?: true

Size: 1.58 KB

Versions: 1

Compression:

Stored size: 1.58 KB

Contents

<%= menu_options[:like] || capture do %>
  <li>
    <div class="verb_like" id="like_<%= dom_id(subject) %>">
      <%= link_like(subject)%>
    </div>
  </li>
<% end %>

<%= menu_options[:contacts] || capture do %>
  <!-- TODO: create helper -->
  <% if user_signed_in? %>
    <% if current_subject.ties_to(subject).present? %>
      <li >
      <%= link_to image_tag("btn/btn_friend.png", :class => "menu_icon")+t('tie.edit.contact', :type => current_subject.ties_to(subject).first.relation_name), edit_tie_path(current_subject.ties_to(subject).first) %>
     </li>
    <% else %>
      <li >
      <%= link_to(image_tag("btn/btn_friend.png", :class => "menu_icon")+t('tie.add.contact'), '#', :id => 'contacts_menu') %>
        <ul>
          <% current_subject.relations.sort.each do |r| %>
            <li>
            <%= link_to image_tag("btn/twitter-follow-icon.png", :size => "19x19", :class => "menu_icon") + r.name,
                        ties_path('tie[sender_id]'   => current_subject.actor_id,
                                  'tie[receiver_id]' => subject.actor_id,
                                  'tie[relation_id]' => r.id),
                        :method => :post   %>
            </li>

          <% end %>
          <li>
          <%= link_to image_tag("btn/twitter-follow-icon.png", :size => "19x19", :class => "menu_icon") + t('tie.relation.new'),
                      new_tie_path('tie[sender_id]'   => current_subject.actor_id,
                                   'tie[receiver_id]' => subject.actor_id) %>
          </li>
        </ul>
      </li>
    <% end %>
  <% end %>
<% end %>


Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
social_stream-0.4.4 app/views/subjects/_toolbar_profile_menu_tie_options.html.erb