{% extends host_template %}

{% load i18n cyclope_utils fb_versions dbgettext_tags %}

{% block content %}
<div class="newsletter_teaser">
    <table align="center" border="0" cellpadding="0" cellspacing="0">
        {% if newsletter.regions == 'tc' or newsletter.regions == 'tcl' %}
        <tr>
            <td class="top_content" valign="top" colspan="2"> 
                {% with categorizations=newsletter.catz_by_region.0 %} 
                    {% for categorization in categorizations %} 
                        {% spaceless %}
                            {% join categorization.content_type.app_label  "/" categorization.content_type.model "_" inline_view_name "_top.html" as template_path %}
                            {% alias categorization.content_object as categorization.content_type.model %}
                        {% endspaceless %}
                        {% include template_path with current_object=categorization.content_object host_template="cyclope/inline_view.html" %}
                    {% endfor %}
                {% endwith %}
            <td>
        </tr>
          <tr>
            <td valign="top" colspan="2" height="15px">
            </td>
        </tr>

        {% endif %}
        <tr>
            <td class="central_content" valign="top">
                {% with categorizations=newsletter.catz_by_region.1 %} 
                    {% for categorization in categorizations %} 
                        {% spaceless %}
                            {% join categorization.content_type.app_label  "/" categorization.content_type.model "_" inline_view_name "_center.html" as template_path %}
                            {% alias categorization.content_object as categorization.content_type.model %}
                        {% endspaceless %}
                        {% include template_path with current_object=categorization.content_object host_template="cyclope/inline_view.html" %}
                    {% endfor %}
                {% endwith %}
            </td>
            {% if newsletter.regions == 'cl' or newsletter.regions == 'tcl' %}          
            <td class="lateral_content" valign="top">
                {% with categorizations=newsletter.catz_by_region.2 %} 
                    {% for categorization in categorizations %} 
                        {% spaceless %}
                            {% join categorization.content_type.app_label  "/" categorization.content_type.model "_" inline_view_name "_lateral.html" as template_path %}
                            {% alias categorization.content_object as categorization.content_type.model %}
                        {% endspaceless %}
                        {% include template_path with current_object=categorization.content_object host_template="cyclope/inline_view.html" %}
                    {% endfor %}
                {% endwith %}
            </td>
            {% endif %}
        </tr>
    </table>
</div>
{% endblock %}
