{% extends "client_portal/base.html" %} {% from "components/ui.html" import page_header %} {% block title %}{{ _('Documents') }} - {{ _('Client Portal') }}{% endblock %} {% block content %} {% set breadcrumbs = [ {'text': _('Client Portal'), 'url': url_for('client_portal.dashboard')}, {'text': _('Documents')} ] %} {{ page_header( icon_class='fas fa-file-alt', title_text=_('Documents'), subtitle_text=_('View and download project documents'), breadcrumbs=breadcrumbs ) }} {% if attachments %}
{% for attachment in attachments %}

{{ attachment.original_filename if attachment.original_filename else attachment.filename }}

{% if hasattr(attachment, 'project') and attachment.project %}

{{ attachment.project.name }}

{% elif hasattr(attachment, 'client') and attachment.client %}

{{ _('Client Document') }}

{% endif %}
{% if attachment.uploaded_at %}
{{ attachment.uploaded_at|user_date }}
{% endif %} {% if attachment.file_size %}
{{ attachment.file_size_display if hasattr(attachment, 'file_size_display') else ("%.2f"|format(attachment.file_size / 1024) + " KB") }}
{% endif %}
{{ _('Download') }}
{% endfor %}
{% else %}

{{ _('No Documents') }}

{{ _('No documents have been shared with you yet. Documents will appear here once they are uploaded and made visible to clients.') }}

{% endif %} {% endblock %}