<p>Dear Colleague,<br />

Your attention is drawn to this assessment sign off on module {{ signoff.module }}. Any previous history is shown
    for reference.</p>

<p><a href="{{ base_url }}{% url 'modules_details' signoff.module.id %}">Further details are available online.</a></p>

{% if assessment_history %}
    {% for signoff, resources in assessment_history %}

    {% if signoff %}
        <h3>{{ signoff.assessment_state }} by {{ signoff.signed_by.first_name }} {{ signoff.signed_by.last_name }} on {{ signoff.created }}</h3>
    {% endif %}

    {% if resources %}
        <table style="border-collapse: collapse; border-color: #ccc;" border="1">
            <tr>
                <th>Resource Type</th><th>Name</th><th>Owner</th><th>Created</th>
            </tr>
        {% for resource in resources %}
            <tr style="background: {% cycle '#EDF3FE' '#FFFFFF' %};">
                <td>{{ resource.resource_type }}</td>
                <td>{{ resource.name }}</td>
                <td>{{ resource.owner }}</td>
                <td>{{ resource.created }}</td>
            </tr>
        {% endfor %}
        </table>
    {% endif %}

    {% endfor %}

{% else %}
    <p>Oh, something went wrong trying to send you an assessment update.</p>

{% endif %}

<p>Dear Colleague,<br />

Your attention is drawn to this assessment sign off on module {{ signoff.module }}. Any previous history is shown
    for reference.</p>

<p><a href="{{ base_url }}{% url 'modules_details' signoff.module.id %}">Further details are available online.</a></p>

{% if assessment_history %}
    {% for signoff, resources in assessment_history %}

    {% if signoff %}
        <h3>{{ signoff.assessment_state }} by {{ signoff.signed_by.first_name }} {{ signoff.signed_by.last_name }} on {{ signoff.created }}</h3>
    {% endif %}

    {% if resources %}
        <table style="border-collapse: collapse; border-color: #ccc;" border="1">
            <tr>
                <th style="text-align: left;">Resource Type</th>
                <th style="text-align: left;">Name</th>
                <th style="text-align: left;">Owner</th><th>Created</th>

            </tr>
        {% for resource in resources %}
            <tr style="background: {% cycle '#EDF3FE' '#FFFFFF' %};">
                <td style="padding: 5px;">{{ resource.resource_type }}</td>
                <td style="padding: 5px;">{{ resource.name }}</td>
                <td style="padding: 5px;">{{ resource.owner }}</td>
                <td style="padding: 5px;">{{ resource.created }}</td>
            </tr>
        {% endfor %}
        </table>
    {% endif %}

    {% endfor %}

{% else %}
    <p>Oh, something went wrong trying to send you an assessment update.</p>

{% endif %}

Tweak HTML for readability of table.
Tweak HTML for readability of table.
