Suggestions

<% if @approaches.length > 0 %> <% if @approaches.first.changes.empty? %>

No changes necessary.

<% else %>

Suggested changes (<%= link_to_function "show", "show_suggest_graph('#{serialize_changes(@approaches.first)}', '#{serialize_relevant_roles(@approaches.first)}', '#{@context}', relevant_user_ids())" %>):

<%= render "suggestion", :object => @approaches.first %> <% end %> <% else %>

No approach found.

<% end %> <% if @approaches.length > 1 %>

>Show other <%= pluralize(@approaches.length - 1, 'approach') %>

> <% @approaches[1..-1].each_with_index do |approach, index| %>

<%= (index + 2).ordinalize %> best approach (<%= pluralize(approach.changes.length, 'step') %>, <%= link_to_function "show", "show_suggest_graph('#{serialize_changes(approach)}', '#{serialize_relevant_roles(approach)}', '#{@context}', relevant_user_ids())" %>) <%= render "suggestion", :object => approach %>

<% end %>
<% end %>