dvd-collection / collection / templates / collection / movie_form.html

Kevin Veroneau 80dc35b 

{% extends "base.html" %}

{% block title %}{% if movie %}Update {{movie.title}}{% else %}Add Movie{% endif %}{% endblock %}

{% block base_content %}
          {% if movie %}
          <form action="{% url 'movie_edit' movie.slug %}" method="post">{% csrf_token %}
          {% else %}
          <form action="{% url 'movie_add' %}" method="post">{% csrf_token %}
          {% endif %}
              <legend>{% if movie %}Update Movie Details for {{movie.title}}{% else %}Add Movie to collection{% endif %}</legend>
              {% if movie %}
              <a class="btn btn-danger" href="{% url 'movie_detail' movie.slug %}">Cancel</a>
              {% endif %}
              {% include "bootstrap_form.html" %}
              <button type="submit" class="btn btn-primary">{% if movie %}Save Movie{% else %}Add Movie{% endif %}</button>
{% endblock %}
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.