Commit e3b23cb0d445b0a543fdc5ee4108302c8652842d

Authored by Gabriel Silva
Committed by Tallys Martins
1 parent ab48799c

Adds hostspot in Organization Rating task details

Signed-off-by: Gabriel Silva <gabriel93.silva@gmail.com>
Signed-off-by: Gustavo Coelho <gust.rod.coelho@gmail.com>
Signed-off-by: Tallys Martins <tallysmartins@gmail.com>
plugins/organization_ratings/views/tasks/_create_organization_rating_comment_accept_details.html.erb
1 1 <div class="organization-rating-comment-body">
2   - <%= _("Comment:")%>
3   - <%= "\"#{task.body}\""%>
  2 + <div class="task-star-container">
  3 + <% rating = OrganizationRating.find(task.organization_rating_id) %>
  4 + <% (1..5).each do |star_number| %>
  5 + <% if star_number <= rating.value %>
  6 + <div class="medium-star-positive"></div>
  7 + <% else %>
  8 + <div class="medium-star-negative"></div>
  9 + <% end %>
  10 + <% end %>
  11 + </div>
  12 + <br />
  13 +
  14 + <div class="task-comment">
  15 + <%= _("Comment:")%>
  16 + <%= "\"#{task.body}\""%>\
  17 + </div>
  18 + <%= @plugins.dispatch(:organization_ratings_plugin_extra_fields_show_data, rating).collect{ |content| instance_exec(&content) }.join("") %>
4 19 </div>
... ...