{% extends "base.html" %} {% from "_macros.html" import th, svg_heatmap, legend_freshness %} {% block title %}{{ t('数据覆盖 Data coverage · 爬虫控制台') }}{% endblock %} {% block content %}

{{ t('数据覆盖') }}

{{ n_concepts }} {{ t('个概念有观测 concepts with observations') }} · {{ total_rows }} {{ t('local rows 本地行') }} · {% if coverage_live %}{{ t('覆盖为实时 live coverage') }}{% else %}{{ t('覆盖采样于 coverage sampled') }} {{ coverage_age_hours }}h {{ t('前') }}{% if coverage_stale %} {{ t('陈旧 stale') }}{% endif %}{% endif %} · {% if census %}{{ "{:,}".format(census_total) }} {{ t('across all stores 全部存储合计') }}{% else %}{{ t('census 尚未采样 not yet sampled') }}{% endif %}

{% if census %}

{{ t('存储') }} {{ t('(最新普查 latest census)') }}

{{ th(t('存储')) }}{{ th(t('类型')) }}{{ th(t('行数')) }}{{ th(t('大小')) }}{{ th(t('分块')) }}{{ th(t('数据截至')) }}{{ th(t('采样于')) }} {% for c in census %} {% endfor %}
{{ c.store }} {{ c.kind }} {% if c.error %}{{ t('错误 error') }} {% elif c.approx_rows is none %}— {% else %}{% if not c.exact %}≈{% endif %}{{ "{:,}".format(c.approx_rows) }}{% endif %} {% if c.total_size_bytes %}{{ (c.total_size_bytes / 1073741824) | round(1) }} GB{% else %}—{% endif %} {{ c.chunks or '—' }} {{ c.time_range_end or '—' }} {% if c.stale %}{{ t('陈旧 stale') }} {% endif %}{{ c.age_hours if c.age_hours is not none else '—' }}h {{ t('前 ago') }}
{% endif %} {% block coverage_heatmap %}

{{ t('概念新鲜度') }}

{{ svg_heatmap(heat, link_prefix='/panel/data?freshness=', active_key=freshness, label=t('概念新鲜度分布 concept freshness by bucket')) }} {{ legend_freshness() }} {% if freshness %}{{ t('清除新鲜度筛选 Clear freshness') }}{% endif %}
{% endblock %}
{{ t('清除 Clear') }}
{{ th(t('概念')) }}{{ th(t('分类')) }}{{ th(t('行数')) }}{{ th(t('最新日期')) }}{{ th(t('数据源')) }}{{ th(t('上次抓取')) }} {% for c in coverage %} {% else %} {% endfor %}
{{ c.name_zh or c.name_en or c.code or c.concept_id }} {{ c.category or '—' }} {{ c.rows }} {{ c.latest_date or '—' }} {{ c.sources }} {{ c.last_fetch or '—' }}
{{ t('没有匹配的观测 No observations match.') }}
{% endblock %}