{% load i18n fairdm %} {% comment %} — what happened to a record, in order: a sample's history, a measurement's procedure. Each step says when, by whom and how. A date recorded only to the year or the month is shown as recorded. Attributes: title – e.g. "History" steps – [{label, date, day, people, note}]; `day` is set when the date is a full day empty – what to say when no step is recorded class – extra classes on the card {% endcomment %} {% if steps %}
    {% for step in steps %}
  1. {% if not forloop.first %}
    {% endif %}
    {{ step.label }} {% if step.day %}{{ step.day|date:"SHORT_DATE_FORMAT" }}{% elif step.date.precision == 1 %}{{ step.date.date|date:"YEAR_MONTH_FORMAT" }}{% elif step.date %}{{ step.date }}{% else %}{% translate "date not recorded" %}{% endif %}
    {% if step.people %}

    {% translate "by" %} {% for person in step.people %}{{ person }}{% if not forloop.last %}, {% endif %}{% endfor %}

    {% endif %} {% if step.note %}
    {{ step.note|safe_markdown }}
    {% endif %}
    {% if not forloop.last %}
    {% endif %}
  2. {% endfor %}
{% else %}

{{ empty }}

{% endif %}