{% extends "events/base.html" %}
{% load event_tags %}
{% load perm_tags %}
{% load styled_forms %}
{% load i18n %}

{% block title %}{{ block.super }}Edit{% endblock %}

{% block extra_head %}
{{ block.super }}
<link rel="stylesheet" href="{{ STATIC_URL }}css/jquery-ui/jquery-ui-1.8.2.custom.css">
<link rel="stylesheet" href="{{ STATIC_URL }}css/timepicker.css" />
<link rel="stylesheet" href="{{ STATIC_URL }}css/events.css">
<script type="text/javascript" src="{{ TINYMCE_JS_URL }}"></script>
{% endblock %}

{% block body %}
<div class="t">
    {% event_nav request.user event %}

    <h1>{% firstof MODULE_EVENTS_LABEL 'Event' %}{% trans " Edit" %}</h1>

    <div class="event-wrap">

    	<form action="{% url event.edit event.pk %}" method="post" enctype="multipart/form-data">{% csrf_token %}
    	<div class="forms">
			{{ multi_event_forms|styled_multi_forms }}          
			<input type="submit" value="Save Changes" />
		</div>
        </form>
    </div>
</div>
{% endblock %}

{% block extra_body %}
    {{ block.super }}
    <script type="text/javascript" src="{{ STATIC_URL }}js/global/tinymce.event_handlers.js"></script>
    <script type="text/javascript" src="{{ STATIC_URL }}js/jquery-ui-1.8.2.custom.min.js"></script>
    <script type="text/javascript" src="{{ STATIC_URL }}js/jquery.time.picker.js"></script>
    <script type="text/javascript" src="{{ STATIC_URL }}js/slug.js"></script>
    <script type="text/javascript" src="{{ STATIC_URL }}js/formset.js"></script>
    <script type="text/javascript">
        var slugit = new Slugify({
			input_element : 'input#id_title',
			slug_element : 'input#id_slug',
			submit_element : 'input[type="submit"]',
			help: false,
			limit : 150
		});
        
        $(document).ready(function() {
            $('.regconfpricing_formset .section-description').addClass('well');
        });
	</script>
	
	<script type="text/javascript">
        {% include 'events/include/event_place.js' %}
    </script>
	
<script type="text/javascript">
 {% include 'events/include/event_form_custom_reg.js' %}
</script>
{% endblock %}
