Commit aa0f384c3007c926ea81af054d06adfd5fcb09ec
Exists in
master
and in
29 other branches
Merge branch 'AI2922-wall_tab_by_default' into 'master'
Ai2922 Wall Tab By Default Display the wall tab by default on user's profile
Showing
1 changed file
with
3 additions
and
4 deletions
Show diff stats
app/views/profile/index.rhtml
... | ... | @@ -19,22 +19,21 @@ |
19 | 19 | <table class='profile'> |
20 | 20 | <tr> |
21 | 21 | <td colspan='2'> |
22 | - <% plugins_tabs = @plugins.dispatch(:profile_tabs). | |
23 | - map { |tab| {:title => tab[:title], :id => tab[:id], :content => instance_eval(&tab[:content]), :start => tab[:title]} }%> | |
22 | + <% plugins_tabs = @plugins.dispatch(:profile_tabs).map { |tab| {:title => tab[:title], :id => tab[:id], :content => instance_eval(&tab[:content]), :start => tab[:title]} }%> | |
24 | 23 | |
25 | 24 | <% tabs = plugins_tabs.select { |tab| tab[:start] } %> |
26 | 25 | |
27 | 26 | <% if @profile.organization? %> |
28 | - <% tabs << {:title => _('Profile'), :id => 'organization-profile', :content => (render :partial => 'organization_profile')} %> | |
29 | 27 | <% if logged_in? && current_person.follows?(@profile) %> |
30 | 28 | <% tabs << {:title => _('Wall'), :id => 'profile-wall', :content => (render :partial => 'profile_wall')} %> |
31 | 29 | <% end %> |
30 | + <% tabs << {:title => _('Profile'), :id => 'organization-profile', :content => (render :partial => 'organization_profile')} %> | |
32 | 31 | <% elsif @profile.person? %> |
33 | - <% tabs << {:title => _('Profile'), :id => 'person-profile', :content => (render :partial => 'person_profile')} %> | |
34 | 32 | <% if logged_in? && current_person.follows?(@profile) %> |
35 | 33 | <% tabs << {:title => _('Wall'), :id => 'profile-wall', :content => (render :partial => 'profile_wall')} %> |
36 | 34 | <% tabs << {:title => _('Network'), :id => 'profile-network', :content => (render :partial => 'profile_network')} %> |
37 | 35 | <% end %> |
36 | + <% tabs << {:title => _('Profile'), :id => 'person-profile', :content => (render :partial => 'person_profile')} %> | |
38 | 37 | <% end %> |
39 | 38 | |
40 | 39 | <% tabs += plugins_tabs.select { |tab| !tab[:start] } %> | ... | ... |