Changeset - 76a5e08e2fe5
[Not reviewed]
0 5 0
Rebecca Lovewell - 10 years ago 2014-01-15 14:36:35
rebecca@caktusgroup.com
Use {% load url from future %} in schedule templates

Using https://github.com/futurecolors/django-future-url
5 files changed with 16 insertions and 7 deletions:
0 comments (0 inline, 0 general)
symposion/templates/schedule/_edit_grid.html
Show inline comments
 
{% load url from future %}
 
<table class="calendar table table-bordered">
 
    <thead>
 
        <tr>
...
 
@@ -15,9 +16,9 @@
 
                    <td class="slot slot-{{ slot.kind.label }}" colspan="{{ slot.colspan }}" rowspan="{{ slot.rowspan }}">
 
                        {% if slot.kind.label == "talk" or slot.kind.label == "tutorial" %}
 
                            {% if not slot.content %}
 
                                <a class="btn btn-mini edit-slot" data-action="{% url schedule_slot_edit schedule.section.slug slot.pk %}" href="#">+</a>
 
                                <a class="btn btn-mini edit-slot" data-action="{% url 'schedule_slot_edit' schedule.section.slug slot.pk %}" href="#">+</a>
 
                            {% else %}
 
                                <span class="title"><a class="edit-slot" data-action="{% url schedule_slot_edit schedule.section.slug slot.pk %}" href="#">{{ slot.content.title }}</a></span>
 
                                <span class="title"><a class="edit-slot" data-action="{% url 'schedule_slot_edit' schedule.section.slug slot.pk %}" href="#">{{ slot.content.title }}</a></span>
 
                                <span class="speaker">{{ slot.content.speaker }}</span>
 
                            {% endif %}
 
                        {% else %}
...
 
@@ -26,7 +27,7 @@
 
                            {% else %}
 
                                {{ slot.kind.label }}
 
                            {% endif %}
 
                            &mdash; <a class="edit-slot" data-action="{% url schedule_slot_edit schedule.section.slug slot.pk %}" href="#">edit</a>
 
                            &mdash; <a class="edit-slot" data-action="{% url 'schedule_slot_edit' schedule.section.slug slot.pk %}" href="#">edit</a>
 
                        {% endif %}
 
                    </td>
 
                {% endfor %}
symposion/templates/schedule/_grid.html
Show inline comments
 
{% load url from future %}
 
<table class="calendar table table-bordered">
 
    <thead>
 
        <tr>
...
 
@@ -17,7 +18,7 @@
 
                            {% if not slot.content %}
 
                            {% else %}
 
                                <span class="title">
 
                                    <a href="{% url schedule_presentation_detail slot.content.pk %}">{{ slot.content.title }}</a>
 
                                    <a href="{% url 'schedule_presentation_detail' slot.content.pk %}">{{ slot.content.title }}</a>
 
                                </span>
 
                                <span class="speaker">
 
                                    {{ slot.content.speakers|join:", " }}
symposion/templates/schedule/_slot_edit.html
Show inline comments
 
{% load url from future %}
 
{% load i18n bootstrap_tags %}
 
<form id="slotEditForm" class="modal-form" method="POST" action="{% url schedule_slot_edit slug slot.pk %}">
 
<form id="slotEditForm" class="modal-form" method="POST" action="{% url 'schedule_slot_edit' slug slot.pk %}">
 
    <div class="modal-header">
 
        <a class="close" data-dismiss="modal">&times;</a>
 
        <h3>{% trans "Edit Slot" %}</h3>
symposion/templates/schedule/presentation_detail.html
Show inline comments
 
{% extends "site_base.html" %}
 

	
 
{% load url from future %}
 

	
 

	
 
{% load sitetree %}
 

	
 
{% block head_title %}Presentation: {{ presentation.title }}{% endblock %}
...
 
@@ -17,7 +20,7 @@
 

	
 
    <h4>
 
        {% for speaker in presentation.speakers %}
 
            <a href="{% url speaker_profile speaker.pk %}">{{ speaker }}</a>{% if not forloop.last %}, {% endif %}{% endfor %}
 
            <a href="{% url 'speaker_profile' speaker.pk %}">{{ speaker }}</a>{% if not forloop.last %}, {% endif %}{% endfor %}
 
    </h4>
 

	
 
    <dl class="dl-horizontal">
symposion/templates/schedule/schedule_list.html
Show inline comments
 
{% extends "site_base.html" %}
 

	
 
{% load url from future %}
 

	
 

	
 
{% load i18n %}
 
{% load cache %}
 
{% load sitetree %}
...
 
@@ -33,7 +36,7 @@
 
        {% for presentation in presentations %}
 
            <div class="row">
 
                <div class="span8 presentation well">
 
                    <h3><a href="{% url schedule_presentation_detail presentation.pk %}">{{ presentation.title }}</a></h3>
 
                    <h3><a href="{% url 'schedule_presentation_detail' presentation.pk %}">{{ presentation.title }}</a></h3>
 
                    <h4>{{ presentation.speakers|join:", " }}</h4>
 
                    {{ presentation.description }}
 
                    {% if presentation.slot %}
0 comments (0 inline, 0 general)