{% load url from future %}
{% load bootstrap_tags %}

<div class="change-subscription">
    <h2>Change Subscription</h2>
    <p class="lead">
        {% if request.user.customer.current_subscription.plan %}
            You currently have the <strong>{{ request.user.customer.current_subscription.plan_display }}</strong> plan.
        {% else %}
            You currently do not have a plan.
        {% endif %}
    </p>
    {% if error %}
        <div class="alert alert-error">{{ error }}</div>
    {% endif %}
    <form action="{% url 'payments_ajax_change_plan' %}" method="POST" class="form-inline ajax" data-replace-closest=".change-subscription">
        {% csrf_token %}
        {{ form|as_bootstrap }}
        <button type="submit" class="btn btn-primary">Change</button>
    </form>
</div>
