{% extends 'base.html' %} {% load i18n %} {% load markdown_extras %} {% load static %} {% block content %}
{% trans "Back to List" %}

{{ page.title|default:"Untitled" }}

{% trans "Status" %}: {% if page.process_status == 'completed' %} {% trans "Completed" %} {% elif page.process_status == 'processing' %} {% trans "Processing" %} {% elif page.process_status == 'failed' %} {% trans "Failed" %} {% else %} {% trans "Pending" %} {% endif %} {% if page.retry_count > 0 %} ({% trans "Retries" %}: {{ page.retry_count }}/3) {% endif %}

{% trans "URL" %}

{{ page.url }}
{% trans "Created" %}: {{ page.created_at|date:"Y-m-d H:i:s" }}
{% trans "Updated" %}: {{ page.updated_at|date:"Y-m-d H:i:s" }}
{% if page.last_retry_at %}
{% trans "Last Retry" %}: {{ page.last_retry_at|date:"Y-m-d H:i:s" }}
{% endif %}
{% if page.summary %}

{% trans "Summary" %}

{{ page.summary }}
{% endif %} {% if page.content %}

{% trans "Content" %}

{{ page.content|markdown|safe }}
{% endif %} {% if page.error_message %}

{% trans "Error Message" %}

{{ page.error_message }}
{% endif %}

{% trans "Screenshots" %}

{% with latest_screenshot=page.screenshots.first %} {% if latest_screenshot %}

{% trans "Latest Screenshot" %}

{% if latest_screenshot.path %} Latest screenshot {% else %} Pending screenshot {% endif %}
{{ latest_screenshot.get_status_display }}
{% if latest_screenshot.error %}
{{ latest_screenshot.error }}
{% endif %}
{% trans "Taken" %}: {{ latest_screenshot.created_at|date:"Y-m-d H:i" }}
{% endif %} {% endwith %} {% with previous_screenshots=page.screenshots.all|slice:"1:" %} {% if previous_screenshots %}

{% trans "Previous Screenshots" %}

{% for screenshot in previous_screenshots %}
{% if screenshot.path %} Screenshot {{ forloop.counter }} {% else %} Pending screenshot {{ forloop.counter }} {% endif %}
{{ screenshot.get_status_display }} {{ screenshot.created_at|date:"Y-m-d H:i" }}
{% endfor %}
{% endif %} {% endwith %}
{% endblock %}