--- /dev/null
+<?xml version="1.1" encoding="iso-8859-1"?>
+<!DOCTYPE xsl:stylesheet [
+<!ENTITY nbsp " ">
+]>
+<xsl:transform xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:java="xalan://xml.apache.org/xalan/java" xmlns="http://www.minefi.gouv.fr/cp/helios/pes/versement/1.0" xmlns:n="http://www.minefi.gouv.fr/cp/helios/pes/versement/1.0" xmlns:added="http://projets.admisource.gouv.fr/xemelios/namspaces#added" xmlns:ano="http://projets.admisource.gouv.fr/xemelios/namspaces#anomally"
+ exclude-result-prefixes="java xsl" version="2.0">
+
+ <xsl:output method="xml" indent="yes"/>
+
+ <xsl:param name="language" select="'fr'"/>
+
+ <xsl:template match="/*[position()=1]">
+ <xsl:choose>
+ <xsl:when test="local-name()='EtatVersement'">
+ <EtatVersement xmlns="http://www.minefi.gouv.fr/cp/helios/pes/versement/1.0" xmlns:n="http://www.minefi.gouv.fr/cp/helios/pes/versement/1.0" xmlns:added="http://projets.admisource.gouv.fr/xemelios/namspaces#added" xmlns:ano="http://projets.admisource.gouv.fr/xemelios/namspaces#anomally">
+ <xsl:apply-templates/>
+ </EtatVersement>
+ </xsl:when>
+ </xsl:choose>
+
+ </xsl:template>
+
+ <xsl:template match="*">
+ <xsl:choose>
+ <xsl:when test="name(.) = 'Correspondance'">
+ <xsl:element name="{name(.)}" namespace="http://www.minefi.gouv.fr/cp/helios/pes/versement/1.0">
+ <xsl:element name="Libelle" namespace="http://www.minefi.gouv.fr/cp/helios/pes/versement/1.0">
+ <xsl:attribute name="V">
+ <xsl:value-of select="translate(concat(Libelle/@V,' (',Code/@V,')'),'"','')"/>
+ </xsl:attribute>
+ </xsl:element>
+ <xsl:element name="Code" namespace="http://www.minefi.gouv.fr/cp/helios/pes/versement/1.0">
+ <xsl:attribute name="V">
+ <xsl:value-of select="translate(Code/@V,'"','')"/>
+ </xsl:attribute>
+ </xsl:element>
+ </xsl:element>
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:choose>
+ <xsl:when test="name(.)='Nomenclatures'">
+ <xsl:element name="{name(.)}" namespace="http://www.minefi.gouv.fr/cp/helios/pes/versement/1.0">
+ <xsl:if test="count(//ReferenceNomenclature)>0">
+ <xsl:attribute name="Code">
+ <xsl:value-of select="//ReferenceNomenclature/Code/@V"/>
+ </xsl:attribute>
+ <xsl:attribute name="Libelle">
+ <xsl:value-of select="//ReferenceNomenclature/Libelle/@V"/>
+ </xsl:attribute>
+ </xsl:if>
+ <xsl:for-each select="./@*">
+ <xsl:attribute name="{name(.)}" select="translate(.,'"','')"/>
+ </xsl:for-each>
+ <xsl:apply-templates/>
+ </xsl:element>
+ </xsl:when>
+ <xsl:otherwise>
+ <xsl:element name="{name(.)}" namespace="http://www.minefi.gouv.fr/cp/helios/pes/versement/1.0">
+ <xsl:for-each select="./@*">
+ <xsl:attribute name="{name(.)}" select="translate(.,'"','')"/>
+ </xsl:for-each>
+ <xsl:apply-templates/>
+ </xsl:element>
+ </xsl:otherwise>
+ </xsl:choose>
+ </xsl:otherwise>
+ </xsl:choose>
+ </xsl:template>
+
+
+
+</xsl:transform>