{% extends "newbase.html" %}
{% load staticfiles %}
{% load rowerfilters %}

{% block title %}Advanced Features {% endblock %}

{% block main %}
<h1>Stream Editor</h1>
<ul class="main-content">
  <li class="grid_4">
    <p>
      Edit river Stream between turning points in your row. 
      Use positive (+) values to denote rowing with the stream, 
      negative (-) values to denote rowing against the stream.
    </p>
  </li>
  <li class="grid_2">
    <form enctype="multipart/form-data" action="{{ formloc }}" method="post">
      {% if form.errors %}
      <p style="color: red;">
        Please correct the error{{ form.errors|pluralize }} below.
      </p>
      {% endif %}
      
      <table>
        {{ form.as_table }}
      </table>
      {% csrf_token %}
      <input class="button green small" type="submit" value="Submit Form">
    </form>
    <img src="/static/img/rivercurrent.jpg" width="400">
  </li>
  <li class="grid_2">
    <script src="https://cdn.pydata.org/bokeh/release/bokeh-1.0.4.min.js"></script>
    <script async="true" type="text/javascript">
      Bokeh.set_log_level("info");
    </script>
    
    {{ interactiveplot |safe }}
    
    {{ the_div |safe }}
  </li>


</ul>

{% endblock %}

{% block sidebar %}
{% include 'menu_workout.html' %}
{% endblock %}
