From 6e059f1bbd9753df279e1d4c1f1f98d9099e6984 Mon Sep 17 00:00:00 2001 From: Bryan Newbold Date: Fri, 26 Feb 2021 10:30:53 -0800 Subject: web: release view improvements --- python/fatcat_web/templates/release_view.html | 190 +++++++++++--------------- 1 file changed, 79 insertions(+), 111 deletions(-) diff --git a/python/fatcat_web/templates/release_view.html b/python/fatcat_web/templates/release_view.html index cc9cf5fe..9464fda2 100644 --- a/python/fatcat_web/templates/release_view.html +++ b/python/fatcat_web/templates/release_view.html @@ -79,23 +79,16 @@
-{% if release.abstracts != [] %} -

Abstract

-

{{ release.abstracts[0].content }} -
In {{ release.abstracts[0].mimetype }} format -{% endif %} - -

{% if release.release_stage == 'published' %} - Published + Published {% if release.container.ident %} in {{ release.container.name }} {% elif release.extra and release.extra.container_name %} in {{ release.extra.container_name }} {% endif %} {% else %} - Released + Released {% if release.release_type %} as a {{ release.release_type }} {% endif %} @@ -105,84 +98,41 @@ {% endif %} {% if release.publisher %} by {{ release.publisher }} - {% endif %} -
- - - {% if release.number != None %} - - - - - - - - - - - - - - - -
Number{{ release.number }} - {% endif %} - {% if release.version != None %} -
Version{{ release.version }} - {% endif %} - {% if release.container != None and release.container.issnl != None %} -
ISSN-L{{ release.container.issnl }} - {% endif %} - {% if release.volume != None %} -
Volume{{ release.volume }} - {% endif %} - {% if release.issue != None %} -
Issue{{ release.issue }} - {% endif %} - {% if release.pages != None %} -
Page(s){{ release.pages }} - {% endif %} - {% if release.release_date != None %} -
Release Date{{ release.release_date }} - {% elif release.release_year != None %} -
Release Year{{ release.release_year }} - {% endif %} - {% if release.container != None and release.container.container_type != None %} -
Container Type{{ release.container.container_type }} - {% endif %} - {% if release.publisher != None %} -
Publisher{{ release.publisher }} - {% endif %} - {% if release.language != None %} -
Primary Language{{ release.language }} - (lookup) - {% endif %} + {% endif %}. -
-
+

+ {% if release.volume != None %} + Volume {{ release.volume }} + {%- if release.issue != None %}, {% endif %} + {% endif %} + {% if release.issue != None %} + Issue {{ release.issue}} + {% endif %} + {% if release.pages != None %} + {% if release.pages[0].isdigit() %}p{% endif -%} + {{ release.pages }} + {% endif %} + {% if release.release_year != None %} + ({{ release.release_year }}) + {% endif %}

+{% if release.abstracts != [] %} +

Abstract

+

{{ release.abstracts[0].content }} +
In {{ release.abstracts[0].mimetype }} format +{% endif %} + {% if entity.state == 'active' %} -

Known Files and URLs

+

Archived Files and Locations

{% if entity.files != [] %} - {% for file in entity.files %} {% for fileset in entity.filesets %}
{% if file.mimetype != None %}{{ file.mimetype }}  {% endif %} {% if file.size != None %}{{ file.size|filesizeformat }}{% endif %}
- {% if file.sha1 != None %}sha1:{{ file.sha1[:20] + "..." }} - {% elif file.sha256!= None %}sha256:{{ file.md5[:20] + "..." }} - {% elif file.md5 != None %}md5:{{ file.md5[:20] + "..." }} - {% endif %} + file_{{ file.ident }}
{% for url in file.urls[:5] %} @@ -208,7 +158,7 @@ accessible version.
{{ fileset.manifest|count }} files  {{ fileset._total_size|filesizeformat }} -
fileset:{{ fileset.ident }} +
fileset_{{ fileset.ident }}
{% for url in fileset.urls[:5] %} {% if url.rel == "dweb" %} @@ -234,7 +184,7 @@ accessible version. {% for webcapture in entity.webcaptures %}
{{ webcapture.original_url }}
{{ webcapture.timestamp.strftime("%Y-%m-%d %H:%M:%S") }} | {{ webcapture.cdx|count }} resources -
webcapture:{{ webcapture.ident }} +
webcapture_{{ webcapture.ident }}
{% for url in webcapture.archive_urls[:5] %} {{ url.url.split('/')[2] }} ({{ url.rel }})
@@ -247,41 +197,42 @@ accessible version.
{% endif %} {% endif %} +
-
-{% if entity.state == 'active' and entity._es and entity._es.best_pdf_url %} -Read Full Text +{% if entity.state == 'active' and entity._es and entity._es.ia_pdf_url %} + + Read Archived PDF + {% elif entity.state == 'active' and entity.webcaptures != [] and entity.webcaptures[0].archive_urls != [] and entity.webcaptures[0].archive_urls[0].rel == "wayback" %} -View Web Archive -{% elif entity.state == 'active' %} -No Full Text Available - - - "Save Paper Now" -
- Know of a fulltext copy of on the public web? Submit a URL and we will archive it -
-
- -{# alternative SPN -
-
- Save Paper Now -
-

Know of a fulltext copy on the public web? Submit a URL and we'll archive it -

-#} + + Visit Web Archive + +{% endif %} -{# alternative SPN -
- Save Paper Now -
know of a fulltext copy on the public web? submit a URL and we'll archive it -
-#} +{% if entity.state == 'active' and entity._es %} + {% if entity._es.preservation == 'bright' %} +
+ Archived +
+ {% elif entity._es.preservation == 'dark' %} +
+ "Dark" Archived +
+ {% else %} +
+ Not Preserved +
+
+ + Save Paper Now! + +

Know of a fulltext copy of on the public web? Submit a URL and we will archive it +

+ {% endif %} {% endif %} {% if release.release_type or release.release_stage or release.release_year %} @@ -305,6 +256,10 @@ accessible version. {% if release.version %} Version   {{ release.version }}
{% endif %} + {% if release.language != None %} + Language   {{ release.language}} + ? + {% endif %}
{% endif %} @@ -357,7 +312,19 @@ accessible version. {% if release.container != None and release.container._es %}
-Container Metadata
+ +{% if release.container.container_type == "journal" %} + Journal Metadata +{% elif release.container.container_type == "proceedings" %} + Proceedings Metadata +{% elif release.container.container_type == "book-series" %} + Book Series Metadata +{% elif release.container.container_type == "blog" %} + Blog Metadata +{% else %} + Container Metadata +{% endif %} +
{% if release.container._es.is_oa == True %} Open Access Publication
{% endif %} @@ -370,7 +337,9 @@ accessible version. {% if release.container._es.in_road == True %} In ISSN ROAD
{% elif release.container._es.in_road == False %} + {# skip 'not in ROAD' display, to reduce UI clutter Not in ISSN ROAD
+ #} {% endif %} {% if release.container._es.any_kbart == True %} In Keepers Registery
@@ -380,19 +349,18 @@ accessible version. {% if release.container.issnl != None %} ISSN-L:  {{ release.container.issnl }}
{% endif %} - Fatcat Entry
{% endif %} -
+
Work Entity -
grouping other versions (eg, pre-print) and variants of this release +
access all versions, variants, and formats of this works (eg, pre-prints)
{% if release.state == "active" and release._can_citeproc %}
- Cite This Release + Cite This
BibTeX -- cgit v1.2.3