diff --git a/aleksis/core/templates/templated_email/data_checks.css b/aleksis/core/templates/templated_email/data_checks.css new file mode 100644 index 0000000000000000000000000000000000000000..b385b185ecfe66dcca070e8eb024bbb091917f04 --- /dev/null +++ b/aleksis/core/templates/templated_email/data_checks.css @@ -0,0 +1,16 @@ +body { + line-height: 1.5; + font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif; + font-weight: normal; + color: rgba(0, 0, 0, 0.87); +} + +.count { + text-align: right; + font-family: monospace; + font-size: 14pt; +} + +td, th { + padding: 10px; +} diff --git a/aleksis/core/templates/templated_email/data_checks.email b/aleksis/core/templates/templated_email/data_checks.email new file mode 100644 index 0000000000000000000000000000000000000000..0f9b5a5307fba9152683d4e03b0c41a2105629c7 --- /dev/null +++ b/aleksis/core/templates/templated_email/data_checks.email @@ -0,0 +1,44 @@ +{% load i18n %} + +{% block subject %} + {% trans "The system detected some new problems with your data." %} +{% endblock %} + +{% block plain %} + {% trans "Hello," %} + + {% blocktrans %} + the system detected some new problems with your data. + Please take some time to inspect them and solve the issues or mark them as ignored. + {% endblocktrans %} + + {% for result in results %} + {{ result.0.problem_name }}: {{ result.1 }} + {% endfor %} +{% endblock %} + +{% block html %} + <style> + {% include "templated_email/data_checks.css" %} + </style> + <p>{% trans "Hello," %}</p> + <p> + {% blocktrans %} + the system detected some new problems with your data. + Please take some time to inspect them and solve the issues or mark them as ignored. + {% endblocktrans %} + </p> + + <table> + <tr> + <th>{% trans "Problem description" %}</th> + <th>{% trans "Count of objects with new problems" %}</th> + </tr> + {% for result in results %} + <tr> + <td>{{ result.0.problem_name }}</td> + <td class="count">{{ result.1 }}</td> + </tr> + {% endfor %} + </table> +{% endblock %}