|
8 | 8 | <div class="row">
|
9 | 9 | <div class="col-lg-6">
|
10 | 10 | <h1>My Contributions</h1>
|
11 |
| - <% if @points.length == 100 %> |
12 |
| - (showing only 100 items) |
13 |
| - <% else %> |
14 |
| - (showing all <%= @points.length %> items) |
15 |
| - <% end %> |
16 | 11 | </div>
|
17 | 12 | </div>
|
18 | 13 | <br>
|
19 | 14 | <br>
|
20 | 15 | <div class="row">
|
21 |
| - <div class="col-lg-6"> |
22 |
| - <%= render "shared/search" %> |
| 16 | + <div class="col-lg-4 text-left"> |
| 17 | + <div class=""> |
| 18 | + <%= search_form_for @q do |f| %> |
| 19 | + <%= f.label :service_name_cont %> |
| 20 | + <%= f.search_field :service_name_cont %> |
| 21 | + |
| 22 | + <%= f.submit %> |
| 23 | + <% end %> |
| 24 | + </div> |
23 | 25 | </div>
|
24 | 26 | </div>
|
25 | 27 | <br>
|
26 | 28 | <% if @points.empty? %>
|
27 | 29 | <p>There are no points to display at this time!</p>
|
28 | 30 | <% else %>
|
29 |
| - <%= render "shared/table_points", points: @points %> |
| 31 | + <div class=""> |
| 32 | + <div class="table-responsive"> |
| 33 | + <table class="table table-striped"> |
| 34 | + <thead> |
| 35 | + <tr> |
| 36 | + <th scope="col">Service</th> |
| 37 | + <th scope="col">Title</th> |
| 38 | + <th scope="col">Rating</th> |
| 39 | + <th scope="col">Status</th> |
| 40 | + <th scope="col">Author</th> |
| 41 | + </tr> |
| 42 | + </thead> |
| 43 | + <tbody id="myTableBody"> |
| 44 | + <% @points.each do |point| %> |
| 45 | + <% if point.case&.classification == 'good' %> |
| 46 | + <% pointbox = "point-good" %> |
| 47 | + <% elsif point.case&.classification == 'neutral' %> |
| 48 | + <% pointbox = "point-neutral" %> |
| 49 | + <% elsif point.case&.classification == 'bad' %> |
| 50 | + <% pointbox = "point-bad" %> |
| 51 | + <% elsif point.case&.classification == 'blocker' %> |
| 52 | + <% pointbox = "point-blocker" %> |
| 53 | + <% end %> |
| 54 | + <tr class="toSort"> |
| 55 | + <td><%= point.service.name %></td> |
| 56 | + <td><%= link_to point.quote_text ? "\"" + point.quote_text + "\"" : point.title, point_path(point), title: "View more details" %></td> |
| 57 | + <td class="<%= pointbox %>"></td> |
| 58 | + <td> <%= status_badge point.status %> </td> |
| 59 | + <td><%= username point.user %> <%= rank_badge point.user %></td> |
| 60 | + </tr> |
| 61 | + <% end %> |
| 62 | + </tbody> |
| 63 | + </table> |
| 64 | + </div> |
| 65 | + </div> |
30 | 66 | <% end %>
|
31 | 67 | </div>
|
32 | 68 | </div>
|
| 69 | + <%= paginate @points %> |
33 | 70 | <% end %>
|
0 commit comments