Skip to content

Commit

Permalink
Issue #200 Editing right side bar
Browse files Browse the repository at this point in the history
  • Loading branch information
Mohab authored and Mohab committed Apr 23, 2014
1 parent 015c677 commit 2768f18
Showing 1 changed file with 21 additions and 19 deletions.
40 changes: 21 additions & 19 deletions tutor/app/views/layouts/_right_side_bar.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -4,22 +4,24 @@
# Author: Ahmed Elassuty
-->
<div id="right_side_bar" class="well pull-right side-right" style="width:25%">
<% recommended_problems = current_student.getClassMatesRecommendations
if recommended_problems != nil then %>
<table class="table table-striped table-bordered table-responsive">
<caption><b>Recommendations by classmates<b></caption>
<% recommended_problems.each do |key , value| %>
<tr>
<td>
<%= value["recommender_name"] %>
</td>
<td>
<%= link_to value["problem_title"], controller: "problems", action: "show", id: key %>
</td>
</tr>
<% end %>
</table>
<% end %>


</div>
<% if student_signed_in? %>
<div>
<% recommended_problems = current_student.getClassMatesRecommendations
if recommended_problems != nil then %>
<table class="table table-striped table-bordered table-responsive">
<caption><b>Recommendations by classmates<b></caption>
<% recommended_problems.each do |key , value| %>
<tr>
<td>
<%= value["recommender_name"] %>
</td>
<td>
<%= link_to value["problem_title"], controller: "problems", action: "show", id: key %>
</td>
</tr>
<% end %>
</table>
<% end %>
</div>
<% end %>
</div>

0 comments on commit 2768f18

Please sign in to comment.