Skip to content
Snippets Groups Projects
Commit d4f40dc0 authored by Thorsten Vitt's avatar Thorsten Vitt
Browse files

Added extra rules for author etc.

authors, funders, sponsors and contributors are now no
longer converted to respStmts but rather to the appropriate
TEI elements in the titleStmt.

fixes issue TG-1921 for the aggregator: 
TextGrid-MD to TEI mapping is not capturing author etc. in a useful way 
https://develop.sub.uni-goettingen.de/jira/browse/TG-1921

git-svn-id: https://develop.sub.uni-goettingen.de/repos/textgrid/trunk/services/aggregator@13860 7c539038-3410-0410-b1ec-0f2a7bf1c452
parent 7cacab5d
No related branches found
No related tags found
No related merge requests found
......@@ -14,8 +14,22 @@
<xsl:value-of select="."/>
</title>
</xsl:for-each>
<xsl:for-each select=".//md:agent">
<xsl:call-template name="convert-authorlike">
<xsl:with-param name="role">author</xsl:with-param>
</xsl:call-template>
<xsl:call-template name="convert-authorlike">
<xsl:with-param name="role">sponsor</xsl:with-param>
</xsl:call-template>
<xsl:call-template name="convert-authorlike">
<xsl:with-param name="role">funder</xsl:with-param>
</xsl:call-template>
<xsl:call-template name="convert-authorlike">
<xsl:with-param name="role">contributor</xsl:with-param>
<xsl:with-param name="element">principal</xsl:with-param>
</xsl:call-template>
<xsl:for-each select=".//md:agent[@role != 'author' and @role != 'sponser' and @role != 'funder' and @role != 'principal']">
<respStmt>
<resp>
<xsl:value-of select="@role"/>
......@@ -287,7 +301,16 @@ and fill out source information in that edition's metadata.</xsl:comment>
</xsl:if>
<xsl:value-of select="$source"/>
</date>
</xsl:template>
</xsl:template>
<xsl:template name="convert-authorlike">
<xsl:param name="role"/>
<xsl:param name="element" select="$role"/>
<xsl:for-each select=".//md:generic/md:provided/md:title[@role = $role]">
<xsl:element name="{$element}">
<xsl:value-of select="."/>
</xsl:element>
</xsl:for-each>
</xsl:template>
</xsl:stylesheet>
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment