Project

General

Profile

1
<?xml version="1.0" encoding="UTF-8"?>
2
<xsl:stylesheet version="2.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" 
3
	xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" exclude-result-prefixes="xsl xsi">
4

    
5
<!-- DO NOT REINDENT THIS FILE: IT IS IMPORTANT THAT EACH PROJECT IS ON ONE SINGLE LINE -->
6
	<xsl:output omit-xml-declaration="yes" standalone="omit" indent="no"/>
7
	
8
	<xsl:template match="/">
9
		<xsl:variable name="jurisdiction" select="//FIELD[@name='jurisdiction']"/>
10
		<xsl:variable name="id" select="//FIELD[@name='grant_agreement_number']" />
11
		<xsl:variable name="title" select="//FIELD[@name='title']" />
12
		<xsl:variable name="acronym" select="//FIELD[@name='acronym']" />
13
		<xsl:variable name="funder" select="//FIELD[@name='funder']" />
14
		<xsl:variable name="fundingProgramme">
15
			<xsl:value-of select="replace(tokenize(//FIELD[@name='fundingpathid'],'::')[3], '/', '%2F')"/>
16
		</xsl:variable>
17
		<xsl:variable name="idnamespace">
18
		<!-- info:eu-repo/grantAgreement/Funder/FundingProgram/ProjectID /[Jurisdiction]/[ProjectName]/[ProjectAcronym]  -->
19
			<xsl:choose>
20
				<xsl:when test="$jurisdiction != ''"><xsl:value-of select="concat('info:eu-repo/grantAgreement/', $funder, '/', $fundingProgramme, '/', $id, '/', $jurisdiction )" /></xsl:when>
21
				<xsl:otherwise><xsl:value-of select="concat('info:eu-repo/grantAgreement/', $funder, '/', $id)" /></xsl:otherwise>
22
			</xsl:choose>
23
		</xsl:variable>
24
		<xsl:variable name="listLabel">
25
		<xsl:choose>
26
				<xsl:when test="$fundingProgramme = 'FP7'">for:value:component:_fp7_project_id</xsl:when>
27
				<xsl:when test="$fundingProgramme = 'H2020'">for:value:component:_h2020_project_id</xsl:when>
28
				<xsl:when test="$funder = 'WT'">for:value:component:_wt_project_id</xsl:when>
29
				<xsl:when test="$funder = 'FCT'">for:value:component:_fct_project_id</xsl:when>
30
				<xsl:when test="$funder = 'NHMRC'">for:value:component:_nhmrc_project_id</xsl:when>
31
				<xsl:when test="$funder = 'ARC'">for:value:component:_arc_project_id</xsl:when>
32
				<xsl:otherwise>info:eu-repo/grantAgreement/</xsl:otherwise>
33
			</xsl:choose>
34
		</xsl:variable>
35
		<xsl:value-of select="concat($acronym, ' - ', $title,  '&#9;')" /><li style='border-right: solid 50px #30FF30' ><xsl:value-of select="concat($id, ' - ', $acronym, ' - ', $title)" /><ul><li id="{$listLabel}"><xsl:value-of select="$idnamespace" /></li></ul></li><xsl:text> 
36
</xsl:text>
37
	</xsl:template>
38
	
39
</xsl:stylesheet>
(2-2/2)