{% extends "base.html" %} {% from "_page_header.html" import page_header %} {% from "_components.html" import badge, identifier, pagination, empty_state, toolbar, operations_journey %} {% block content %} {{ page_header("Documents", "Every document in the workspace with the real state of its newest version. Searchable means published and indexed; Failed carries the reason the worker recorded.") }} {{ operations_journey(source_url="/admin/sources" if can_open_sources else None, job_url="/admin/jobs" if can_open_jobs else None, current="document") }}
{% if selected_source %}Filtered to {{ selected_source.name }}.{% else %}Filtered to an unavailable source.{% endif %} Show all documents
{% endif %} {% if not page.items %}| Name | Source | Space | Parser | State | Updated |
|---|---|---|---|---|---|
|
{{ document.title }}
{{ document.external_id }} |
{% set source = sources.get(document.source_id) %} {% if source %}{{ source.name }}{% else %}{{ identifier(document.source_id) }}{% endif %} | {{ spaces.get(document.space_id, "—") }} | {{ item.parser_version or "—" }} |
{% if document.source_deleted %}{{ badge("Retired", "neutral") }}
{% elif item.searchable %}{{ badge("Searchable", "ok") }}
{% elif item.failed %}{{ badge("Failed", "error") }}{% if item.failure_code %} {{ item.failure_code }} {% endif %} {% elif item.latest_state %}{{ badge("Processing", "info") }} {% else %}{{ badge("No version", "neutral") }}{% endif %} |
{{ item.updated_at.strftime("%Y-%m-%d %H:%M") if item.updated_at else "—" }} |