aboutsummaryrefslogtreecommitdiffstats
path: root/python/fatcat/templates/release_view.html
blob: 4d67644d9af4d063ed9bfbd5e959f2155329bb85 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
{% extends "base.html" %}
{% block fullbody %}

<div class="ui stackable mobile reversed grid centered">
<div class="one wide column"></div>
<div class="ten wide column">

<h1 class="ui header">{{ release.title }}
<div class="sub header"><code>release {{ release.ident }}</code></div></h1>
{% for contrib in authors %}
  {% if contrib.creator_id %}
    <b><a href="/creator/{{contrib.creator_id}}">{{ contrib.raw }}</a></b>
  {% else %}
    {{ contrib.raw }}
  {% endif %}
{% endfor %}

<br><br>
{% if release.release_date != None %}<p><b>Date (published):</b> {{ release.release_date }}{% endif %}
{% if release.doi != None %}
<br><b>DOI:</b> <a href="https://doi.org/{{ release.doi }}"><code>{{ release.doi }}</code></a>
{% endif %}
{% if release.language != None %}
<br><b>Primary Language:</b> <code>{{ release.language }}</code> (<a href="https://www.loc.gov/standards/iso639-2/php/langcodes_name.php?iso_639_1={{ release.language }}">lookup ISO-639 code</a>)
{% endif %}

<div class="ui segment">
{% if container and release.release_status == 'published' %}
<div class="ui top attached label">
Published as a <i>{{ release.release_type }}</i> in <a href="/container/{{ container.ident }}">{{ container.name }}</a>
{% if container.extra.is_oa %} (open access!){% endif %}
</div>
{% endif %}
{% if container.issnl != None %}<br><b>ISSN-L:</b> {{ container.issnl }}{% endif %}
{% if release.volume != None %}<br><b>Volume:</b> {{ release.volume }}{% endif %}
{% if release.issue != None %}<br><b>Issue:</b> {{ release.issue }}{% endif %}
{% if release.pages != None %}<br><b>Page(s):</b> {{ release.pages }}{% endif %}
{% if release.publisher != None %}<br><b>Publisher:</b> {{ release.publisher }}{% endif %}
{% if release.release_status != None %}<br><b>Release Status:</b> {{ release.release_status }}{% endif %}
{% if release.release_type != None %}<br><b>Release Type:</b> {{ release.release_type}}{% endif %}
</div>
There may be other versions or releases (pre-prints, publications, etc) linked
to the same work:
<a href="/work/{{ release.work_id }}"><code>{{ release.work_id }}</code></a>

{% if release.isbn13 != None %}
<p><b>ISBN-13:</b> <code>{{ release.isbn13 }}</code> (<a href="https://openlibrary.org/search?isbn={{ release.isbn13 }}">openlibrary.org</a>)
{% endif %}

{% if release.extra != None %}
<p><b>Additional Metadata (raw JSON):</b>
<pre>{{ release.extra }}</pre>
{% endif %}

<!--
Raw JSON Object:
<pre>{{ release }}</pre>
-->

<br>
<h3>Files</h3>
{% if files != [] %}
Believed to represent this release...
<table class="ui table">
  <thead>
    <tr><th>SHA-1
        <th>Size (bytes)
        <th>File Type
        <th>Links
  </thead>
  <tbody>
  {% for file in files %}
  <tr><td><a href="/file/{{ file.ident }}">{{ file.sha1}}</a>
      <td>{{ file.size }}
      <td>{{ file.mimetype }}
      <td><a href="{{ file.url }}">{{ file.url.split('/')[2] }}</a>
          <br><a href="https://web.archive.org/web/2/{{ file.url }}">web.archive.org</a>
  {% endfor %}
  </tbody>
</table>
</ul>
{% else %}
<p>There are no known files associated with this release (you could try
<a href="/work/{{ release.work_id }}">other releases for this work?</a>).
{% endif %}

<br>
<h3>All Contributors</h3>
{% if release.contribs.size != 0 %}
<table class="ui table">
  <thead>
    <tr><th>Attribution Order
        <th>Name
        <th>Role
  </thead>
  <tbody>
  {% for contrib in release.contribs %}
  <tr><td>{{ contrib.index }}
      {% if contrib.creator_id %}
        <td><a href="/creator/{{contrib.creator_id}}">{{ contrib.raw }}</a> 
      {% else %}
        <td>{{ contrib.raw }}
      {% endif %}
      <td>{{ contrib.role or '' }}
  {% endfor %}
  </tbody>
</table>
{% else %}
<p>Contributors (authors, etc) not known.
{% endif %}

<br>
{% if release.refs.size != 0 %}
<h3>References</h3>
This release citing other releases.
<ul>
  {% for ref in release.refs %}
    <li>{{ ref.raw }}
    {% if ref.target_release_id != None %}
    (<a href="/release/{{ ref.target_release_id }}">fatcat release</a>)
    {% endif %}
  {% endfor %}
</ul>
{% else %}
<p>No reference list available.
{% endif %}

</div>
<div class="five wide column">

<a href="#" class="ui top attached fluid huge green button"><i class="file pdf outline icon"></i>Download Full Text</a>
<div class="ui segment attached">

A Bunch Of Other Content...

<ul>
  <li><a>and links!</a>
  <li><a>and links!</a>
  <li><a>and links!</a>
</ul>

Over here
</div><div class="ui segment attached">
<b>DOI </b> <a href="https://doi.org/{{ release.doi }}">{{ release.doi }}</a>

</div><div class="ui segment attached">
<b>Fatcat Bits</b>
<p>Revision #{{ release.revision }}. State is "{{ release.state }}"

</div>
<div class="two ui buttons bottom attached">
  <a href="#" class="ui blue button">Edit Metadata</a>
  <a href="#" class="ui button">View History</a>
</div>

</div>
</div>
{% endblock %}