Skip to content

add handling for dates of non articles #78

Description

@tcatapano

per Guido:

Also, your expressions only grab the year of publication, the specific date (where available) is in one of these two places:

  • journal articles: mods:relatedItem[./@type = 'host']/mods:part/mods:detail[./@type = 'pubDate']/mods:number
  • books, reports, etc.: mods:originInfo/mods:dateOther[./@type = 'pubDate']

The specific date of publication always is in ISO format, i.e., "YYYY-MM-DD", so you should be able to parse out year, month, and day if required.

<xsl:template match="mods:mods">
<journal-meta>
<journal-id><xsl:value-of select="mods:identifier[@type = 'DOI']"/></journal-id>
<issn><xsl:value-of select="mods:identifier[@type = 'ISSN']"/></issn>
</journal-meta>
<article-meta>
<title-group>
<article-title><xsl:value-of select="mods:titleInfo/mods:title"/></article-title>
</title-group>
<contrib-group>
<xsl:apply-templates select="mods:name[mods:role/mods:roleTerm = 'Author']"/>
</contrib-group>
<pub-date>
<year><xsl:value-of select="mods:relatedItem[@type = 'host']/mods:part/mods:date"/></year>
</pub-date>
</article-meta>
</xsl:template>

Metadata

Metadata

Assignees

Labels

JATSconversionenhancementNew feature or requestmetadataissues related to metadata for sources, etc...

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions