{% block inspection_pictures %} {% set observations_per_page = 2 %} {% set total_observations = inspection.observations|length %} {% set total_pages = ((total_observations / observations_per_page) | round(0, 'ceil')) | int %} {% for page_num in range(1, total_pages + 1) %}
{% set title = "Imágenes de Inspección / Inspección : ID de Registro: " ~ (inspection.header.location.access_point_no if inspection.header.location.access_point_no else "") %} {% set border_bottom = false %} {% set border_top = false %} {% include "nassco/macp/es/page_title.html" %}

{{ t("labels.place") }}:

{% if inspection.header.location.city %}

{{ inspection.header.location.city }}

{% endif %}

{{ t("labels.road") }}:

{% if inspection.header.location.street %}

{{ inspection.header.location.street }}

{% endif %}

{{ t("labels.date") }} (YYYY/MM/DD):

{% if inspection.header.survey.survey_date %}

{{ inspection.header.survey.survey_date.strftime("%Y/%m/%d") }}

{% endif %}

{{ t("labels.camera") }}:

{% if inspection.header.survey.inspection_technology and inspection.header.survey.inspection_technology.label %}

{{ inspection.header.survey.inspection_technology.label }}

{% endif %}

{{ t("labels.operator") }}:

{% if inspection.header.survey.surveyed_by %}

{{ inspection.header.survey.surveyed_by }}

{% endif %}
{% set start_index = (page_num - 1) * observations_per_page %} {% set end_index = start_index + observations_per_page if start_index + observations_per_page <= total_observations else total_observations %} {% for i in range(start_index, end_index) %} {% set observation = inspection.observations[i] %}
{% if observation.annotated_frame %} {% endif %}

{{ t("labels.photo") }}: {{ i + 1 }} {% if observation.video_ref %} , {{ observation.video_ref }} {% endif %}

{% if observation.distance is not none %} {{ observation.distance }}{{ measurement_units }} {% endif %}{% if observation.code and observation.code.full_name %} , {{ observation.code.full_name }} {% endif %}

{% endfor %}
{% endfor %} {% endblock %}