Skip to content

Commit 2b63839

Browse files
improved labels in the mobility view
1 parent cc564f3 commit 2b63839

File tree

3 files changed

+50
-24
lines changed

3 files changed

+50
-24
lines changed

src/main/plugin/dcat-ap/formatter/xsl-view/view.xsl

Lines changed: 30 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -28,17 +28,20 @@
2828
xmlns:dc="http://purl.org/dc/elements/1.1/"
2929
xmlns:dct="http://purl.org/dc/terms/"
3030
xmlns:dcat="http://www.w3.org/ns/dcat#"
31+
xmlns:dqv="http://www.w3.org/ns/dqv#"
3132
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
3233
xmlns:skos="http://www.w3.org/2004/02/skos/core#"
3334
xmlns:xs="http://www.w3.org/2001/XMLSchema"
3435
xmlns:vcard="http://www.w3.org/2006/vcard/ns#"
3536
xmlns:locn="http://www.w3.org/ns/locn#"
3637
xmlns:foaf="http://xmlns.com/foaf/0.1/"
38+
xmlns:oa="http://www.w3.org/ns/oa#"
3739
xmlns:owl="http://www.w3.org/2002/07/owl#"
3840
xmlns:dcatap="http://data.europa.eu/r5r/"
3941
xmlns:spdx="http://spdx.org/rdf/terms#"
4042
xmlns:schema="http://schema.org/"
4143
xmlns:mdcat="https://data.vlaanderen.be/ns/metadata-dcat#"
44+
xmlns:mobilitydcatap="https://w3id.org/mobilitydcat-ap"
4245
xmlns:gn-fn-render="http://geonetwork-opensource.org/xsl/functions/render"
4346
xmlns:gn-fn-metadata="http://geonetwork-opensource.org/xsl/functions/metadata"
4447
xmlns:gn-fn-dcat-ap="http://geonetwork-opensource.org/xsl/functions/profiles/dcat-ap"
@@ -386,6 +389,7 @@
386389
<xsl:variable name="sectionContent">
387390
<xsl:apply-templates mode="render-view" select="section|field"/>
388391
</xsl:variable>
392+
389393
<!-- Hide sections if empty -->
390394
<xsl:if test="normalize-space($sectionContent)">
391395
<div id="gn-section-{generate-id()}" class="gn-tab-content">
@@ -433,7 +437,7 @@
433437
</xsl:template>
434438

435439
<!-- Field with lang : display only field of current lang or first one if not exist -->
436-
<xsl:template mode="render-field" match="dct:title|dct:description|foaf:name|adms:versionNotes">
440+
<xsl:template mode="render-field" match="dct:title|dct:description|foaf:name|adms:versionNotes|foaf:firstName|foaf:surname">
437441
<xsl:param name="xpath"/>
438442
<xsl:variable name="stringValue" select="string()"/>
439443
<xsl:variable name="name" select="name()"/>
@@ -549,14 +553,15 @@
549553
</xsl:if>
550554
</xsl:template>
551555

556+
<!-- render the element name (key) and the @rdf:resource (value) -->
552557
<xsl:template mode="render-field"
553-
match="dcat:accessURL|dcat:downloadURL|dcat:landingPage">
558+
match="dcat:accessURL|dcat:downloadURL|dcat:landingPage|foaf:mbox|foaf:phone|foaf:workplaceHomepage">
554559
<xsl:param name="xpath"/>
555560
<xsl:variable name="stringValue" select="string(@rdf:resource)"/>
556561
<xsl:if test="normalize-space($stringValue) != ''">
557562
<tr>
558563
<th style="{$thStyle}">
559-
<xsl:value-of select="gn-fn-metadata:getLabel($schema, 'rdf:resource', $labels, name(.), '', concat(gn-fn-dcat-ap:concatXPaths($xpath, gn-fn-metadata:getXPath(.), name(.)), '/@rdf:resource'))/label" />
564+
<xsl:value-of select="gn-fn-metadata:getLabel($schema, name(.), $labels, name(..), '', gn-fn-dcat-ap:concatXPaths($xpath, gn-fn-metadata:getXPath(.), name(.)))/label" />
560565
</th>
561566
<td style="{$tdStyle}">
562567
<xsl:apply-templates mode="render-url" select="@rdf:resource" />
@@ -570,7 +575,9 @@
570575
<xsl:template mode="render-field" match="dct:type|dct:accrualPeriodicity|dcat:theme|dct:language|dct:format|dcat:mediaType|
571576
adms:status|mdcat:levensfase|mdcat:ontwikkelingstoestand|dct:accessRights|dcat:compressFormat|
572577
dcat:packageFormat|dct:subject|mdcat:MAGDA-categorie|mdcat:statuut|
573-
dcatap:hvdCategory">
578+
dcatap:hvdCategory|
579+
mobilitydcatap:networkCoverage|mobilitydcatap:transportMode| mobilitydcatap:mobilityTheme|
580+
mobilitydcatap:georeferencingMethod|mobilitydcatap:intendedInformationService">
574581
<xsl:param name="xpath"/>
575582
<xsl:variable name="name" select="name()"/>
576583
<xsl:if test="not(preceding-sibling::*[name(.) = $name and position()=1])">
@@ -600,6 +607,25 @@
600607
</xsl:if>
601608
</xsl:template>
602609

610+
<!-- element that include an ao:hasBody -->
611+
<xsl:template mode="render-field" match="mobilitydcatap:assessmentResult|dqv:hasQualityAnnotation">
612+
<xsl:param name="xpath"/>
613+
<xsl:variable name="stringValue" select="string(oa:hasBody/@rdf:resource)"/>
614+
<xsl:if test="normalize-space($stringValue) != ''">
615+
<tr>
616+
<th style="{$thStyle}">
617+
<xsl:value-of select="gn-fn-metadata:getLabel($schema, name(.), $labels, name(..), '', gn-fn-dcat-ap:concatXPaths($xpath, gn-fn-metadata:getXPath(.), name(.)))/label" />
618+
</th>
619+
<td style="{$tdStyle}">
620+
<xsl:apply-templates mode="render-url" select="oa:hasBody/@rdf:resource" />
621+
<xsl:if test="dct:issued">
622+
(<xsl:value-of select="gn-fn-metadata:getLabel($schema, 'dct:issued', $labels)/label "/><xsl:value-of select="' '"/><xsl:value-of select="dct:issued"/>)
623+
</xsl:if>
624+
</td>
625+
</tr>
626+
</xsl:if>
627+
</xsl:template>
628+
603629

604630
<!-- Bbox is displayed with an overview and the geom displayed on it and
605631
the coordinates displayed around -->

src/main/plugin/dcat-ap/loc/dut/labels.xml

Lines changed: 19 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -343,25 +343,26 @@
343343
<label>Documentatie</label>
344344
<description>Documentatie</description>
345345
<btnLabel>Documentatie</btnLabel>
346-
</element><element name="foaf:workplaceHomepage">
347-
<label>URL</label>
348-
<description>The Web site of the agent.</description>
346+
</element>
347+
<element name="foaf:workplaceHomepage">
348+
<label>Werkplek startpagina</label>
349+
<description>The startpagina van de werkplek van de agent.</description>
349350
</element>
350351
<element name="foaf:firstName">
351-
<label>First name</label>
352-
<description>The first name of the agent.</description>
352+
<label>Voornaam</label>
353+
<description>De voornaam van de agent.</description>
353354
</element>
354355
<element name="foaf:surname">
355-
<label>Surname</label>
356-
<description>The surname of the agent.</description>
356+
<label>Achternaam</label>
357+
<description>De achternaam van de agent.</description>
357358
</element>
358359
<element name="foaf:phone">
359-
<label>Phone</label>
360-
<description>The phone number of the agent, specified using fully qualified tel: URI scheme RFC3966.</description>
360+
<label>Telefoon</label>
361+
<description>Het telefoonnummer van de agent, gespecificeerd met behulp van het volledig gekwalificeerde tel: URI-schema RFC3966.</description>
361362
</element>
362363
<element name="foaf:mbox">
363-
<label>Email</label>
364-
<description>The email address of the agent, specified using fully qualified mailto: URI scheme RFC6068.</description>
364+
<label>E-mail</label>
365+
<description>Het e-mailadres van de agent, gespecificeerd met behulp van het volledig gekwalificeerde mailto: URI-schema RFC6068.</description>
365366
</element>
366367
<element name="org:memberOf">
367368
<label>Member of</label>
@@ -1046,9 +1047,9 @@
10461047
<btnLabel>Dekking netwerk</btnLabel>
10471048
</element>
10481049
<element name="mobilitydcatap:georeferencingMethod">
1049-
<label>Georeferencing method</label>
1050-
<description>This property SHOULD be used to specify the georeferencing method used in the dataset.</description>
1051-
<btnLabel>Georeferencing method</btnLabel>
1050+
<label>Georeferentiemethode</label>
1051+
<description>Deze eigenschap MOET worden gebruikt om de georeferentiemethode te specificeren die in de dataset is gebruikt.</description>
1052+
<btnLabel>Georeferentiemethode</btnLabel>
10521053
</element>
10531054
<element name="mobilitydcatap:intendedInformationService">
10541055
<label>Bedoelde informatie service</label>
@@ -1078,9 +1079,8 @@
10781079
<description>The technical data grammar format of the delivered content within the Distribution. It describes the standard on top of the elementary syntax that describe data structures in the dataset.</description>
10791080
</element>
10801081
<element name="mobilitydcatap:assessmentResult">
1081-
<label>Assessment result</label>
1082-
<description>The results and outcomes from an assessment process by an external organisation, e.g., a National Body in the context of EU Delegated Regulations. EU Delegated Regulations require Member States to set up procedures to assess the compliance of the Delegated Regulations, e.g. regarding the provisioning of data via a NAP. These assessment processes are handled by National Bodies and installed individually in each Member State.
1083-
The property may point to the most recent assessment procedure, including its date, its result as a free-text and/or a link referring to an assessment report online.</description>
1082+
<label>Beoordelingsresultaat</label>
1083+
<description>De resultaten en uitkomsten van een beoordelingsproces door een externe organisatie, e.g., een nationale instantie in het kader van gedelegeerde EU-verordeningen. Gedelegeerde EU-verordeningen vereisen dat lidstaten procedures instellen om de naleving van de gedelegeerde verordeningen te beoordelen, bijvoorbeeld met betrekking tot de verstrekking van gegevens via een NAP. Deze beoordelingsprocessen worden uitgevoerd door nationale instanties en zijn per lidstaat afzonderlijk geïmplementeerd. De eigenschap kan verwijzen naar de meest recente beoordelingsprocedure, inclusief de datum, het resultaat als vrije tekst en/of een link naar een online beoordelingsrapport.</description>
10841084
</element>
10851085
<element name="mobilitydcatap:dataFormatNotes">
10861086
<label>Data format notes</label>
@@ -1091,8 +1091,8 @@
10911091
<description>The result of the latest assessment procedure, in form of a URL linking to further details or results. Alternatively, textual information is provided using the Embedded Textual Body construction of the Web Annotation Data Model, which allows to specify text formats and languages which might be relevant for multilingual purposes.</description>
10921092
</element>
10931093
<element name="dqv:hasQualityAnnotation">
1094-
<label>Quality annotation</label>
1095-
<description>An annotation about any quality aspects regarding the delivered content, in particular methods, metrics/indicators and results of a quality assessment in the responsibility of the Data Owner.</description>
1094+
<label>Kwaliteitsannotatie</label>
1095+
<description>Een toelichting over alle kwaliteitsaspecten met betrekking tot de geleverde inhoud, in het bijzonder methoden, meetmethoden/indicatoren en resultaten van een kwaliteitsbeoordeling waarvoor de Data Owner verantwoordelijk is.</description>
10961096
</element>
10971097
<element name="cnt:characterEncoding">
10981098
<label>Character encoding</label>

src/main/plugin/dcat-ap/loc/eng/labels.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -345,7 +345,7 @@
345345
<btnLabel>Documentation</btnLabel>
346346
</element>
347347
<element name="foaf:workplaceHomepage">
348-
<label>URL</label>
348+
<label>Workplace homepage</label>
349349
<description>The Web site of the agent.</description>
350350
</element>
351351
<element name="foaf:firstName">

0 commit comments

Comments
 (0)