From bd3c6566fb9fdd5507782f19672fc62d0c551d05 Mon Sep 17 00:00:00 2001 From: Bryan Newbold Date: Tue, 7 Jul 2020 16:18:53 -0700 Subject: preservation coverage updates (first round) - new by-year chart with stacked histograms of all 4 preservation statuses - new-style single progress bar showing overall preservation status - new by-volume query and chart Old endpoints are left as-is, with the intention of having them "deprecated" for some time span until entirely removing them. --- .../templates/container_view_coverage.html | 60 ++++++++++++++-------- 1 file changed, 38 insertions(+), 22 deletions(-) (limited to 'python/fatcat_web/templates') diff --git a/python/fatcat_web/templates/container_view_coverage.html b/python/fatcat_web/templates/container_view_coverage.html index ffd1a447..fc643f81 100644 --- a/python/fatcat_web/templates/container_view_coverage.html +++ b/python/fatcat_web/templates/container_view_coverage.html @@ -19,34 +19,50 @@ {% set frac_preserved = container._stats.is_preserved/container._stats.total %} {% set frac_web = container._stats.in_web/container._stats.total %} -
-
-
{{ (frac_web*100)|int }}%
-
-
- {{ "{:,}".format(container._stats.in_web) }} preserved and available (bright) -
-
+ {% set pstats = container._stats.preservation %} + {% set frac_bright = container._stats.preservation.bright/container._stats.total %} + {% set frac_dark = container._stats.preservation.dark/container._stats.total %} + {% set frac_shadows_only = container._stats.preservation.shadows_only/container._stats.total %} + {% set frac_none = container._stats.preservation.none/container._stats.total %} -
-
-
-
{{ (frac_preserved*100)|int }}%
+
+
+
{# {{ (frac_bright*100)|int }}% #}
-
- {{ "{:,}".format(container._stats.is_preserved) }} preserved at all (bright or dark) +
+
{# {{ (frac_dark*100)|int }}% #}
-
- -
-
-
-
{{ (frac_kbart*100)|int }}%
+
+
{# {{ (frac_shadows_only*100)|int }}% #}
-
- {{ "{:,}".format(container._stats.in_kbart ) }} preserved by Keeper (dark) +
+
{# {{ (frac_none*100)|int }}% #}
+ + + + + + + +
+ {{ "{:,}".format(pstats.bright) }} + {{ (frac_bright*100)|round(2,method='ceil') }}% + preserved and publicly available (bright) +
+ {{ "{:,}".format(pstats.dark) }} + {{ (frac_dark*100)|round(2,method='ceil') }}% + preserved but not publicly accessible (dark) +
+ {{ "{:,}".format(pstats.shadows_only) }} + {{ (frac_shadows_only*100)|round(2,method='ceil') }}% + only independently preserved in "shadow" libraries +
+ {{ "{:,}".format(pstats.none) }} + {{ (frac_none*100)|round(2,method='ceil') }}% + no known independent preservation +
{% endif %}
-- cgit v1.2.3