Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve /reconcile page #400

Merged
merged 5 commits into from
Jun 17, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
78 changes: 78 additions & 0 deletions app/views/gnd.scala.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,78 @@
@* Copyright 2015-2024 Fabian Steeg, hbz. Licensed under the EPL 2.0 *@

@(title: String)(content: Html)

<!DOCTYPE html>

<html lang="de">
<head>
<title>@title</title>
<link rel="stylesheet" media="all" href="@controllers.routes.Assets.versioned("stylesheets/bootstrap.min.css")">
<link rel="stylesheet" media="all" href="@controllers.routes.Assets.versioned("stylesheets/octicons.css")">
<link rel="stylesheet" media="all" href="@controllers.routes.Assets.versioned("stylesheets/jquery-ui.min.css")">
<link rel="stylesheet" media="all" href='@controllers.routes.Assets.versioned("stylesheets/font-awesome.min.css")'>
<link rel="stylesheet" media="all" href="@controllers.routes.Assets.versioned("stylesheets/main.css")">
<link rel="shortcut icon" type="image/png" href="@controllers.routes.Assets.versioned("images/gnd.png")">
<script src="@controllers.routes.Assets.versioned("javascripts/jquery-1.10.2.min.js")"></script>
<script src="@controllers.routes.Assets.versioned("javascripts/jquery-ui.min.js")"></script>
<script src="@controllers.routes.Assets.versioned("javascripts/bootstrap.min.js")"></script>
<script src="@controllers.routes.Assets.versioned("javascripts/main.js")"></script>
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta http-equiv="X-UA-Compatible" content="IE=EmulateIE10">
</head>
<body>
<div class="container">
<p/>
<div class="navbar navbar-default" role="navigation">
<div class="container-fluid" id="header-gnd">
<div class="navbar-header">
<button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#resources-nav">
<span class="sr-only">Navigation ein/ausblenden</span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
<a class="navbar-brand" href="https://lobid.org/gnd">
<img id="small-logo" src='@controllers.routes.Assets.versioned("images/favicon.png")' alt="lobid-gnd"/>
</a>
<a class="navbar-brand" id="small-gnd-logo-link" href="https://gnd.network">
<img id="small-logo" src='@controllers.routes.Assets.versioned("images/gnd.png")' alt="gnd.network"/>
</a>
</div>
<div class="navbar-collapse collapse" id="resources-nav">

<ul class="nav navbar-nav navbar-right">
<li class="divider"></li>
<li @if(title.contains("Dataset")){class="active"} class="dropdown">
<a href="#" class="dropdown-toggle" data-toggle="dropdown" title="Info" style='color:white'><span class="glyphicon glyphicon-info-sign"></span><b class="caret"></b></a>
<ul class="dropdown-menu">
<li class="dropdown-header">Dokumentation</li>
<li><a href="http://lobid.org/usage-policy" target="_blank">Richtlinien zur API-Nutzung</a></li>
<li class="divider"></li>
<li class="dropdown-header">Kontakt</li>
<li><a href="mailto:lobid-admin@@hbz-nrw.de?subject=Feedback%20zum%20GND-Reconciliation-Service">Feedback zum Reconciliation-Service</a></li>
</ul>
</li>
</ul>
</div><!--/.nav-collapse -->
</div><!--/.container-fluid -->
</div>
@content
<div class="panel panel-default footer-gnd">
<div class="panel-body">
<span class="pull-left">
<img id='small-logo' src='@controllers.routes.Assets.versioned("images/gnd.png")' alt="GND-Logo"/> &nbsp;
GND Reconciliation | ein Dienst im <a href='https://gnd.network'>gnd.network</a>
</span>
<span class="pull-right">
<a href="http://lobid.org/warranty">Gewährleistung</a> |
<a href="http://www.hbz-nrw.de/impressum">Impressum</a> |
<a href="https://github.com/hbz/lobid/blob/master/conf/Datenschutzerklaerung_lobid.textile">Datenschutz</a> |
<a href="http://github.com/hbz/lobid-gnd"><i class="fa-brands fa-github" aria-hidden="true"></i> GitHub</a>&nbsp;
<a href="https://wiki.dnb.de/pages/viewrecentblogposts.action?key=GND"><i class="fa fa-pencil" aria-hidden="true"></i> Blog</a>
</span>
</div>
</div>
</div>
</body>
</html>
55 changes: 28 additions & 27 deletions app/views/reconcile.scala.html
Original file line number Diff line number Diff line change
Expand Up @@ -6,24 +6,25 @@
<dt>@Html(label)</dt> <dd><a href='@link'>@java.net.URLDecoder.decode(link.toString.replaceAll("[&?]format=json$", ""), "UTF-8")</a></dd>
}

@main("", "lobid-gnd - Reconcile") {
@gnd("GND Reconciliation") {
<div class='pull-right'>
<img src='@controllers.routes.Assets.versioned("images/gnd.jpg")' height='85px'/>
<img src='@controllers.routes.Assets.versioned("images/gnd.png")' height='85px'/>
<img src='@controllers.routes.Assets.versioned("images/refine.png")' height='100px'/>
</div>

<h1>GND reconciliation for OpenRefine</h1>
<h1>GND Reconciliation</h1>

<p class="lead">Align your data with the Integrated Authority File GND</p>
<p class="lead">Abgleich eigener Daten mit der Gemeinsamen Normdatei</p>

<p>
Use this URL in OpenRefine: <code>@controllers.HomeController.config("host")@routes.Reconcile.reconcile()</code>
</p>
<p>Dieser Dienst ermöglicht den Abgleich eigener Daten mit der Gemeinsamen Normdatei, insbesondere mit OpenRefine, einem nicht nur im Bibliotheksbereich weitverbreiteten Werkzeug. OpenRefine bietet zahlreiche Funktionalitäten zur Bereinigung und Transformation von Daten, sowie zum Abgleich (Reconciliation) mit externen Datenquellen und zur Anreicherung auf Basis der abgeglichenen Daten. Dieser Dienst stellt die GND als eine solche Datenquelle in OpenRefine bereit. Der Dienst kann zugleich auch in anderen Anwendungen verwendet werden, z. B. im Bibliotheksmanagementsystem Alma über Alma Refine (s. <a href="https://reconciliation-api.github.io/census/clients/">weitere Clients</a>).</p>

<p>Service-URL: <code>@controllers.HomeController.config("host")@routes.Reconcile.reconcile()</code></p>

<h2>Data and Tools</h2>
<h2>Daten und Werkzeuge</h2>

<p><a href='https://www.dnb.de/EN/Professionell/Standardisierung/GND/gnd_node.html'>Integrated Authority File GND</a></p>
<p><a href='https://www.dnb.de/DE/Professionell/Standardisierung/GND/gnd_node.html'>Gemeinsamen Normdatei GND</a> <span class="label label-info">de</span></p>
<p><a href='http://openrefine.org/'>OpenRefine</a>, <a href="https://docs.openrefine.org/manual/reconciling/">Reconciliation</a></p>
<p><a href='https://reconciliation-api.github.io/census/clients/'>Known clients</a></p>

<h2>Tutorials</h2>

Expand All @@ -34,49 +35,49 @@ <h2>Tutorials</h2>
<h2>Community</h2>
<p><a href="https://www.w3.org/community/reconciliation/">W3C entity reconciliation community group</a></p>
<p><a href="https://reconciliation-api.github.io/testbench/">Reconciliation service test bench</a></p>
<p><a href="https://metadaten.community">metadaten.community forum</a></p>
<p><a href="https://metadaten.community">metadaten.community Forum</a> <span class="label label-info">de</span></p>

<h2>API</h2>

<p>
This service provides an implementation of the OpenRefine
Dieser Dienst implementiert die OpenRefine
<a href="https://docs.openrefine.org/manual/reconciling/">Reconciliation</a>
<a href="https://openrefine.org/docs/technical-reference/reconciliation-api">API</a>.
</p>

<h3>General API <small>(<a href="https://www.w3.org/community/reports/reconciliation/CG-FINAL-specs-0.2-20230410">spec</a>)</small></h3>
<h3>Allgemeine API <small>(<a href="https://www.w3.org/community/reports/reconciliation/CG-FINAL-specs-0.2-20230410">spec</a>)</small></h3>

<p><b>Service</b><br/>
<code>curl @controllers.HomeController.config("host")@routes.Reconcile.reconcile()</code>
<p><b>JSONP callback</b><br/>
<p><b>JSONP-callback</b><br/>
<code>curl @controllers.HomeController.config("host")@routes.Reconcile.main("jsonp")</code>
<p><b>CORS header</b><br/>
<p><b>CORS-header</b><br/>
<code>curl --head @controllers.HomeController.config("host")@routes.Reconcile.reconcile() | grep Access-Control-Allow-Origin</code>
</p>

<h3>View API</h3>
<h3>View-API</h3>

@desc("Preview entities (<a href=\"https://www.w3.org/community/reports/reconciliation/CG-FINAL-specs-0.2-20230410/#preview-service\">spec</a>)", routes.HomeController.authorityDotFormat("118624822", "preview"))
@desc("View entities (<a href=\"https://www.w3.org/community/reports/reconciliation/CG-FINAL-specs-0.2-20230410/#dfn-view-template\">spec</a>)", routes.HomeController.authority("118624822"))
@desc("Entities: preview (<a href=\"https://www.w3.org/community/reports/reconciliation/CG-FINAL-specs-0.2-20230410/#preview-service\">spec</a>)", routes.HomeController.authorityDotFormat("118624822", "preview"))
@desc("Entities: view (<a href=\"https://www.w3.org/community/reports/reconciliation/CG-FINAL-specs-0.2-20230410/#dfn-view-template\">spec</a>)", routes.HomeController.authority("118624822"))

<h3>Query API <small>(<a href="https://www.w3.org/community/reports/reconciliation/CG-FINAL-specs-0.2-20230410/#reconciliation-queries">spec</a>)</small></h3>
<h3>Query-API <small>(<a href="https://www.w3.org/community/reports/reconciliation/CG-FINAL-specs-0.2-20230410/#reconciliation-queries">spec</a>)</small></h3>

@desc("Query: GET", routes.Reconcile.main(queries="{\"q1\":{\"query\":\"Twain, Mark\"}}"))
<p><b>Query: POST</b><br/>
<code>curl --data 'queries={"q1":{"query":"Twain, Mark"}}' @controllers.HomeController.config("host")@routes.Reconcile.reconcile()</code></p>

<h3>Suggest API <small>(<a href="https://www.w3.org/community/reports/reconciliation/CG-FINAL-specs-0.2-20230410/#suggest-services">spec</a>)</small></h3>
<h3>Suggest-API <small>(<a href="https://www.w3.org/community/reports/reconciliation/CG-FINAL-specs-0.2-20230410/#suggest-services">spec</a>)</small></h3>

@desc("Suggest entities ", routes.Reconcile.suggest(service="entity", prefix="hbz"))
@desc("Suggest types ", routes.Reconcile.suggest(service="type", prefix="werk"))
@desc("Suggest properties ", routes.Reconcile.suggest(service="property", prefix="beruf"))
@desc("Flyout entities ", routes.Reconcile.flyout(service="entity", id="2047974-8"))
@desc("Flyout types ", routes.Reconcile.flyout(service="type", id="Work"))
@desc("Flyout properties ", routes.Reconcile.flyout(service="property", id="professionOrOccupation"))
@desc("Suggest: entity ", routes.Reconcile.suggest(service="entity", prefix="hbz"))
@desc("Suggest: type ", routes.Reconcile.suggest(service="type", prefix="werk"))
@desc("Suggest: property ", routes.Reconcile.suggest(service="property", prefix="beruf"))
@desc("Flyout: entity ", routes.Reconcile.flyout(service="entity", id="2047974-8"))
@desc("Flyout: type ", routes.Reconcile.flyout(service="type", id="Work"))
@desc("Flyout: property ", routes.Reconcile.flyout(service="property", id="professionOrOccupation"))

<h3>Data extension API</h3>
<h3>Data-extension-API</h3>

@desc("Property proposal (<a href=\"https://www.w3.org/community/reports/reconciliation/CG-FINAL-specs-0.2-20230410/#data-extension-property-proposals\">spec</a>)", routes.Reconcile.properties("","Work",""))
@desc("Property-proposals (<a href=\"https://www.w3.org/community/reports/reconciliation/CG-FINAL-specs-0.2-20230410/#data-extension-property-proposals\">spec</a>)", routes.Reconcile.properties("","Work",""))
@desc("Extend: GET (<a href=\"https://www.w3.org/community/reports/reconciliation/CG-FINAL-specs-0.2-20230410/#data-extension-service\">spec</a>)", routes.Reconcile.main(extend="{\"ids\":[\"1081942517\",\"4791358-7\"],\"properties\":[{\"id\":\"preferredName\"},{\"id\":\"firstAuthor\"}]}"))
<p><b>Extend: POST</b><br/>
<code>curl --data 'extend={"ids":["1081942517","4791358-7"],"properties":[{"id":"preferredName"},{"id":"firstAuthor"}]}' @controllers.HomeController.config("host")@routes.Reconcile.reconcile()</code></p>
Expand Down
Binary file removed public/images/gnd.jpg
Binary file not shown.
Binary file added public/images/gnd.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
29 changes: 29 additions & 0 deletions public/stylesheets/main.css
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,25 @@ dd {
background-repeat: repeat-x;
}

#header-gnd {
width: 100%;
background: #0069b4;
}

.label-info {
background-color: #0069b4;
}

#small-logo {
height: 25px;
border: 1px solid white;
background: white;
}

#small-gnd-logo-link {
padding: 5px;
}

#header #butterfly {
height: 25px;
}
Expand Down Expand Up @@ -119,6 +138,16 @@ ul.facet li {
margin-top: 30px;
}

.footer-gnd {
margin-top: 30px;
background: #0069b4;
color: white;
}

.footer-gnd a {
color: white;
}

.pagination {
margin-top: 0px !important;
margin-bottom: 0px !important;
Expand Down
Loading