Commit 86e15c6f authored by Øyvind gjesdal's avatar Øyvind gjesdal
Browse files

Revert "remove organization template"

This reverts commit fd7ae645.
parent fd7ae645
Pipeline #49004 passed with stages
in 1 minute and 32 seconds
<!DOCTYPE html>
<html lang="no" prefix="og: http://ogp.me/ns#">
<head>
{%include "../../includes/head_common.inc"%}
{%include "../../includes/head_page.inc"%}
</head>
<body>
{%include "../../includes/sidebar.inc"%}
<div class="pusher">
{%include "../../includes/static_sidebar_left.inc"%}
<div class="ui inverted segment">
<div class="main-content-wrapper">
{%include "../../includes/header.inc"%}
<div class="main-content">
<div class="ui grid">
<div class="ui sixteen wide column">
<h1>{{first.main.label.value}}</h1>
<span class="ui label">{{first.count.total.value}}</span>
{% if first.main.description.value %}<p itemprop="http://schema.org/description">{{first.main.description.value}}</p>{% endif %}
<p>{% if first.main.altname %}Også kjent som: <ul class="list-inline text-muted">{% for row in models.main %}{% ifchanged row.label.value %}<li><i>{{row.altname.value}}</i></li>{% endifchanged %}{% endfor %}</ul>{% endif %}</p>
{% if not first.dbpedia.sameas.dbparticle | null %}
<div class="ui message">
{% for i in models.dbpedia.sameas %}
{% ifchanged i.dbparticle.value %}
<img class="ui small right floated image" src="{{i.thumbnail.value}}">
<p>{% autoescape off %}{{i.abstract.value}}{% endautoescape %}<p>
<p><i class="fa fa-wikipedia-w"></i> Fra Wikipedia (<a href="{{i.dbparticle.value}}"><small>{{i.dbparticle.value}}</small></a>)</p>
{% endifchanged %}
{% endfor %}
</div>
{% endif %}
{% if models.ms|length != 0 %}
<div class="ui message">
<p><strong>{{ first.main.label.value }} er relatert til disse samlingene.</strong> Disse samlingene er ikke tilgjengelig i Marcus, men du kan finne mer informasjon i den gamle <a href="http://www.uib.no/filearchive/manuskriptkatalogen-ms-1-2097.pdf" target="_blank">Manuskriptkatalogen (pdf)</a>.</p>
<div class="ui horizontal list">
{% for row in models.ms %}
<div class="item"><i class="icon fa fa-dot-circle-o"></i> {{row.label.value}}</div>
{% endfor %}
</div>
</div>
{% endif%}
{% if models.collections|length != 0 %}
<div class="ui items">
<h3>Relaterte samlinger</h3>
{% for row in models.collections %}
{% ifchanged row.uri.value %}
<div style="item">
<div class="content">
<h4><i class="fa fa-archive"></i><a href="{{ row.uri.value }}"> {% if row.label && row.label.value != "" %}{{row.label.value}}{% else %} {{row.identifier.value}}{%endif%}</a></h4>
{% if row.description.value %}
<div class="description">
<p>{{row.description.value|truncatewords:35}}</p>
{% endif %}
</div>
<p><span class="ui label">Samling</span> <span><i class="fa fa-key"></i>{{row.identifier.value}}</span></p>
</div>
</div>
{% endifchanged %}
{% endfor %}
</div>
{% endif%}
</div>
</div>
<div class="equal width row">
<div class="three wide column">
<div class="ui list">
{% if first.main.birthdate %}<div class="item"><i class="icon asterisk"></i><div class="content">{{first.main.birthdate.value}}</div></div>{% endif %}
{% if first.main.deathdate %}<div class="item"><i class="icon"><strong></strong></i><div class="content">{{first.main.deathdate.value}}</div></div>{% endif %}
{% if first.main.email.value|length != 0 %}<div class="item"><i class="icon email"></i><div class="content">{{first.main.email.value}}</div></div>{% endif %}
</div>
{% if models.webresources|length != 0 %}
<p><strong class="text-muted">Nettsider</strong><br>
{% for row in models.webresources %}
<a target="_blank" href="{{row.uri.value}}">{{row.label.value}}</a> <i class="fa fa-external-link"></i><br>
{% endfor %}
</p>
{% endif %}
</div>
<div class="column">
{% if first.count.total.value > 100 %}
<div class="ui borderless pagination menu">
<script>
if ("{{lodspk.args.arg1}}".length < 1)
{page = 0;}
else {page = "{{lodspk.args.arg1}}";}
if ("{{lodspk.args.arg0}}".length > 0)
{page=parseInt(page)}
else {}
var offset = 50;
var count = {{first.count.total.value}};
var totalPages = Math.floor(count / 50);
var lastPage = '{{lodspk.home}}instance/person/{{lodspk.args.arg0}}/'+ (count - ((count - (50*totalPages))));
var nextPage = page+offset;
var prevPage = page-offset;
var next_uri = '{{lodspk.home}}instance/person/{{lodspk.args.arg0}}/'+ nextPage;
var prev_uri = '{{lodspk.home}}instance/person/{{lodspk.args.arg0}}/'+ prevPage;
if (prevPage === 0){
document.write('<div class="item"><a href="{{lodspk.home}}instance/person/{{lodspk.args.arg0}}" id="prev"><i class="icon left arrow"></i> Forrige 50</a></div>');
}
else if ("{{lodspk.args.arg1}}".length > 1){
document.write('<div class="item"><a href="{{lodspk.home}}instance/person/{{lodspk.args.arg0}}/">Første side</a></div><div class="item"><a href="" class="prev">Forrige 50</a></div>');
$(".prev").attr("href",prev_uri);
};
if ({{first.count.total.value}} > nextPage){
document.write('<div class="item"><a href="" class="next">Neste 50</a></div><div class="item"><a class="lastpage" href="">Siste side <i class="icon right arrow"></i></a></div>');
$(".next").attr("href",next_uri);
$(".lastpage").attr("href",lastPage);
};
</script>
</div>
{% endif %}
<div class="ui items">
{% for row in models.related %}
{% ifchanged row.uri.value %}
<div class="item">
{% if row.classLabel.value != "Samling" %}
<a class="ui medium image" href="{{row.uri.value}}"><img {% if row.img %}{% else %}data-src="holder.js/100%x150/text:Ingen forhåndsvisning"{% endif %} src="{{row.img.value}}" /></a>
{% endif %}
{% if row.classLabel.value == "Samling" %}
<a class="ui medium image" style="color:#bbb;" href="{{row.uri.value}}">{% if row.img %}<img src="{{row.img.value}}" />{% else %}<span class="right floated fa-stack fa-3x">
<i class="fa fa-circle fa-stack-2x"></i>
<i class="fa fa-archive fa-stack-1x fa-inverse"></i>
</span>{% endif %}</a>
{% endif %}
<div class="content">
<a class="header" href="{{ row.uri.value }}">{% if row.title && row.title.value != "" %}{{row.title.value}}{% else %}{% if row.label && row.label.value != "" %}{{row.label.value}}{% else %} {{row.identifier.value}}{%endif%}{%endif%}</a>
<div class="meta">
{% if row.makerNames %}
<p><i style="margin-right: 5px;" data-trigger="hover" data-toggle="tooltip" data-placement="left" title="Personer knyttet til samlingen eller dokumentet" class="fa fa-users"></i> <strong>{{row.makerNames.value}}</strong></p>
{% endif %}
</div>
{% if row.description.value %}
<div class="description">
<p>{{row.description.value|truncatewords:35}}</p>
</div>{% endif %}
<div class="extra">
{% if row.subjectLabels %}
<p class="text-muted"><i class="fa fa-tags"></i> <i itemprop="keywords">{{row.subjectLabels.value}}</i></p>
{% endif %}
<p> {% if row.classLabel %}<span class="ui label">{{row.classLabel.value}}</span> {% endif %} {% if row.hasTranscription.value == "true" %}<span class="ui label">Transkribert</span>{% endif %} {% if row.hasPage.value == "true" %}<span class="ui label">Faksimile</span>{% endif %} <span ><i class="fa fa-key"></i>{{row.identifier.value}}</span></p>
{% if row.show.value == false %}<p><span class="ui red label">Upublisert</span></p>{% endif %}
{% if row.show.value === "true" %}<p><span class="ui blue label">Publisert</span></p>{% endif %}
</div>
</div>
</div>
{% endifchanged %}
{% endfor %}
</div>
{% if first.count.total.value > 100 %}
<div class="ui borderless pagination menu">
<script>
if ("{{lodspk.args.arg1}}".length < 1)
{page = 0;}
else {page = "{{lodspk.args.arg1}}";}
if ("{{lodspk.args.arg0}}".length > 0)
{page=parseInt(page)}
else {}
var offset = 50;
var count = {{first.count.total.value}};
var totalPages = Math.floor(count / 50);
var lastPage = '{{lodspk.home}}instance/person/{{lodspk.args.arg0}}/'+ (count - ((count - (50*totalPages))));
var nextPage = page+offset;
var prevPage = page-offset;
var next_uri = '{{lodspk.home}}instance/person/{{lodspk.args.arg0}}/'+ nextPage;
var prev_uri = '{{lodspk.home}}instance/person/{{lodspk.args.arg0}}/'+ prevPage;
if (prevPage === 0){
document.write('<div class="item"><a href="{{lodspk.home}}instance/person/{{lodspk.args.arg0}}" id="prev"><i class="icon left arrow"></i> Forrige 50</a></div>');
}
else if ("{{lodspk.args.arg1}}".length > 1){
document.write('<div class="item"><a href="{{lodspk.home}}instance/person/{{lodspk.args.arg0}}/">Første side</a></div><div class="item"><a href="" class="prev">Forrige 50</a></div>');
$(".prev").attr("href",prev_uri);
};
if ({{first.count.total.value}} > nextPage){
document.write('<div class="item"><a href="" class="next">Neste 50</a></div><div class="item"><a class="lastpage" href="">Siste side <i class="icon right arrow"></i></a></div>');
$(".next").attr("href",next_uri);
$(".lastpage").attr("href",lastPage);
};
</script>
</div>
{% endif %}
</div>
</div>
<div class="row">
<div class="column">
<!-- ALL DATA MODAL -->
{% include "../../includes/all-data-modal.inc" %}
</div>
</div>
</div>
</div>
</div>
</div>
{%include "../../includes/footer.inc"%}
</body>
</html>
SELECT ?uri ?name ?img WHERE {
GRAPH <urn:x-arq:UnionGraph> {
<http://data.ub.uib.no/instance/organization/{{ lodspk.args.arg0 }}> schema:children ?uri .
?uri foaf:name ?name .
OPTIONAL { ?uri foaf:img ?img . }
}
}
\ No newline at end of file
SELECT DISTINCT ?uri ?label ?description ?identifier ?img WHERE {
GRAPH <urn:x-arq:UnionGraph> {
<http://data.ub.uib.no/instance/organization/{{ lodspk.args.arg0 }}> ?p ?uri .
?uri rdf:type bibo:Collection .
OPTIONAL { ?uri dct:title ?label . }
OPTIONAL { ?uri rdfs:label ?label . }
OPTIONAL { ?uri dct:identifier ?identifier . }
OPTIONAL { ?uri dct:description ?description . }
OPTIONAL { ?uri ubbont:hasThumbnail ?img . }
}
}
GROUP BY ?uri ?label ?description ?identifier ?img
ORDER BY ?identifier
LIMIT 100
SELECT DISTINCT (COUNT(?imgUri) AS ?total) WHERE {
GRAPH <urn:x-arq:UnionGraph> {
OPTIONAL {<http://data.ub.uib.no/instance/organization/{{ lodspk.args.arg0 }}> ?p ?imgUri . }
}
}
\ No newline at end of file
SELECT ?dbparticle ?abstract ?thumbnail ?birthDate ?deathDate WHERE {
<{{first.main.sameAsDB.value}}> foaf:isPrimaryTopicOf ?dbparticle ;
dbo:abstract ?abstract .
OPTIONAL { <{{first.main.sameAsDB.value}}> foaf:depiction ?thumbnail . }
OPTIONAL { <{{first.main.sameAsDB.value}}> dbo:birthDate ?birthDate . }
OPTIONAL { <{{first.main.sameAsDB.value}}> dbo:deathDate ?deathDate . }
FILTER(LANG(?abstract) = "no" || LANG(?abstract) = "se" || LANG(?abstract) = "en")
}
\ No newline at end of file
SELECT ?uri ?label ?p ?identifier ?img WHERE {
GRAPH <urn:x-arq:UnionGraph> {
?uri foaf:depicts <http://data.ub.uib.no/instance/organization/{{ lodspk.args.arg0 }}> .
?uri ubbont:showWeb true .
OPTIONAL { ?uri dct:identifier ?identifier . }
OPTIONAL { ?uri dct:title ?label . }
OPTIONAL { ?uri rdfs:label ?label . }
OPTIONAL { ?uri ubbont:hasPage?/ubbont:hasRepresentation/ubbont:hasURI ?img . }
FILTER (regex(STR(?img), "th.jpg","i"))
}
}
ORDER BY ?uri
LIMIT 10
SELECT ?uri ?label WHERE {
GRAPH <urn:x-arq:UnionGraph> {
<http://data.ub.uib.no/instance/organization/{{ lodspk.args.arg0 }}> skos:inScheme ?uri .
?uri rdfs:label ?label .
}
}
\ No newline at end of file
SELECT ?label ?firstname ?lastname ?altname ?profession ?description ?sameAsDB ?sameAsM ?deathdate ?deathyearmonth ?deathyear ?birthdate ?birthyearmonth ?birthyear ?birthplaceuri ?birthplace ?deathplaceuri ?deathplace ?img ?email WHERE {
GRAPH <urn:x-arq:UnionGraph> {
OPTIONAL { <http://data.ub.uib.no/instance/organization/{{ lodspk.args.arg0 }}> foaf:name ?label . }
OPTIONAL { <http://data.ub.uib.no/instance/organization/{{ lodspk.args.arg0 }}> foaf:familyName ?lastname . }
OPTIONAL { <http://data.ub.uib.no/instance/organization/{{ lodspk.args.arg0 }}> foaf:firstName ?firstname . }
OPTIONAL { <http://data.ub.uib.no/instance/organization/{{ lodspk.args.arg0 }}> ubbont:invertedName ?label . }
OPTIONAL { <http://data.ub.uib.no/instance/organization/{{ lodspk.args.arg0 }}> skos:altLabel ?altname . }
OPTIONAL { <http://data.ub.uib.no/instance/organization/{{ lodspk.args.arg0 }}> dbo:profession ?profession . }
OPTIONAL { <http://data.ub.uib.no/instance/organization/{{ lodspk.args.arg0 }}> dct:description ?description . }
OPTIONAL { <http://data.ub.uib.no/instance/organization/{{ lodspk.args.arg0 }}> dbo:birthDate ?birthdate . }
OPTIONAL { <http://data.ub.uib.no/instance/organization/{{ lodspk.args.arg0 }}> dbo:deathDate ?deathdate . }
OPTIONAL { <http://data.ub.uib.no/instance/organization/{{ lodspk.args.arg0 }}> dbo:birthPlace ?birthplaceuri . ?birthplaceuri skos:prefLabel ?birthplace . }
OPTIONAL { <http://data.ub.uib.no/instance/organization/{{ lodspk.args.arg0 }}> dbo:deathPlace ?deathplaceuri . ?deathplaceuri skos:prefLabel ?deathplace . }
OPTIONAL { <http://data.ub.uib.no/instance/organization/{{ lodspk.args.arg0 }}> foaf:img ?img . }
OPTIONAL { <http://data.ub.uib.no/instance/organization/{{ lodspk.args.arg0 }}> ubbont:hasThumbnail ?img . }
OPTIONAL { <http://data.ub.uib.no/instance/organization/{{ lodspk.args.arg0 }}> schema:email ?email . }
OPTIONAL { <http://data.ub.uib.no/instance/organization/{{ lodspk.args.arg0 }}> rdfs:seeAlso ?sameAsDB .
FILTER(STRSTARTS(STR(?sameAsDB), "http://dbpedia.org"))
}
OPTIONAL { <http://data.ub.uib.no/instance/organization/{{ lodspk.args.arg0 }}> ubbont:sameAs ?sameAsM .
FILTER(STRSTARTS(STR(?sameAsM), "http://data.ub.uib.no"))
}
}
}
\ No newline at end of file
SELECT ?label WHERE {
GRAPH <urn:x-arq:UnionGraph> {
<http://data.ub.uib.no/instance/organization/{{lodspk.args.arg0}}> dc:relation ?label .
FILTER isLiteral(?label)
}
}
ORDER BY ?label
\ No newline at end of file
SELECT ?uri ?name ?img WHERE {
GRAPH <urn:x-arq:UnionGraph> {
<http://data.ub.uib.no/instance/organization/{{ lodspk.args.arg0 }}> schema:parent ?uri .
?uri foaf:name ?name .
OPTIONAL { ?uri foaf:img ?img . }
}
}
\ No newline at end of file
SELECT ?p ?classLabel ?o ?label WHERE {
GRAPH <urn:x-arq:UnionGraph> {
{
<{{uri}}> ?p ?o .
OPTIONAL { ?o foaf:name ?label . }
OPTIONAL { ?o dct:title ?label . }
OPTIONAL { ?o skos:prefLabel ?label . }
OPTIONAL { ?o rdfs:label ?label . }
OPTIONAL { ?p rdfs:label ?classLabel . FILTER(langMatches(lang(?classLabel), ""))}
}
MINUS
{
<{{uri}}> ubbont:hasPage ?oo .
}
}
}
ORDER BY ?p
LIMIT 100
\ No newline at end of file
SELECT DISTINCT ?uri ?title ?label ?description ?classLabel ?identifier (group_concat(distinct ?subjectLabel ; separator = ", ") AS ?subjectLabels) (group_concat(distinct ?makerName ; separator = "; ") AS ?makerNames ) ?img ?hasPage ?hasTranscription ?nr1
WHERE {
GRAPH <urn:x-arq:UnionGraph> {
<http://data.ub.uib.no/instance/organization/{{ lodspk.args.arg0 }}> ?p ?uri .
?uri rdf:type ?class .
OPTIONAL { ?uri dct:title ?title . }
OPTIONAL { ?uri rdfs:label ?label . }
OPTIONAL { ?uri ubbont:sequenceNr ?nr }
OPTIONAL { ?uri dct:identifier ?identifier . }
OPTIONAL { ?uri dct:description ?description . }
OPTIONAL { ?uri dct:subject ?subject . ?subject skos:prefLabel ?subjectLabel . }
OPTIONAL { ?uri foaf:maker ?maker . ?maker foaf:name ?makerName . }
OPTIONAL { ?uri ubbont:hasThumbnail ?thumb . }
OPTIONAL { ?uri ubbont:hasRepresentation/dct:hasPart/ubbont:hasSMView ?img1 . }
BIND ( EXISTS { ?uri ubbont:hasPage ?page } AS ?hasPage )
BIND ( EXISTS { ?uri ubbont:hasTranscription ?transcription } AS ?hasTranscription )
BIND (if (!bound( ?nr ), 500, ?nr) AS ?nr1 )
BIND(COALESCE(?img1, ?thumb) AS ?img )
}
GRAPH ubbont:ubbont {
?class rdfs:label ?classLabel .
FILTER(langMatches(lang(?classLabel), "")) }
}
GROUP BY ?uri ?title ?label ?description ?classLabel ?identifier ?subjectLabels ?makerNames ?img ?hasPage ?hasTranscription ?nr1
ORDER BY ?nr1 ?identifier
OFFSET {{lodspk.args.arg1|default:0}}
LIMIT 50
SELECT ?s ?label ?p ?classLabel WHERE {
GRAPH <urn:x-arq:UnionGraph> {
{
?s ?p <{{uri}}> .
OPTIONAL { ?s foaf:name ?label . }
OPTIONAL { ?s dct:title ?label . }
OPTIONAL { ?s skos:prefLabel ?label . }
OPTIONAL { ?s rdfs:label ?label . }
?p rdfs:label ?classLabel .
FILTER(langMatches(lang(?classLabel), ""))
}
MINUS
{
?s ubbont:pageIn <{{uri}}> .
}
}
}
ORDER BY ?p
LIMIT 100
\ No newline at end of file
SELECT ?uri ?name ?img WHERE{
GRAPH <urn:x-arq:UnionGraph> {
<http://data.ub.uib.no/instance/organization/{{lodspk.args.arg0}}> foaf:page ?webresource .
?webresource ubbont:hasURI ?uri .
?webresource rdfs:label ?label .}
}
\ No newline at end of file
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment