From a24e3a67987e7a070eca562ce1cf30a59c206e06 Mon Sep 17 00:00:00 2001 From: Bryan Newbold Date: Thu, 31 Jan 2019 17:10:33 -0800 Subject: tweaks and fixes for new container extra schema --- python/fatcat_web/templates/release_view.html | 42 +++++++++++++-------------- 1 file changed, 21 insertions(+), 21 deletions(-) (limited to 'python/fatcat_web/templates/release_view.html') diff --git a/python/fatcat_web/templates/release_view.html b/python/fatcat_web/templates/release_view.html index c81bf478..3716f0cb 100644 --- a/python/fatcat_web/templates/release_view.html +++ b/python/fatcat_web/templates/release_view.html @@ -154,20 +154,20 @@ This release citing other releases. {% if ref.container_name %}{{ ref.container_name }}.{% endif %} {% if ref.year %}{{ ref.year }}{% endif %} {% if ref.locator %}{{ ref.locator }}{% endif %} - {% elif ref.extra %} + {% elif ref.extra != None %} {% if ref.extra.get('author') %}{{ ref.extra['author'] }}.{% endif %} {% if ref.extra.get('article-title') %}{{ ref.extra['article-title'] }}.{% endif %} {% if ref.container_name %}{{ ref.container_name }}.{% endif %} {% if ref.year %}{{ ref.year }}.{% endif %} - {% elif ref.extra and ref.extra.unstructured %} - {{ ref.extra.unstructured }} + {% if ref.extra.unstructured %}{{ ref.extra.unstructured }}{% endif %} {% else %} unknown {% endif %} {% if ref.target_release_id != None %} - (fatcat release) -{# {% elif ref.extra != None and ref.extra.doi != None %} - (DOI: {{ ref.extra.get('doi') }}) #} + (fatcat entry) + {% endif %} + {% if ref.extra != None and ref.extra.doi %} + (DOI: {{ ref.extra.doi }}) {% endif %} {% endfor %} @@ -186,13 +186,13 @@ This release citing other releases. {% if release.release_type != None %}
-Release Type {{ release.release_type }} +Release Type  {{ release.release_type }}
{% endif %} {% if release.doi %}
-DOI {{ release.doi }} +DOI  {{ release.doi }}
{% endif %} {% if release.isbn13 != None %} @@ -210,37 +210,37 @@ This release citing other releases. {% endif %} -{% if container != None %} +{% if container != None and container.es != None %}
Container Metadata
-{% if container.extra.is_oa == True %} +{% if container.es.is_oa == True %} Open Access Publication
-{% elif container.extra.is_oa == False %} +{% elif container.es.is_oa == False %} Not Open Access
{% else %} Unknown OA Status
{% endif %} -{% if (container.extra != None) %} - {% if container.extra.in_doaj == True %} +{% if (container.es != None) %} + {% if container.es.in_doaj == True %} In DOAJ
- {% elif container.extra.in_doaj == False %} + {% elif container.es.in_doaj == False %} Not in DOAJ
{% endif %} - {% if container.extra.in_road == True %} + {% if container.es.in_road == True %} In ISSN ROAD
- {% elif container.extra.in_road == False %} + {% elif container.es.in_road == False %} Not in ISSN ROAD
{% endif %} - {% if container.extra.is_kept == True %} + {% if container.es.in_kbart == True %} In Keepers Registery
- {% elif container.extra.is_kept == False %} + {% elif container.es.in_kbart == False %} Not in Keepers Registry
{% endif %} {% endif %} {% if container.issnl != None %} - ISSN-L:  {{ container.issnl }}
+ ISSN-L:  {{ container.issnl }}
{% endif %} - Fatcat:  {{ container.ident }}
+ Fatcat Entry
{% endif %} @@ -273,7 +273,7 @@ This release citing other releases. Fatcat Bits

State is "{{ release.state }}". Revision:
{{ release.revision }} -
As JSON object via API +
As JSON object via API

-- cgit v1.2.3