2014-04-16 08:44:36 +00:00
|
|
|
<div id="user-profile">
|
|
|
|
<h1 class="fancy">
|
|
|
|
<span><%= @user.username %></span>
|
|
|
|
</h1>
|
2014-03-23 00:22:25 +00:00
|
|
|
|
2014-04-16 08:44:36 +00:00
|
|
|
<div class="photo">
|
|
|
|
<%= image_tag @user.profile.avatar.url %>
|
|
|
|
</div>
|
2014-03-23 00:22:25 +00:00
|
|
|
|
2014-04-16 08:44:36 +00:00
|
|
|
<div class="tabs tabbed">
|
|
|
|
<ul id="user-nav" class="tabs">
|
2014-04-19 01:12:02 +00:00
|
|
|
<li class="activeli"><a id="general">General</a></li>
|
2014-03-23 00:22:25 +00:00
|
|
|
|
|
|
|
<% if @user.teamers.past.count > 0 %>
|
2014-04-16 08:44:36 +00:00
|
|
|
<li><a id="teams">Teams</a></li>
|
2014-03-23 00:22:25 +00:00
|
|
|
<% end %>
|
|
|
|
|
|
|
|
<% if @user.match_teams.count > 0 %>
|
2014-04-16 08:44:36 +00:00
|
|
|
<li><a id="matches">Matches</a></li>
|
2014-03-23 00:22:25 +00:00
|
|
|
<% end %>
|
|
|
|
|
|
|
|
<% if @user.predictions.count > 0 %>
|
2014-04-16 08:44:36 +00:00
|
|
|
<li><a id="predictions">Predictions</a></li>
|
|
|
|
<% end %>
|
|
|
|
|
|
|
|
<% if @user.articles.count > 0 %>
|
|
|
|
<li><a id="articles">Articles</a></li>
|
2014-03-23 00:22:25 +00:00
|
|
|
<% end %>
|
|
|
|
|
2014-04-16 08:44:36 +00:00
|
|
|
<% if @user.movies.count > 0 %>
|
|
|
|
<li><a id="movies">Movies</a></li>
|
|
|
|
<% end %>
|
2014-03-23 00:22:25 +00:00
|
|
|
|
2014-04-16 08:44:36 +00:00
|
|
|
<li><a id="comments">Comments</a></li>
|
|
|
|
</ul>
|
2014-03-23 00:22:25 +00:00
|
|
|
|
2014-04-16 08:44:36 +00:00
|
|
|
<div id="user-data" class="tabbed-contents">
|
2014-03-23 00:22:25 +00:00
|
|
|
<%= render :partial => "general" %>
|
2014-04-16 08:44:36 +00:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<% if cuser and @user.can_update? cuser %>
|
|
|
|
<%= link_to 'Edit', edit_user_path(@user), class: 'button' %>
|
|
|
|
<%= link_to 'My Agenda', "/users/agenda/#{cuser.id}", class: 'button' %>
|
|
|
|
<% end %>
|
|
|
|
</div>
|
|
|
|
|