EPrints Technical Mailing List Archive

Message: #07602


< Previous (by date) | Next (by date) > | < Previous (in thread) | Next (in thread) > | Messages - Most Recent First | Threads - Most Recent First

[EP-tech] RT1/Crosswalks - multiple dates


Hello all,

I recently noticed we had an item type in EPrints that hadn't been set up properly (Presentation Material). I have managed to add it to the crosswalks and phrases, but I have a problem that I cannot solve with the metadata.

The "Presentation Date" is sent over from the Elements "publication-date" field and so has a field name in Eprints of "Published" when I want it to say "Presented".

This is controlled via this bit of code in uol_xwalks_default.xml:

<!-- ##################### MULTIPLE DATES ##################### -->
    <xsl:template match="pubs:date" mode="mapping">
        <xsl:param name="name"/>
        <xsl:param name="repo_field"/>
        <xsl:choose>
            <xsl:when test="$repo_field = 'dates'">
                <xsl:element name="date">
                    <xsl:apply-templates select="."/>
                </xsl:element>
                <xsl:element name="date_type">
                    <xsl:choose>
<xsl:when test="$name='publication-date'">published</xsl:when>
                        <xsl:when test="$name='acceptance-date'">accepted</xsl:when>
                        <xsl:when test="$name='filed-date'">filed</xsl:when>
                        <xsl:when test="$name='online-publication-date'">published_online</xsl:when>
                    </xsl:choose>
                </xsl:element>
            </xsl:when>
            <xsl:otherwise>
                <xsl:apply-templates select="." />
            </xsl:otherwise>
        </xsl:choose>
    </xsl:template>


It is the section in bold that I need to alter and add a condition to. Ideally I want to say something along the lines of:

</xsl:when>  test="$name='publication-date' and type='presentation_material'>presented</xsl:when>

but I'm struggling to access the item type. I'm also uncertain as to whether the type should be the EPrint field name that was set in another crosswalks file, or if I should be using some other nomenclature. Complicated further by searching "type" and getting millions of results.

This isn't particularly urgent or even essential, but if anybody has some advice I'd appreciate it.

Thanks,
James