<% if @sprint.has_burndown? %>
  <a href="<%= url_for(:controller => 'rb_burndown_charts', :action => 'print', :sprint_id => @sprint.id) %>">print</a>
  <%= render :partial => 'burndown', :locals => {:sprint => @sprint, :mode => :full, :style => 'width:650px; height: 300px' } %>

  <fieldset>
      <legend><%= l(:label_chart_options) %></legend>

      Legend:
      <%- ['Off', 'NW', 'N', 'NE', 'E', 'SE', 'S', 'SW', 'W'].each do |legend| %>
        <input type="radio" name="legend" id="burndown_legend_<%= legend.downcase %>" value="<%= legend.downcase %>" onclick="RB.burndown.change_legend(this)">&nbsp;<%= legend %>&nbsp;&nbsp;
      <%- end %><br/>

      <% @sprint.burndown.series.sort{|a, b| l("label_#{a}") <=>  l("label_#{b}")}.each do |series| %>
          <input class="series_enabled" id="burndown_series_<%= series %>" type="checkbox" checked="checked" onclick="RB.burndown.change_series(this)" value="<%= series %>"><%= l("label_#{series}") %><br/>
      <% end %>
  </fieldset>
  <script type="text/javascript">
    RB.burndown.configure();
  </script>
<% else %>
  No burndown data available -- are the sprint start- and end dates set?
<% end %>
