{% extends "layout.html" %}

{% load i18n %}

{% block title %}
{% trans 'Email history' %} | {{ block.super }}
{% endblock %}

{% block breadcrumbs %}
<ul class="breadcrumb">
    <li>
        <a href="{% url promotions:home %}">{% trans 'Home' %}</a>
        <span class="divider">/</span>
    </li>
    <li>
        <a href="{% url customer:summary %}">{% trans 'Account' %}</a>
        <span class="divider">/</span>
    </li>
	<li class="active"><a href=".">{% trans 'Email history' %}</a></li>
</ul>
{% endblock %}

{% block header %}
<div class="page-header">
    <h2>{% trans 'Email history' %}</h2>
</div>
{% endblock header %}

{% block content %}
	<table class="table table-striped table-bordered">
		<tr>
			<th>{% trans 'Date sent' %}</th>
			<th>{% trans 'Subject' %}</th>
			<th></th>
		</tr>
		{% for email in emails %}
		<tr>
			<td>{{ email.date_sent }}</td>
			<td>{{ email.subject }}</td>
			<td>
				<a href="{% url customer:email-detail email.id %}" class="btn btn-info">{% trans 'View' %}</a>
			</td>
		</tr>
		{% endfor %}
	</table>
{% endblock content %}

