Skip to content

Commit

Permalink
Spatial representation type should not be mandatory. Fixes #299 (#300)
Browse files Browse the repository at this point in the history
  • Loading branch information
josegar74 committed Feb 6, 2023
1 parent 4dad6f3 commit 536c78c
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 5 deletions.
5 changes: 0 additions & 5 deletions src/main/plugin/iso19139.ca.HNAP/inflate-metadata.xsl
Original file line number Diff line number Diff line change
Expand Up @@ -373,11 +373,6 @@

<xsl:apply-templates select="gmd:aggregationInfo" />
<xsl:apply-templates select="gmd:spatialRepresentationType" />
<xsl:if test="not(gmd:spatialRepresentationType)">
<gmd:spatialRepresentationType>
<gmd:MD_SpatialRepresentationTypeCode codeListValue="" codeList="http://nap.geogratis.gc.ca/metadata/register/napMetadataRegister.xml#IC_109"/>
</gmd:spatialRepresentationType>
</xsl:if>

<xsl:apply-templates select="gmd:spatialResolution" />
<xsl:apply-templates select="gmd:language" />
Expand Down
12 changes: 12 additions & 0 deletions src/main/plugin/iso19139.ca.HNAP/layout/config-editor.xml
Original file line number Diff line number Diff line change
Expand Up @@ -453,6 +453,18 @@

<field xpath="/gmd:MD_Metadata/gmd:identificationInfo/gmd:MD_DataIdentification/gmd:spatialRepresentationType"/>

<action type="add" name="spatialRepresentationType" or="spatialRepresentationType"
in="/gmd:MD_Metadata/gmd:identificationInfo/gmd:MD_DataIdentification"
if="count(gmd:MD_Metadata/gmd:identificationInfo/gmd:MD_DataIdentification/gmd:spatialRepresentationType) = 0">
<template>
<snippet>
<gmd:spatialRepresentationType>
<gmd:MD_SpatialRepresentationTypeCode codeListValue="" codeList="http://nap.geogratis.gc.ca/metadata/register/napMetadataRegister.xml#IC_109"/>
</gmd:spatialRepresentationType>
</snippet>
</template>
</action>

<field xpath="/gmd:MD_Metadata/gmd:identificationInfo/gmd:MD_DataIdentification/gmd:citation/gmd:CI_Citation/gmd:citedResponsibleParty "
in="/gmd:MD_Metadata/gmd:identificationInfo/gmd:MD_DataIdentification/gmd:citation/gmd:CI_Citation"
or="citedResponsibleParty"/>
Expand Down
1 change: 1 addition & 0 deletions src/main/plugin/iso19139.ca.HNAP/loc/eng/labels.xml
Original file line number Diff line number Diff line change
Expand Up @@ -1934,6 +1934,7 @@
</element>
<element name="gmd:spatialRepresentationType" id="37.0">
<label>Spatial representation type</label>
<btnLabel>Add spatial representation type</btnLabel>
<description>Method used to spatially represent geographic information</description>
</element>
<element name="gmd:spatialResolution" id="38.0">
Expand Down
1 change: 1 addition & 0 deletions src/main/plugin/iso19139.ca.HNAP/loc/fre/labels.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2663,6 +2663,7 @@
</element>
<element name="gmd:spatialRepresentationType" id="37.0">
<label>Type de représentation spatiale</label>
<btnLabel>Ajouter type de représentation spatiale</btnLabel>
<description>Méthode utilisée pour représenter spatialement l'information géographique</description>
</element>
<element name="gmd:spatialResolution" id="38.0">
Expand Down

0 comments on commit 536c78c

Please sign in to comment.