{% extends "base.html" %}
{% load bootstrap3 %}
{% block title %}{{hierarchy.label}} (clone){% endblock %}

{% block css %} 
<style></style>
<link rel="stylesheet" href="https://ajax.googleapis.com/ajax/libs/jqueryui/1.11.4/themes/smoothness/jquery-ui.css">
{% endblock %} 

{% block js %}
    <script src="https://ajax.googleapis.com/ajax/libs/jqueryui/1.11.4/jquery-ui.min.js"></script>
{% endblock %}

{% block navrightextra %}
<a href="{{section.get_absolute_url}}" class="btn btn-success">view page</a>
{% endblock %}

{% block content %}
    {{ form.media }}

    <h1>Clone {{ hierarchy.name }}</h1>
    <div id="clone-hierarchy-tab" class="tab-pane">
        <form action="{% url 'clone-hierarchy' hierarchy.id %}"
              method="post" class="form-inline pagetree-clone-form">
            {% csrf_token %}
            {% bootstrap_form form layout='inline' %}
            <button class="btn btn-primary" type="submit">clone</button>
            {% include 'pagetree/loading.html' %}
            <p class="help-block">
                The Base URL field will be used as part of the clone's
                URL. This should be something like: <code>my-clone</code>
            </p>
        </form>
    </div>
{% endblock %}
