You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

30 lines
611 B

  1. {% extends "base.html" %}
  2. {% block content %}
  3. {% if id %}
  4. <h2>Editing Chemical {{id}}</h2>
  5. {% endif %}
  6. {% if invalid %}
  7. <p style="color: red;">Invalid Form!</p>
  8. {% endif %}
  9. {% if success %}
  10. <p style="color: green;">Success!</p>
  11. {% endif %}
  12. <form method="post">
  13. <table>
  14. {% for field in form %}
  15. <tr>
  16. <td>
  17. <strong>
  18. {{ field.label }}{% if field.flags.required %}*{% endif %}
  19. </strong>
  20. </td>
  21. <td>
  22. {{ field }}
  23. </td>
  24. </tr>
  25. {% endfor %}
  26. </table>
  27. <input type="submit" value="Submit">
  28. </form>
  29. {% endblock %}