{% extends "atlas/base.html" %}
{% load crispy_forms_tags %}

{% block js %}
    {{ form.media }}
{% endblock %}

{% block content %}
    <h2>Add / Edit Subspecialty</h2>
    <p>Use this form to create or edit a subspecialty.</p>
    <p>Please check if it already <a href='{% url "atlas:subspecialty_view" %}'>exists</a> before doing so!</p>

    <form action="" method="post" enctype="multipart/form-data" id="subspecialty-form">
        {% csrf_token %}
        {% crispy form %}

        <div class="mt-3">
            <button type="submit" class="btn btn-primary">Submit</button>
            <a class="btn btn-secondary ms-2" href="{% url 'atlas:subspecialty_view' %}">Cancel</a>
        </div>
    </form>

{% endblock %}
