-
Notifications
You must be signed in to change notification settings - Fork 0
/
publications.html
99 lines (97 loc) · 3.65 KB
/
publications.html
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
---
layout: page
title: Publications
rdf_prefix_path: "_data/prefix.sparql"
weight: 100
description: "Here you can find a list of my publications. Most of them with an open accessible link."
---
{% capture query %}
SELECT DISTINCT ?publication WHERE {
{
?publication dct:creator <http://aksw.org/NatanaelArndt>
} UNION {
?publication dct:creator [ ?num <http://aksw.org/NatanaelArndt> ]
}
OPTIONAL {
{
?publication dct:issued ?issued
} UNION {
?publication dct:isPartOf ?collection .
?collection dct:issued ?issued
}
BIND(STRDT(if(
datatype(?issued) = xsd:date,
CONCAT(STR(?issued), "T00:00:00"),
if(
datatype(?issued) = xsd:gYearMonth,
CONCAT(STR(?issued), "-01T00:00:00"),
if(datatype(?issued) = xsd:gYear,
CONCAT(STR(?issued), "-01-01T00:00:00"),
"2006-10-01T00:00:00"
)
)
), xsd:dateTime) AS ?issued_order)
}
}
ORDER BY DESC(?issued_order)
{% endcapture %}
{% assign resultset = page.rdf | sparql_query: query %}
{% for result in resultset %}
<!-- {{ result.publication }} -->
<div class="posts">
<div>
<h3 class="post-link">
<a href="{{ result.publication.page_url }}">{{ result.publication | rdf_property: "dct:title" }}</a>
</h3>
{% assign creators = result.publication | rdf_container: "dct:creator" %}
<span class="meta post-date">
<em>by</em>
{% for creator in creators %}
{%- if creator.iri -%}
<span class="author">{{ creator | rdf_property: "foaf:name" }}</span>
{%- else -%}
<span class="author">{{ creator }}</span>
{%- endif -%}
{% unless forloop.last %}, {% endunless %}
{%- endfor -%}
{%- assign comment = result.publication | rdf_property: "rdfs:comment" -%}
{%- if comment -%}
 <em>({{ comment }})</em>
{%- endif -%}
{%- assign publisher = result.publication | rdf_property: "dct:publisher" -%}
{%- if publisher -%}
</div>
<div>
<em>at</em>
<span class="publisher">{{ publisher }}</span>
{%- endif -%}
{%- assign collection = result.publication | rdf_property: "dct:isPartOf" -%}
{%- if collection -%}
<br/>
<em>in</em>
{% if collection.iri %}
<span class="journal">
{%- assign editors = collection | rdf_container: "bibtex:editor" -%}
{{ collection | rdf_property: "dct:title" }}
{%- if editors.size > 0 %}
(Editors: 
{%- for editor in editors -%}
<span class="editor">{{ editor | rdf_property: "foaf:name" }}</span>{% unless forloop.last %}, {% endunless %}{% endfor %}){% endif %}</span>,
<span class="date">{{ collection | rdf_property: "dct:issued" }}</span>
{% else %}
<span class="journal">{{ collection }}</span>
{% endif %}
<br/>
{%- else -%}
{%- assign submitted = result.publication | rdf_property: "dct:dateSubmitted" -%}
{%- assign accepted = result.publication | rdf_property: "dct:dateAccepted" -%}
{%- if submitted or accepted -%}
; submitted: <span class="date">{{ submitted }}</span>, accepted: <span class="date">{{ accepted }}</span>, published: <span class="date">{{ result.publication | rdf_property: "dct:issued" }}</span>
{%- else -%}
; <span class="date">{{ result.publication | rdf_property: "dct:issued" }}</span>
{%- endif -%}
{% endif %}
</span>
</div>
</div>
{% endfor %}