<!--
//**************************************************************************
//*
//* APPLICATION ........ : XML EDI
//* CLASS .............. : Feuille de style de transformation d'un fichier 
//*                        de resultats au format XSL-FO 
//* WRITER ............. : L. CHEVRY
//*
//* CREATION DATE ...... : june 2005
//*
//* MODULE ............. :xmledi
//*
//**************************************************************************
--><xsl:stylesheet xmlns:fo="http://www.w3.org/1999/XSL/Format" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:ref="http://xml.sandre.eaufrance.fr/scenario/referentiel/2" version="2.0" xpath-default-namespace="http://xml.sandre.eaufrance.fr/scenario/labo_dest/1"><xsl:output method="xml" version="1.0" encoding="ISO-8859-1"/><xsl:param name="refFile"/><xsl:variable name="mergeResults"><xsl:apply-templates mode="copy" select="/"/></xsl:variable><xsl:template match="/"><xsl:apply-templates mode="transform" select="$mergeResults"/></xsl:template><xsl:template match="/LABO_DEST" mode="copy"><xsl:message>XSL REF FILE = <xsl:value-of select="$refFile"/></xsl:message><xsl:copy><xsl:apply-templates select="document($refFile)" mode="copy"/><xsl:apply-templates mode="copy"/></xsl:copy></xsl:template><xsl:template match="*|@*|comment()|processing-instruction()|text()" mode="copy"><xsl:copy><xsl:apply-templates select="*|@*|comment()|processing-instruction()|text()" mode="copy"/></xsl:copy></xsl:template><xsl:attribute-set name="Titre"><xsl:attribute name="border">1px solid black</xsl:attribute><xsl:attribute name="background-color">#c0c0c0</xsl:attribute><xsl:attribute name="font-weight">bold</xsl:attribute><xsl:attribute name="font-family">Helvetica</xsl:attribute><xsl:attribute name="font-size">14pt</xsl:attribute><xsl:attribute name="padding">.75em 0</xsl:attribute><xsl:attribute name="space-before">12pt</xsl:attribute><xsl:attribute name="space-after">12pt</xsl:attribute><xsl:attribute name="text-align">center</xsl:attribute></xsl:attribute-set><xsl:attribute-set name="Titre14"><xsl:attribute name="border">none</xsl:attribute><xsl:attribute name="background-color">#c0c0c0</xsl:attribute><xsl:attribute name="font-family">Helvetica</xsl:attribute><xsl:attribute name="font-weight">bold</xsl:attribute><xsl:attribute name="font-size">14pt</xsl:attribute><xsl:attribute name="padding">6pt 0</xsl:attribute><xsl:attribute name="text-decoration">underline</xsl:attribute></xsl:attribute-set><xsl:attribute-set name="Titre12"><xsl:attribute name="border">none</xsl:attribute><xsl:attribute name="font-family">Helvetica</xsl:attribute><xsl:attribute name="font-weight">bold</xsl:attribute><xsl:attribute name="font-size">12pt</xsl:attribute><xsl:attribute name="margin">3pt 0</xsl:attribute></xsl:attribute-set><xsl:attribute-set name="Label"><xsl:attribute name="font-family">Helvetica</xsl:attribute><xsl:attribute name="font-weight">bold</xsl:attribute><xsl:attribute name="vertical-align">text-top</xsl:attribute></xsl:attribute-set><xsl:attribute-set name="Label14" use-attribute-sets="Label"><xsl:attribute name="font-size">14pt</xsl:attribute><xsl:attribute name="padding">6pt 2pt</xsl:attribute></xsl:attribute-set><xsl:attribute-set name="Label12" use-attribute-sets="Label"><xsl:attribute name="font-size">12pt</xsl:attribute><xsl:attribute name="padding">3pt 2pt</xsl:attribute></xsl:attribute-set><xsl:attribute-set name="Label10" use-attribute-sets="Label"><xsl:attribute name="font-size">10pt</xsl:attribute><xsl:attribute name="padding">1.5pt 2pt</xsl:attribute></xsl:attribute-set><xsl:attribute-set name="Value"><xsl:attribute name="font-family">Helvetica</xsl:attribute><xsl:attribute name="vertical-align">text-top</xsl:attribute></xsl:attribute-set><xsl:attribute-set name="Value14" use-attribute-sets="Value"><xsl:attribute name="font-size">14pt</xsl:attribute><xsl:attribute name="padding">6pt 2pt</xsl:attribute></xsl:attribute-set><xsl:attribute-set name="Value12" use-attribute-sets="Value"><xsl:attribute name="font-size">12pt</xsl:attribute><xsl:attribute name="padding">3pt 2pt</xsl:attribute></xsl:attribute-set><xsl:attribute-set name="Value10" use-attribute-sets="Value"><xsl:attribute name="font-size">10pt</xsl:attribute><xsl:attribute name="padding">1.5pt 2pt</xsl:attribute></xsl:attribute-set><xsl:attribute-set name="bord"><xsl:attribute name="table-layout">fixed</xsl:attribute><xsl:attribute name="font-family">Helvetica</xsl:attribute><xsl:attribute name="border">1px solid black</xsl:attribute><xsl:attribute name="border-collapse">collapse</xsl:attribute><xsl:attribute name="space-before">12pt</xsl:attribute><xsl:attribute name="space-after">12pt</xsl:attribute></xsl:attribute-set><xsl:attribute-set name="allBord"><xsl:attribute name="table-layout">fixed</xsl:attribute><xsl:attribute name="font-family">Helvetica</xsl:attribute><xsl:attribute name="border">1px solid black</xsl:attribute><xsl:attribute name="border-collapse">collapse</xsl:attribute><xsl:attribute name="space-before">12pt</xsl:attribute><xsl:attribute name="space-after">12pt</xsl:attribute></xsl:attribute-set><xsl:attribute-set name="cell"><xsl:attribute name="language">fr</xsl:attribute><xsl:attribute name="hyphenate">true</xsl:attribute><xsl:attribute name="border">1px solid black</xsl:attribute></xsl:attribute-set><xsl:attribute-set name="cellH" use-attribute-sets="cell"><xsl:attribute name="text-align">center</xsl:attribute><xsl:attribute name="background-color">#c0c0c0</xsl:attribute><xsl:attribute name="font-weight">bold</xsl:attribute></xsl:attribute-set><xsl:attribute-set name="verticaltext"><xsl:attribute name="writing-mode">tb-rl</xsl:attribute><xsl:attribute name="filter">flipv fliph</xsl:attribute></xsl:attribute-set><xsl:attribute-set name="verticaltext2"><xsl:attribute name="block-progression">lr</xsl:attribute><xsl:attribute name="writing-mode">tb-rl</xsl:attribute></xsl:attribute-set>

	<!-- ================== -->
	<!-- = FORMATAGE DATE = -->
	<!-- ================== --><xsl:template name="formatDate"><xsl:param name="date"/><xsl:if test="$date"><xsl:value-of select="substring($date, 9, 2)"/>/<xsl:value-of select="substring($date, 6, 2)"/>/<xsl:value-of select="substring($date, 1, 4)"/></xsl:if></xsl:template>

	<!-- ================================================= -->
	<!-- = LIBELLE DE L'ORIGINE DU CODE D'UN INTERVENANT = -->
	<!-- ================================================= --><xsl:template name="origineCode"><xsl:param name="code"/><xsl:variable name="lib"><xsl:choose><xsl:when test="$code='SIRET'">Sireté</xsl:when><xsl:when test="$code='SANDRE'">Sandré</xsl:when></xsl:choose></xsl:variable><xsl:value-of select="$lib"/></xsl:template>

	<!-- ====================== -->
	<!-- = DEFINITION PUCE 1  = -->
	<!-- ====================== --><xsl:variable name="puce1"><fo:inline font-weight="normal" font-family="ZapfDingbats">➢</fo:inline></xsl:variable>

	<!-- ====================== -->
	<!-- = DEFINITION PUCE 2  = -->
	<!-- ====================== --><xsl:variable name="puce2"><fo:inline font-weight="normal" font-size="1.5em" font-family="ZapfDingbats">❖</fo:inline></xsl:variable>
	<!-- ======================== -->
	<!-- = DEFINITION DES CLES  = -->
	<!-- ======================== -->

	<!-- = CLE sur Intervenant par CdIntervenant  = --><xsl:key name="keyIntervenant" match="LABO_DEST/Intervenant" use="CdIntervenant"/>

	<!-- = CLE sur GroupeParametres par CdGroupeParametres  = -->
	<!--<xsl:key name="keyGroupeParametres" match="COM_LABO/GroupeParametres" use="CdGroupeParametres"/>-->

	<!-- = CLE sur StationPrelevement par CdStationPrelevement  = --><xsl:key name="keyStationPrelevement" match="LABO_DEST/StationPrelevement" use="CdStationPrelevement"/>

	<!-- = YM CLE Valeurs possibles de parametres = --><xsl:key name="keyValeurParametre" match="ref:REFERENTIELS/ref:REFERENTIELS/ref:Referentiel[ref:CdReferentiel='PAR']/ref:Parametre/ref:ValeursPossiblesParametre" use="ref:CdValeursPossiblesParametre"/>


	<!-- = CLE Parametre par code parametre = -->
	<!--<xsl:key name="keyParametre" match="ref:REFERENTIEL/ref:Parametre" use="ref:CdParametre"/>--><xsl:key name="keyParametre" match="ref:REFERENTIELS/ref:REFERENTIELS/ref:Referentiel[ref:CdReferentiel='PAR']/ref:Parametre" use="ref:CdParametre"/>

	<!-- = CLE Methode par code methode  = --><xsl:key name="keyMethode" match="ref:REFERENTIELS/ref:REFERENTIELS/ref:Referentiel[ref:CdReferentiel='MET']/ref:Methode" use="ref:CdMethode"/>

	<!-- = CLE Unite de reference par code = --><xsl:key name="keyUniteReference" match="ref:REFERENTIELS/ref:REFERENTIELS/ref:Referentiel[ref:CdReferentiel='URF']/ref:UniteReference" use="ref:CdUniteReference"/>

	<!-- = CLE Support par code = --><xsl:key name="keySupport" match="ref:REFERENTIELS/ref:REFERENTIELS/ref:Referentiel[ref:CdReferentiel='SUP']/ref:Support" use="ref:CdSupport"/>

	<!-- = CLE FractionAnalysee par code = --><xsl:key name="keyFraction" match="ref:REFERENTIELS/ref:REFERENTIELS/ref:Referentiel[ref:CdReferentiel='FAN']/ref:FractionAnalysee" use="ref:CdFractionAnalysee"/>

	<!-- = CLE Element de la nomenclature 22 (Projection des coordonnées) par code = --><xsl:key name="keyNomenclature22" match="ref:REFERENTIELS/ref:REFERENTIELS/ref:Referentiel[ref:CdReferentiel=22]/ref:Element" use="ref:CdElement"/>

	<!-- = CLE Element de la nomenclature 76 (Système altimétrique de référence)  par code = --><xsl:key name="keyNomenclature76" match="ref:REFERENTIELS/ref:REFERENTIELS/ref:Referentiel[ref:CdReferentiel=76]/ref:Element" use="ref:CdElement"/>

	<!-- = CLE Element de la nomenclature 156 (Type d'analyse) par code = --><xsl:key name="keyNomenclature156" match="ref:REFERENTIELS/ref:REFERENTIELS/ref:Referentiel[ref:CdReferentiel=156]/ref:Element" use="ref:CdElement"/>

	<!-- = CLE Element de la nomenclature 215 (Norme Eau en AEP) par code = --><xsl:key name="keyNomenclature215" match="ref:REFERENTIELS/ref:REFERENTIELS/ref:Referentiel[ref:CdReferentiel=215]/ref:Element" use="ref:CdElement"/>

	<!-- = CLE Element de la nomenclature 216 (Motif de prélèvement AEP) par code = --><xsl:key name="keyNomenclature216" match="ref:REFERENTIELS/ref:REFERENTIELS/ref:Referentiel[ref:CdReferentiel=216]/ref:Element" use="ref:CdElement"/>

	<!-- = CLE Element de la nomenclature 295 (Type de demande) par code = --><xsl:key name="keyNomenclature295" match="ref:REFERENTIELS/ref:REFERENTIELS/ref:Referentiel[ref:CdReferentiel=295]/ref:Element" use="ref:CdElement"/>

	<!-- = CLE Element de la nomenclature 296 (conformite du prélèvement) par code = --><xsl:key name="keyNomenclature296" match="ref:REFERENTIELS/ref:REFERENTIELS/ref:Referentiel[ref:CdReferentiel=296]/ref:Element" use="ref:CdElement"/>

	<!-- = CLE Element de la nomenclature 297 (origine du code d'une station de prelevement) par code = --><xsl:key name="keyNomenclature297" match="ref:REFERENTIELS/ref:REFERENTIELS/ref:Referentiel[ref:CdReferentiel=297]/ref:Element" use="ref:CdElement"/>

	<!-- = CLE Element de la nomenclature 299 (Accreditation de l'analyse) par code = --><xsl:key name="keyNomenclature299" match="ref:REFERENTIELS/ref:REFERENTIELS/ref:Referentiel[ref:CdReferentiel=299]/ref:Element" use="ref:CdElement"/>

	<!-- = CLE Element de la nomenclature 300 (confirmation résultat analyse) par code = --><xsl:key name="keyNomenclature300" match="ref:REFERENTIELS/ref:REFERENTIELS/ref:Referentiel[ref:CdReferentiel=300]/ref:Element" use="ref:CdElement"/>

	<!-- = CLE Element de la nomenclature 325 (Nature du produit) par code = --><xsl:key name="keyNomenclature325" match="ref:REFERENTIELS/ref:REFERENTIELS/ref:Referentiel[ref:CdReferentiel=325]/ref:Element" use="ref:CdElement"/>

	<!-- = CLE Element de la nomenclature 329 (Usage du produit) par code = --><xsl:key name="keyNomenclature329" match="ref:REFERENTIELS/ref:REFERENTIELS/ref:Referentiel[ref:CdReferentiel=329]/ref:Element" use="ref:CdElement"/>

	<!-- = CLE Element de la nomenclature 333 (Accréditation d'un prélèvement) par code = --><xsl:key name="keyNomenclature333" match="ref:REFERENTIELS/ref:REFERENTIELS/ref:Referentiel[ref:CdReferentiel=333]/ref:Element" use="ref:CdElement"/>

	<!-- = CLE Element de la nomenclature 334 (Prélèvement sous réserve) par code = --><xsl:key name="keyNomenclature334" match="ref:REFERENTIELS/ref:REFERENTIELS/ref:Referentiel[ref:CdReferentiel=334]/ref:Element" use="ref:CdElement"/>

	<!-- = CLE Element de la nomenclature 335 (Analyse sous reserve) par code = --><xsl:key name="keyNomenclature335" match="ref:REFERENTIELS/ref:REFERENTIELS/ref:Referentiel[ref:CdReferentiel=335]/ref:Element" use="ref:CdElement"/>

	<!-- = CLE Element de la nomenclature 336 (contexte codification) par code = --><xsl:key name="keyNomenclature336" match="ref:REFERENTIELS/ref:REFERENTIELS/ref:Referentiel[ref:CdReferentiel=336]/ref:Element" use="ref:CdElement"/>

	<!-- = CLE Element de la nomenclature 340 (complétude d'envoi) par code = --><xsl:key name="keyNomenclature340" match="ref:REFERENTIELS/ref:REFERENTIELS/ref:Referentiel[ref:CdReferentiel=340]/ref:Element" use="ref:CdElement"/>


	<!-- ============================================ -->
	<!-- ============================================ -->
	<!-- ============================================ -->
	<!-- ============================================ --><xsl:variable name="codePayeurDemande" select="/LABO_DEST/Demande/Payeur/CdIntervenant"/><xsl:template match="/LABO_DEST" mode="transform"><xsl:variable name="dateC"><xsl:call-template name="formatDate"><xsl:with-param name="date" select="Scenario/DateCreationFichier"/></xsl:call-template></xsl:variable><fo:root><fo:layout-master-set><fo:simple-page-master master-name="portrait" page-width="21cm" page-height="29.7cm" margin-left="1.0cm" margin-top="1.5cm" margin-right="1.0cm" margin-bottom="1.5cm"><fo:region-body/></fo:simple-page-master><fo:simple-page-master master-name="paysage" page-width="29.7cm" page-height="21cm" margin-left="1.0cm" margin-top="1.5cm" margin-right="1.0cm" margin-bottom="1.5cm"><fo:region-body/></fo:simple-page-master></fo:layout-master-set><fo:page-sequence master-reference="portrait"><fo:flow flow-name="xsl-region-body"><fo:block xsl:use-attribute-sets="Titre" width="18cm">BULLETIN D'ANALYSES
						<fo:block/>daté du : <xsl:value-of select="$dateC"/></fo:block><fo:table table-layout="fixed" width="18cm"><fo:table-column column-width="35mm"/><fo:table-column column-width="35mm"/><fo:table-column column-width="35mm"/><fo:table-column column-width="35mm"/><fo:table-body><fo:table-row><fo:table-cell><fo:block><fo:basic-link internal-destination="Caracteristiques"><fo:inline color="blue" text-decoration="underline">Caractéristiques</fo:inline></fo:basic-link></fo:block></fo:table-cell><fo:table-cell><fo:block><fo:basic-link internal-destination="Intervenants"><fo:inline color="blue" text-decoration="underline">Intervenants</fo:inline></fo:basic-link></fo:block></fo:table-cell><fo:table-cell><fo:block><fo:basic-link internal-destination="Stations"><fo:inline color="blue" text-decoration="underline">Stations de prélèvement</fo:inline></fo:basic-link></fo:block></fo:table-cell><fo:table-cell><fo:block><fo:basic-link internal-destination="Prestations"><fo:inline color="blue" text-decoration="underline">Détails des prestations</fo:inline></fo:basic-link></fo:block></fo:table-cell></fo:table-row></fo:table-body></fo:table><xsl:apply-templates select="Demande"/><xsl:call-template name="Intervenants"/><xsl:call-template name="Stations"/></fo:flow></fo:page-sequence><fo:page-sequence master-reference="paysage"><fo:flow flow-name="xsl-region-body"><xsl:call-template name="Recapitulatif"/><xsl:call-template name="Prelevements"/></fo:flow></fo:page-sequence></fo:root></xsl:template>

	<!-- ========================== -->
	<!-- = DETAILS DE LA DEMANDE  = -->
	<!-- ========================== --><xsl:template match="Demande"><fo:table xsl:use-attribute-sets="bord"><fo:table-column column-width="5mm"/><fo:table-column column-width="35mm"/><fo:table-column column-width="60mm"/><fo:table-column column-width="25mm"/><fo:table-column column-width="65mm"/><fo:table-body><fo:table-row><fo:table-cell xsl:use-attribute-sets="Titre14" number-columns-spanned="5"><fo:block><fo:inline id="Caracteristiques">CARACTERISTIQUES DE LA DEMANDE DE PRESTATIONS</fo:inline></fo:block></fo:table-cell></fo:table-row><fo:table-row><fo:table-cell xsl:use-attribute-sets="Value14"><fo:block><xsl:copy-of select="$puce1"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Label14" number-columns-spanned="2"><fo:block><fo:basic-link external-destination="url(http://www.sandre.eaufrance.fr/?urn=urn:sandre:dictionnaire:LAB::attribut:CdDemandeCommanditaire:ressource:1:::html)">Numéro de la demande :</fo:basic-link></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value14" number-columns-spanned="2"><fo:block><xsl:value-of select="CdDemandeCommanditaire"/></fo:block></fo:table-cell></fo:table-row><xsl:variable name="intC" select="key('keyIntervenant', Commanditaire/CdIntervenant)"/><fo:table-row><fo:table-cell xsl:use-attribute-sets="Value14"><fo:block><xsl:copy-of select="$puce1"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Label14"><fo:block><fo:basic-link external-destination="url(http://www.sandre.eaufrance.fr/?urn=urn:sandre:dictionnaire:INT::attribut:CdIntervenant:ressource:1:::html)">Commanditaire :</fo:basic-link></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value14"><fo:block><xsl:value-of select="$intC/NomIntervenant"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Label14"><fo:block><fo:basic-link external-destination="url(http://www.sandre.eaufrance.fr/?urn=urn:sandre:dictionnaire:INT::attribut:CdIntervenant:ressource:1:::html)"><xsl:call-template name="origineCode"><xsl:with-param name="code" select="Commanditaire/CdIntervenant/@schemeAgencyID"/></xsl:call-template></fo:basic-link></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value14"><fo:block><xsl:value-of select="Commanditaire/CdIntervenant"/></fo:block></fo:table-cell></fo:table-row><fo:table-row><fo:table-cell number-columns-spanned="3" xsl:use-attribute-sets="Label14"><fo:block><fo:basic-link external-destination="url(http://www.sandre.eaufrance.fr/?urn=urn:sandre:dictionnaire:LAB::attribut:NomService:ressource:1:::html)">Service :</fo:basic-link></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value14"><fo:block><xsl:value-of select="Commanditaire/Service/NomService"/></fo:block></fo:table-cell></fo:table-row><fo:table-row><fo:table-cell number-columns-spanned="3" xsl:use-attribute-sets="Label14"><fo:block><fo:basic-link external-destination="url(http://www.sandre.eaufrance.fr/?urn=urn:sandre:dictionnaire:LAB::attribut:NomContact:ressource:1:::html)">Contact :</fo:basic-link></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value14"><fo:block><xsl:value-of select="Commanditaire/Contact/NomContact"/></fo:block></fo:table-cell></fo:table-row><xsl:variable name="intP" select="key('keyIntervenant', Prestataire/CdIntervenant)"/><fo:table-row><fo:table-cell xsl:use-attribute-sets="Value14"><fo:block><xsl:copy-of select="$puce1"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Label14"><fo:block><fo:basic-link external-destination="url(http://www.sandre.eaufrance.fr/?urn=urn:sandre:dictionnaire:INT::attribut:CdIntervenant:ressource:1:::html)">Prestataire :</fo:basic-link></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value14"><fo:block><xsl:value-of select="$intP/NomIntervenant"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Label14"><fo:block><fo:basic-link external-destination="url(http://www.sandre.eaufrance.fr/?urn=urn:sandre:dictionnaire:INT::attribut:CdIntervenant:ressource:1:::html)"><xsl:call-template name="origineCode"><xsl:with-param name="code" select="Prestataire/CdIntervenant/@schemeAgencyID"/></xsl:call-template></fo:basic-link></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value14"><fo:block><xsl:value-of select="Prestataire/CdIntervenant"/></fo:block></fo:table-cell></fo:table-row><fo:table-row><fo:table-cell xsl:use-attribute-sets="Label14" number-columns-spanned="3"><fo:block><fo:basic-link external-destination="url(http://www.sandre.eaufrance.fr/?urn=urn:sandre:dictionnaire:LAB::attribut:NomService:ressource:1:::html)">Service :</fo:basic-link></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value14"><fo:block><xsl:value-of select="Prestataire/Service/NomService"/></fo:block></fo:table-cell></fo:table-row><fo:table-row><fo:table-cell xsl:use-attribute-sets="Label14" number-columns-spanned="3"><fo:block><fo:basic-link external-destination="url(http://www.sandre.eaufrance.fr/?urn=urn:sandre:dictionnaire:LAB::attribut:NomContact:ressource:1:::html)">Contact :</fo:basic-link></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value14"><fo:block><xsl:value-of select="Prestataire/Contact/NomContact"/></fo:block></fo:table-cell></fo:table-row><fo:table-row><fo:table-cell xsl:use-attribute-sets="Value14"><fo:block><xsl:copy-of select="$puce1"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Label14" number-columns-spanned="2"><fo:block><fo:basic-link external-destination="url(http://www.sandre.eaufrance.fr/?urn=urn:sandre:dictionnaire:LAB::attribut:TypeDemande:ressource:1:::html)">Type de demande :</fo:basic-link></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value14" number-columns-spanned="2"><fo:block><xsl:value-of select="key('keyNomenclature295', TypeDemande)/ref:LbElement"/></fo:block></fo:table-cell></fo:table-row><fo:table-row><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:copy-of select="$puce1"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Label10" number-columns-spanned="2"><fo:block>Contexte d'échange :</fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value10" number-columns-spanned="2"><fo:block><xsl:value-of select="key('keyNomenclature336', ContexteCodification)/ref:LbElement"/></fo:block></fo:table-cell></fo:table-row><fo:table-row><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:copy-of select="$puce1"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Label10" number-columns-spanned="2"><fo:block><fo:basic-link external-destination="url(http://www.sandre.eaufrance.fr/?urn=urn:sandre:dictionnaire:LAB::attribut:CdDemandePrestataire:ressource:1:::html)">Référence de la demande chez le prestataire :</fo:basic-link></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value10" number-columns-spanned="2"><fo:block><xsl:value-of select="CdDemandePrestataire"/></fo:block></fo:table-cell></fo:table-row><fo:table-row><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:copy-of select="$puce1"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Label10" number-columns-spanned="2"><fo:block><fo:basic-link external-destination="url(http://www.sandre.eaufrance.fr/?urn=urn:sandre:dictionnaire:LAB::attribut:LbDemande:ressource:1:::html)">Objet de la demande :</fo:basic-link></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value10" number-columns-spanned="2"><fo:block><xsl:value-of select="LbDemande"/></fo:block></fo:table-cell></fo:table-row><fo:table-row><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:copy-of select="$puce1"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Label10" number-columns-spanned="2"><fo:block>Dates d'application de la demande :</fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value10" number-columns-spanned="2"><fo:block><xsl:if test="DateDebutApplicationDemande">du
								<xsl:call-template name="formatDate"><xsl:with-param name="date" select="DateDebutApplicationDemande"/></xsl:call-template></xsl:if><xsl:if test="DateFinApplicationDemande">au
								<xsl:call-template name="formatDate"><xsl:with-param name="date" select="DateFinApplicationDemande"/></xsl:call-template></xsl:if></fo:block></fo:table-cell></fo:table-row><fo:table-row><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:copy-of select="$puce1"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Label10" number-columns-spanned="2"><fo:block><fo:basic-link external-destination="url(http://www.sandre.eaufrance.fr/?urn=urn:sandre:dictionnaire:LAB::attribut:ReferenceMarche:ressource:1:::html)">Référence du marché :</fo:basic-link></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value10" number-columns-spanned="2"><fo:block><xsl:value-of select="ReferenceMarche"/></fo:block></fo:table-cell></fo:table-row><fo:table-row><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:copy-of select="$puce1"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Label10" number-columns-spanned="2"><fo:block><fo:basic-link external-destination="url(http://www.sandre.eaufrance.fr/?urn=urn:sandre:dictionnaire:LAB::attribut:CommentairesCommanditaire:ressource:1:::html)">Commentaires :</fo:basic-link></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value10" number-columns-spanned="2"><fo:block><xsl:value-of select="CommentairesCommanditaire"/></fo:block></fo:table-cell></fo:table-row></fo:table-body></fo:table></xsl:template>

	<!-- ========================== -->
	<!-- = LISTE DES INTERVENANTS  = -->
	<!-- ========================== --><xsl:template name="Intervenants"><fo:table xsl:use-attribute-sets="allBord"><fo:table-column column-width="45mm"/><fo:table-column column-width="75mm"/><fo:table-column column-width="60mm"/><fo:table-body><fo:table-row><fo:table-cell xsl:use-attribute-sets="Titre14" number-columns-spanned="3"><fo:block id="Intervenants">LISTE DES INTERVENANTS MIS EN JEU ET ROLES ASSOCIES</fo:block></fo:table-cell></fo:table-row><fo:table-row><fo:table-cell xsl:use-attribute-sets="cellH"><fo:block>Code</fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="cellH"><fo:block>Nom</fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="cellH"><fo:block>Rôles</fo:block></fo:table-cell></fo:table-row><xsl:for-each select="Intervenant"><fo:table-row><fo:table-cell xsl:use-attribute-sets="cell Value10"><fo:block><xsl:value-of select="CdIntervenant"/>(<xsl:value-of select="CdIntervenant/@schemeAgencyID"/>)</fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="cell Value10"><fo:block><xsl:value-of select="NomIntervenant"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="cell Value10"><fo:block><xsl:if test="CdIntervenant = ../Demande/Commanditaire/CdIntervenant">
                                - Commanditaire de la demande
                            </xsl:if><xsl:if test="CdIntervenant = ../Demande/Prestataire/CdIntervenant">
                                - Prestataire de la demande
                            </xsl:if><xsl:if test="CdIntervenant = ../Demande/DestinataireRsAna/CdIntervenant">
                                - Destinataire des résultats
                            </xsl:if><xsl:if test="CdIntervenant = ../Demande/Payeur/CdIntervenant">
                                - Payeur des prestations
                            </xsl:if><xsl:if test="CdIntervenant = ../Demande/Prelevement/Payeur/CdIntervenant">
                                - Payeur d'un ou plusieurs prélèvements
                            </xsl:if><xsl:if test="CdIntervenant = ../Demande/Prelevement/Echantillon/Payeur/CdIntervenant">
                                - Payeur d'une ou plusieurs analyses
                            </xsl:if><xsl:if test="CdIntervenant = ../Demande/Prelevement/Echantillon/Laboratoire/Analyse/Payeur/CdIntervenant">
                                - Payeur d'une analyse bien particulière
                            </xsl:if><xsl:if test="CdIntervenant = ../Demande/Prelevement/Preleveur/CdIntervenant">
                                - Préleveur
                            </xsl:if><xsl:if test="CdIntervenant = ../Demande/Prelevement/Echantillon/Laboratoire/CdIntervenant">
                                - Laboratoire
                            </xsl:if></fo:block></fo:table-cell></fo:table-row></xsl:for-each></fo:table-body></fo:table></xsl:template>


	<!-- ===================================== -->
	<!-- = LISTE DES STATIONS DE PRELEVEMENT = -->
	<!-- ===================================== --><xsl:template name="Stations"><fo:table xsl:use-attribute-sets="bord" break-before="page"><fo:table-column column-width="5mm"/><fo:table-column column-width="65mm"/><fo:table-column column-width="120mm"/><fo:table-body><fo:table-row><fo:table-cell xsl:use-attribute-sets="Titre14" number-columns-spanned="3"><fo:block id="Stations">CARACTERISTIQUES DES STATIONS DE PRELEVEMENTS</fo:block></fo:table-cell></fo:table-row><xsl:apply-templates select="StationPrelevement"/></fo:table-body></fo:table></xsl:template>

	<!-- ======================================== -->
	<!-- = DETAILS D'UNE STATION DE PRELEVEMENT = -->
	<!-- ======================================== --><xsl:template match="StationPrelevement"><fo:table-row><fo:table-cell xsl:use-attribute-sets="Value12"><fo:block><xsl:copy-of select="$puce2"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Label12" number-columns-spanned="2"><fo:block><xsl:value-of select="LbStationPrelevement"/></fo:block></fo:table-cell></fo:table-row><fo:table-row><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:copy-of select="$puce1"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Label10"><fo:block>Code :</fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:value-of select="CdStationPrelevement"/>(<xsl:value-of select="key('keyNomenclature297', CdStationPrelevement/@schemeAgencyID)/ref:LbElement"/>)</fo:block></fo:table-cell></fo:table-row><fo:table-row><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:copy-of select="$puce1"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Label10"><fo:block>Adresse :</fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:value-of select="AdresseStationPrelevement"/></fo:block></fo:table-cell></fo:table-row><fo:table-row><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:copy-of select="$puce1"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Label10"><fo:block>Coordonnées géographiques :</fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:if test="CoordXStationPrelevement">X=<xsl:value-of select="CoordXStationPrelevement"/> / Y=<xsl:value-of select="CoordXStationPrelevement"/>
			    (<xsl:value-of select="key('keyNomenclature22', ProjectStationPrelevement)/ref:LbElement"/>)</xsl:if></fo:block></fo:table-cell></fo:table-row><fo:table-row><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:copy-of select="$puce1"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Label10"><fo:block>Altitude :</fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:if test="AltitudeStationPrelevement">Z=<xsl:value-of select="AltitudeStationPrelevement"/> mètres
				(<xsl:value-of select="key('keyNomenclature76', ProjectAltiStationPrelevement)/ref:LbElement"/>)</xsl:if></fo:block></fo:table-cell></fo:table-row><fo:table-row><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:copy-of select="$puce1"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Label10"><fo:block>Commune :</fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:value-of select="Commune/LbCommune"/>(<xsl:value-of select="Commune/CdCommune"/>)</fo:block></fo:table-cell></fo:table-row><xsl:if test="LocalPrelevement"><fo:table-row><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:copy-of select="$puce1"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Label10" number-columns-spanned="2"><fo:block>Liste des localisations de prélèvements pour cette station :</fo:block></fo:table-cell></fo:table-row><fo:table-row><fo:table-cell number-columns-spanned="3" padding="2pt"><xsl:call-template name="LocalisationsStation"/></fo:table-cell></fo:table-row></xsl:if></xsl:template>

	<!-- ======================================================== -->
	<!-- = LISTE DES LOCALISATIONS D'UNE STATION DE PRELEVEMENT = -->
	<!-- ======================================================== --><xsl:template name="LocalisationsStation"><fo:table xsl:use-attribute-sets="allBord"><fo:table-column column-width="37mm"/><fo:table-column column-width="22mm"/><fo:table-column column-width="17mm"/><fo:table-column column-width="42mm"/><fo:table-column column-width="35mm"/><fo:table-column column-width="29mm"/><fo:table-header><fo:table-row><fo:table-cell xsl:use-attribute-sets="cellH"><fo:block>Code<fo:block/>(Origine du code)</fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="cellH"><fo:block>Libellé</fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="cellH"><fo:block>Type</fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="cellH"><fo:block>Coordonnées géographique</fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="cellH"><fo:block>Altitudes minimales / maximales</fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="cellH"><fo:block>Commune<fo:block/>(Code INSEE)</fo:block></fo:table-cell></fo:table-row></fo:table-header><fo:table-body><xsl:apply-templates select="LocalPrelevement"/></fo:table-body></fo:table></xsl:template>

	<!-- =========================================================== -->
	<!-- = DETAILS D'UNE LOCALISATION D'UNE STATION DE PRELEVEMENT = -->
	<!-- =========================================================== --><xsl:template match="LocalPrelevement"><fo:table-row><fo:table-cell xsl:use-attribute-sets="cell Value10"><fo:block><fo:inline font-weight="bold"><xsl:value-of select="CdLocalPrelevement"/></fo:inline><fo:block/>(<xsl:value-of select="key('keyNomenclature297', CdLocalPrelevement/@schemeAgencyID)/ref:LbElement"/>)</fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="cell Value10"><fo:block><xsl:value-of select="LbLocalPrelevement"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="cell Value10"><fo:block><xsl:value-of select="TypeLocalPrelevement"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="cell Value10"><fo:block><xsl:if test="CoordXLocalPrelevement">X=<xsl:value-of select="CoordXLocalPrelevement"/><fo:block/>Y=<xsl:value-of select="CoordYLocalPrelevement"/><fo:block/>(<xsl:value-of select="key('keyNomenclature22', ProjLocalPrelevement)/ref:LbElement"/>)</xsl:if></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="cell Value10"><fo:block><xsl:if test="AltMinLocalPrelevement">min=<xsl:value-of select="AltMinLocalPrelevement"/><fo:block/>max=<xsl:value-of select="AltMaxLocalPrelevement"/>
				(<xsl:value-of select="key('keyNomenclature76', ProjAltiLocalPrelevement)/ref:LbElement"/>)</xsl:if></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="cell Value10"><fo:block><xsl:value-of select="Commune/LbCommune"/><fo:block/>(<xsl:value-of select="Commune/CdCommune"/>)</fo:block></fo:table-cell></fo:table-row></xsl:template>

	<!-- ================================== -->
	<!-- = RECAPITULATIF DES PRELEVEMENTS = -->
	<!-- ================================== --><xsl:template name="Recapitulatif"><fo:block id="Prestations" xsl:use-attribute-sets="Titre14" width="18cm">DETAILS DES PRESTATIONS</fo:block><xsl:apply-templates select="Demande" mode="recap"/></xsl:template>

	<!-- = CLE Tous les prélévements pour un code de StationPrelevement  = --><xsl:key name="keyPrelevementParStation" match="LABO_DEST/Demande/Prelevement" use="StationPrelevement/CdStationPrelevement"/>

	<!-- = CLE PRELEVEMENT PAR code LocalPrelevement = --><xsl:key name="keyPrelevementParLocal" match="LABO_DEST/Demande/Prelevement" use="concat(StationPrelevement/CdStationPrelevement, '::', LocalPrelevement/CdLocalPrelevement)"/><xsl:key name="keyEchantillonPrelParLaboratoire" match="LABO_DEST/Demande/Prelevement/Echantillon" use="concat(generate-id(..), '::', Laboratoire/CdIntervenant)"/><xsl:template match="Demande" mode="recap"><fo:block xsl:use-attribute-sets="Titre12"><xsl:copy-of select="$puce2"/> Tableau récapitulatif des prélèvements</fo:block><fo:table xsl:use-attribute-sets="allBord"><fo:table-column column-width="25mm"/><fo:table-column column-width="25mm"/><fo:table-column column-width="30mm"/><fo:table-column column-width="20mm"/><fo:table-column column-width="55mm"/><fo:table-column column-width="25mm"/><fo:table-column column-width="35mm"/><fo:table-column column-width="60mm"/><fo:table-header><fo:table-row><fo:table-cell xsl:use-attribute-sets="cellH Value10"><fo:block>Code Station de prélèvement</fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="cellH Value10"><fo:block>Code Localisation de prélèvement</fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="cellH Value10"><fo:block>Localisation exacte</fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="cellH Value10"><fo:block>Support prélevé</fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="cellH Value10"><fo:block>Code du prélèvement</fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="cellH Value10"><fo:block>Date, heure, durée du prélèvement réalisé</fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="cellH Value10"><fo:block>Préleveur</fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="cellH Value10"><fo:block>Echantillon(s) par prélèvement et destinataires</fo:block></fo:table-cell></fo:table-row></fo:table-header><fo:table-body><xsl:for-each select="Prelevement[generate-id() = generate-id(key('keyPrelevementParLocal', concat(StationPrelevement/CdStationPrelevement, '::', LocalPrelevement/CdLocalPrelevement))[1])]"><xsl:variable name="codeStation" select="StationPrelevement/CdStationPrelevement"/><xsl:variable name="codeLocal" select="LocalPrelevement/CdLocalPrelevement"/><xsl:variable name="prelevementsS" select="key('keyPrelevementParStation', $codeStation)"/><xsl:variable name="prelevementsGrpL" select="key('keyPrelevementParLocal', concat($codeStation, '::', $codeLocal))"/><xsl:for-each select="$prelevementsGrpL"><xsl:variable name="prelCourant" select="."/><xsl:variable name="idP" select="generate-id()"/><fo:table-row><xsl:if test="generate-id() = generate-id($prelevementsS[1])"><fo:table-cell xsl:use-attribute-sets="cell Label10" number-rows-spanned="{count($prelevementsS)}"><fo:block><xsl:value-of select="$codeStation"/></fo:block></fo:table-cell></xsl:if><xsl:if test="position() = 1"><fo:table-cell xsl:use-attribute-sets="cell Label10" number-rows-spanned="{count($prelevementsGrpL)}"><fo:block><xsl:value-of select="$codeLocal"/></fo:block></fo:table-cell></xsl:if><fo:table-cell xsl:use-attribute-sets="cell Value10"><fo:block><xsl:value-of select="LocalExactePrel"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="cell Value10"><fo:block><xsl:value-of select="key('keySupport', Support/CdSupport)/ref:LbSupport"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="cell Value10"><fo:block><xsl:value-of select="CdPrelevement"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="cell Value10"><fo:block><xsl:call-template name="formatDate"><xsl:with-param name="date" select="DatePrel"/></xsl:call-template><fo:block/><xsl:value-of select="HeurePrel"/><fo:block/><xsl:value-of select="DureePrel"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="cell Value10"><fo:block><xsl:value-of select="key('keyIntervenant', Preleveur/CdIntervenant)/NomIntervenant"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="cell Value10"><fo:block><xsl:for-each select="Echantillon[generate-id() = generate-id(key('keyEchantillonPrelParLaboratoire', concat($idP, '::', Laboratoire/CdIntervenant))[1])]"><xsl:variable name="codeLabo" select="Laboratoire/CdIntervenant"/><fo:block><xsl:value-of select="count(key('keyEchantillonPrelParLaboratoire', concat($idP, '::', $codeLabo)))"/>pour <xsl:value-of select="key('keyIntervenant', $codeLabo)/NomIntervenant"/></fo:block></xsl:for-each></fo:block></fo:table-cell></fo:table-row></xsl:for-each></xsl:for-each></fo:table-body></fo:table></xsl:template>

	<!-- ========================== -->
	<!-- = LISTE DES PRELEVEMENTS = -->
	<!-- ========================== --><xsl:template name="Prelevements"><xsl:apply-templates select="Demande/Prelevement"/></xsl:template>

	<!-- =========================== -->
	<!-- = DETAIL D'UN PRELEVEMENT = -->
	<!-- =========================== --><xsl:template match="Prelevement"><fo:table xsl:use-attribute-sets="bord"><fo:table-column column-width="5mm"/><fo:table-column column-width="120mm"/><fo:table-column column-width="145mm"/><fo:table-body><fo:table-row><fo:table-cell xsl:use-attribute-sets="Label12"><fo:block><xsl:copy-of select="$puce2"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Label12" number-columns-spanned="2"><fo:block>Caractéristiques du <fo:basic-link external-destination="url(http://www.sandre.eaufrance.fr/?urn=urn:sandre:dictionnaire:LAB::entite:Prelevement:ressource:1:::html)">prélèvement</fo:basic-link><xsl:value-of select="CdPrelevement"/></fo:block></fo:table-cell></fo:table-row><xsl:variable name="codePreleveur" select="Preleveur/CdIntervenant"/><fo:table-row><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:copy-of select="$puce1"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Label10"><fo:block><fo:basic-link external-destination="url(http://www.sandre.eaufrance.fr/?urn=urn:sandre:dictionnaire:INT::attribut:CdIntervenant:ressource:1:::html)">Préleveur :</fo:basic-link></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:value-of select="key('keyIntervenant', $codePreleveur)/NomIntervenant"/>(<xsl:call-template name="origineCode"><xsl:with-param name="code" select="$codePreleveur/@schemeAgencyID"/></xsl:call-template> : <xsl:value-of select="$codePreleveur"/>),
							<xsl:value-of select="Preleveur/Service/NomService"/>,
							<xsl:value-of select="Preleveur/Contact/NomContact"/></fo:block></fo:table-cell></fo:table-row><xsl:variable name="codePayeur" select="Payeur/CdIntervenant"/><xsl:if test="$codePayeur != $codePayeurDemande"><fo:table-row><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:copy-of select="$puce1"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Label10"><fo:block>Payeur du prélèvement :</fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:value-of select="key('keyIntervenant', $codePayeur)/NomIntervenant"/>(<xsl:call-template name="origineCode"><xsl:with-param name="code" select="$codePayeur/@schemeAgencyID"/></xsl:call-template> : <xsl:value-of select="$codePayeur"/>),
								<xsl:value-of select="Payeur/Service/NomService"/>,
								<xsl:value-of select="Payeur/Contact/NomContact"/></fo:block></fo:table-cell></fo:table-row></xsl:if><xsl:variable name="codeStation" select="StationPrelevement/CdStationPrelevement"/><xsl:variable name="station" select="key('keyStationPrelevement', $codeStation)"/><fo:table-row><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:copy-of select="$puce1"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Label10"><fo:block><fo:basic-link external-destination="url(http://www.sandre.eaufrance.fr/?urn=urn:sandre:dictionnaire:LAB::entite:StationPrelevement:ressource:1:::html)">Station de prélèvement :</fo:basic-link></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:value-of select="$station/LbStationPrelevement"/>(<xsl:value-of select="$codeStation"/>)</fo:block></fo:table-cell></fo:table-row><xsl:variable name="codeLocal" select="LocalPrelevement/CdLocalPrelevement"/><xsl:variable name="local" select="$station/LocalPrelevement[CdLocalPrelevement=$codeLocal]"/><fo:table-row><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:copy-of select="$puce1"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Label10"><fo:block><fo:basic-link external-destination="url(http://www.sandre.eaufrance.fr/?urn=urn:sandre:dictionnaire:LAB::entite:LocalPrelevement:ressource:1:::html)">Localisation du prélèvement :</fo:basic-link></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:value-of select="$local/LbLocalPrelevement"/>(<xsl:value-of select="$codeLocal"/>)</fo:block></fo:table-cell></fo:table-row><fo:table-row><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:copy-of select="$puce1"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Label10"><fo:block><fo:basic-link external-destination="url(http://www.sandre.eaufrance.fr/?urn=urn:sandre:dictionnaire:LAB::attribut:LocalExactePrel:ressource:1:::html)">Localisation exacte du prélèvement :</fo:basic-link></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:value-of select="LocalExactePrel"/></fo:block></fo:table-cell></fo:table-row><fo:table-row><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:copy-of select="$puce1"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Label10"><fo:block><fo:basic-link external-destination="url(http://www.sandre.eaufrance.fr/?urn=urn:sandre:dictionnaire:LAB::attribut:DatePrel:ressource:1:::html)">Date du prélèvement :</fo:basic-link></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:value-of select="DatePrel"/></fo:block></fo:table-cell></fo:table-row><fo:table-row><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:copy-of select="$puce1"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Label10"><fo:block>Durée du prélèvement :</fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:value-of select="DureePrel"/></fo:block></fo:table-cell></fo:table-row><xsl:variable name="codeSupport" select="Support/CdSupport"/><fo:table-row><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:copy-of select="$puce1"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Label10"><fo:block><fo:basic-link external-destination="url(http://www.sandre.eaufrance.fr/?urn=urn:sandre:dictionnaire:PAR::entite:Support:ressource:latest:::html)">Support prélevé :</fo:basic-link></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:value-of select="key('keySupport', $codeSupport)/ref:LbSupport"/>(<xsl:value-of select="$codeSupport"/>)</fo:block></fo:table-cell></fo:table-row><xsl:variable name="codeNature" select="NatureProduit"/><fo:table-row><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:copy-of select="$puce1"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Label10"><fo:block><fo:basic-link external-destination="url(http://www.sandre.eaufrance.fr/?urn=urn:sandre:dictionnaire:LAB::attribut:NatureProduit:ressource:1:::html)">Nature du produit de prélèvement :</fo:basic-link></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:if test="NatureProduit"><xsl:value-of select="key('keyNomenclature325', $codeNature)/ref:LbElement"/>(<xsl:value-of select="$codeNature"/>)</xsl:if></fo:block></fo:table-cell></fo:table-row><xsl:variable name="codeUsage" select="UsageProduit"/><fo:table-row><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:copy-of select="$puce1"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Label10"><fo:block><fo:basic-link external-destination="url(http://www.sandre.eaufrance.fr/?urn=urn:sandre:dictionnaire:LAB::attribut:UsageProduit:ressource:1:::html)">Usage du produit de prélèvement :</fo:basic-link></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:if test="UsageProduit"><xsl:value-of select="key('keyNomenclature329', $codeUsage)/ref:LbElement"/>(<xsl:value-of select="$codeUsage"/>)</xsl:if></fo:block></fo:table-cell></fo:table-row><fo:table-row><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:copy-of select="$puce1"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Label10"><fo:block><fo:basic-link external-destination="url(http://www.sandre.eaufrance.fr/?urn=urn:sandre:dictionnaire:LAB::attribut:RisqueProduit:ressource:1:::html)">Risque du produit de prélèvement :</fo:basic-link></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:value-of select="RisqueProduit"/></fo:block></fo:table-cell></fo:table-row><fo:table-row><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:copy-of select="$puce1"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Label10"><fo:block><fo:basic-link external-destination="url(http://www.sandre.eaufrance.fr/?urn=urn:sandre:dictionnaire:LAB::attribut:FinalitePrel:ressource:1:::html)">Finalité du prélèvement :</fo:basic-link></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:if test="FinalitePrel"><xsl:value-of select="key('keyNomenclature216', FinalitePrel)/ref:LbElement"/>(<xsl:value-of select="FinalitePrel"/>)</xsl:if></fo:block></fo:table-cell></fo:table-row><fo:table-row><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:copy-of select="$puce1"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Label10"><fo:block><fo:basic-link external-destination="url(http://www.sandre.eaufrance.fr/?urn=urn:sandre:dictionnaire:LAB::attribut:NormeProduit:ressource:1:::html)">Norme appliquée au produit de prélèvement :</fo:basic-link></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:if test="NormeProduit"><xsl:value-of select="key('keyNomenclature215', NormeProduit)/ref:LbElement"/>(<xsl:value-of select="NormeProduit"/>)</xsl:if></fo:block></fo:table-cell></fo:table-row><xsl:if test="MesureEnvironnementale"><fo:table-row><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:copy-of select="$puce1"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Label12" number-columns-spanned="2"><fo:block><fo:basic-link external-destination="url(http://www.sandre.eaufrance.fr/?urn=urn:sandre:dictionnaire:LAB::entite:MesureEnvironnementale:ressource:1:::html)">Mesure(s) environnementale(s) associée(s)</fo:basic-link></fo:block></fo:table-cell></fo:table-row><fo:table-row><fo:table-cell number-columns-spanned="2"><fo:table xsl:use-attribute-sets="allBord" margin-left="10mm"><fo:table-column column-width="80mm"/><fo:table-column column-width="70mm"/><fo:table-column column-width="80mm"/><fo:table-header><fo:table-row><fo:table-cell xsl:use-attribute-sets="cellH"><fo:block>Paramètre<fo:block/>nom (code)</fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="cellH"><fo:block>Méthode de mesure<fo:block/>nom (code)</fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="cellH"><fo:block>Résultat (code unité)</fo:block></fo:table-cell></fo:table-row></fo:table-header><fo:table-body><xsl:apply-templates select="MesureEnvironnementale"/></fo:table-body></fo:table></fo:table-cell></fo:table-row></xsl:if><fo:table-row><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:copy-of select="$puce1"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Label12" number-columns-spanned="2"><fo:block>Qualification du prélèvement</fo:block></fo:table-cell></fo:table-row><fo:table-row><fo:table-cell number-columns-spanned="2"><fo:table table-layout="fixed" margin-left="10mm"><fo:table-column column-width="75mm"/><fo:table-column column-width="85mm"/><fo:table-body><fo:table-row><fo:table-cell xsl:use-attribute-sets="Label10"><fo:block><fo:basic-link external-destination="url(http://www.sandre.eaufrance.fr/?urn=urn:sandre:dictionnaire:LAB::attribut:AccredPrel:ressource:1:::html)">Accréditation du prélèvement :</fo:basic-link></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:value-of select="key('keyNomenclature333', AccredPrel)/ref:LbElement"/></fo:block></fo:table-cell></fo:table-row><fo:table-row><fo:table-cell xsl:use-attribute-sets="Label10"><fo:block><fo:basic-link external-destination="url(http://www.sandre.eaufrance.fr/?urn=urn:sandre:dictionnaire:LAB::attribut:ConformitePrel:ressource:1:::html)">Conformité du prélèvement :</fo:basic-link></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:value-of select="key('keyNomenclature296', ConformitePrel)/ref:LbElement"/></fo:block></fo:table-cell></fo:table-row><fo:table-row><fo:table-cell xsl:use-attribute-sets="Label10"><fo:block><fo:basic-link external-destination="url(http://www.sandre.eaufrance.fr/?urn=urn:sandre:dictionnaire:LAB::attribut:PrelSousReserve:ressource:1:::html)">Prélèvement sous réserve :</fo:basic-link></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:value-of select="key('keyNomenclature334', PrelSousReserve)/ref:LbElement"/></fo:block></fo:table-cell></fo:table-row></fo:table-body></fo:table></fo:table-cell></fo:table-row></fo:table-body></fo:table><xsl:apply-templates select="Echantillon"/></xsl:template>

	<!-- ========================================================= -->
	<!-- = DETAIL D'UNE MESURE ENVIRONNEMENTALE D'UN PRELEVEMENT = -->
	<!-- ========================================================= --><xsl:template match="MesureEnvironnementale"><fo:table-row><fo:table-cell xsl:use-attribute-sets="cell Value10"><fo:block><xsl:value-of select="key('keyParametre', Parametre/CdParametre)/ref:NomParametre"/>(<xsl:value-of select="Parametre/CdParametre"/>)</fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="cell Value10"><fo:block><xsl:value-of select="key('keyMethode', Methode/CdMethode)/ref:LbLongMethode"/>(<xsl:value-of select="Methode/CdMethode"/>)</fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="cell Value10"><fo:block><xsl:value-of select="RsParEnv"/><xsl:text> </xsl:text><xsl:value-of select="key('keyUniteReference', UniteReference/CdUniteReference)/ref:SymUniteReference"/>(<xsl:value-of select="UniteReference/CdUniteReference"/>)</fo:block></fo:table-cell></fo:table-row></xsl:template>

	<!-- =========================== -->
	<!-- = DETAIL D'UN ECHANTILLON = -->
	<!-- =========================== --><xsl:template match="Echantillon"><fo:table table-layout="fixed"><fo:table-column column-width="5mm"/><fo:table-column column-width="90mm"/><fo:table-column column-width="85mm"/><fo:table-body><xsl:if test="position() = 1"><fo:table-row><fo:table-cell xsl:use-attribute-sets="Label12"><fo:block><xsl:copy-of select="$puce2"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Label12" number-columns-spanned="2"><fo:block><fo:basic-link external-destination="url(http://www.sandre.eaufrance.fr/?urn=urn:sandre:dictionnaire:LAB::entite:Echantillon:ressource:1:::html)">Echantillon(s)</fo:basic-link> du prélèvement <xsl:value-of select="CdPrelevement"/></fo:block></fo:table-cell></fo:table-row></xsl:if><xsl:variable name="codeDest" select="Laboratoire/CdIntervenant"/><fo:table-row><fo:table-cell xsl:use-attribute-sets="Label12" number-columns-spanned="3"><fo:block>1 <fo:basic-link external-destination="url(http://www.sandre.eaufrance.fr/?urn=urn:sandre:dictionnaire:LAB::entite:Echantillon:ressource:1:::html)">échantillon</fo:basic-link> pour :
							<xsl:value-of select="key('keyIntervenant', $codeDest)/NomIntervenant"/>(<xsl:call-template name="origineCode"><xsl:with-param name="code" select="$codeDest/@schemeAgencyID"/></xsl:call-template> : <xsl:value-of select="$codeDest"/>),
							<xsl:value-of select="Laboratoire/Service/NomService"/>,
							<xsl:value-of select="Laboratoire/Contact/NomContact"/></fo:block></fo:table-cell></fo:table-row><fo:table-row><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:copy-of select="$puce1"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Label10"><fo:block><fo:basic-link external-destination="url(http://www.sandre.eaufrance.fr/?urn=urn:sandre:dictionnaire:LAB::attribut:CompletEchant:ressource:1:::html)">Complétude de l'echantillon:</fo:basic-link></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:value-of select="key('keyNomenclature340', CompletEchant)/ref:LbElement"/>(<xsl:value-of select="CompletEchant"/>)</fo:block></fo:table-cell></fo:table-row><fo:table-row><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:copy-of select="$puce1"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Label10"><fo:block><fo:basic-link external-destination="url(http://www.sandre.eaufrance.fr/?urn=urn:sandre:dictionnaire:LAB::attribut:RefEchantillonCommanditaire:ressource:1:::html)">Référence de l'échantillon chez le commanditaire :</fo:basic-link></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:value-of select="RefEchantillonCommanditaire"/></fo:block></fo:table-cell></fo:table-row><fo:table-row><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:copy-of select="$puce1"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Label10"><fo:block><fo:basic-link external-destination="url(http://www.sandre.eaufrance.fr/?urn=urn:sandre:dictionnaire:LAB::attribut:RefEchantillonPrel:ressource:1:::html)">Référence de l'échantillon chez le préleveur :</fo:basic-link></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:value-of select="RefEchantillonPrel"/></fo:block></fo:table-cell></fo:table-row><fo:table-row><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:copy-of select="$puce1"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Label10"><fo:block><fo:basic-link external-destination="url(http://www.sandre.eaufrance.fr/?urn=urn:sandre:dictionnaire:LAB::attribut:RefEchantillonLabo:ressource:1:::html)">Référence de l'échantillon chez le laboratoire :</fo:basic-link></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:value-of select="RefEchantillonLabo"/></fo:block></fo:table-cell></fo:table-row><fo:table-row><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:copy-of select="$puce1"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Label10"><fo:block><fo:basic-link external-destination="url(http://www.sandre.eaufrance.fr/?urn=urn:sandre:dictionnaire:PAR::entite:Methode:ressource:latest:::html)">Méthode de transport :</fo:basic-link></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:value-of select="key('keyMethode', MethodeTransport/CdMethode)/ref:LbLongMethode"/>(<xsl:value-of select="MethodeTransport/CdMethode"/>)</fo:block></fo:table-cell></fo:table-row><xsl:variable name="codePayeur" select="Payeur/CdIntervenant"/><xsl:if test="$codePayeur != $codePayeurDemande"><fo:table-row><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:copy-of select="$puce1"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Label10"><fo:block>Payeur de l'ensemble des analyses à réaliser sur cet échantillon :</fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:value-of select="key('keyIntervenant', $codePayeur)/NomIntervenant"/>(<xsl:call-template name="origineCode"><xsl:with-param name="code" select="$codePayeur/@schemeAgencyID"/></xsl:call-template> : <xsl:value-of select="$codePayeur"/>),
								<xsl:value-of select="Payeur/Service/NomService"/>,
								<xsl:value-of select="Payeur/Contact/NomContact"/></fo:block></fo:table-cell></fo:table-row></xsl:if><fo:table-row><fo:table-cell xsl:use-attribute-sets="Value10"><fo:block><xsl:copy-of select="$puce1"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Label10" number-columns-spanned="2"><fo:block>Résultats d'analyses réalisées sur cet échantillon:</fo:block></fo:table-cell></fo:table-row></fo:table-body></fo:table><fo:table table-layout="fixed" xsl:use-attribute-sets="allBord"><fo:table-column column-width="25mm"/><fo:table-column column-width="32mm"/><fo:table-column column-width="25mm"/><fo:table-column column-width="25mm"/><fo:table-column column-width="25mm"/><fo:table-column column-width="15mm"/><fo:table-column column-width="17mm"/><fo:table-column column-width="20mm"/><fo:table-column column-width="15mm"/><fo:table-column column-width="75mm"/><fo:table-header><fo:table-row><fo:table-cell xsl:use-attribute-sets="Value10 cellH" number-rows-spanned="2"><fo:block><fo:basic-link external-destination="url(http://www.sandre.eaufrance.fr/?urn=urn:sandre:dictionnaire:PAR::entite:Parametre:ressource:latest:::html)">PARAMETRE</fo:basic-link><fo:block/>nom (code)</fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value10 cellH" number-rows-spanned="2"><fo:block><fo:basic-link external-destination="url(http://www.sandre.eaufrance.fr/?urn=urn:sandre:dictionnaire:PAR::entite:FractionAnalysee:ressource:latest:::html)">FRACTION ANALYSEE</fo:basic-link><fo:block/>nom (code)</fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value10 cellH" number-rows-spanned="2"><fo:block><fo:basic-link external-destination="url(http://www.sandre.eaufrance.fr/?urn=urn:sandre:dictionnaire:PAR::entite:Methode:ressource:latest:::html)">METHODE D'ANALYSE</fo:basic-link><fo:block/>nom (code)</fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value10 cellH" number-rows-spanned="2"><fo:block><fo:basic-link external-destination="url(http://www.sandre.eaufrance.fr/?urn=urn:sandre:dictionnaire:LAB::attribut:InsituAna:ressource:1:::html)">TYPE D'ANALYSE</fo:basic-link></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value10 cellH" number-rows-spanned="2"><fo:block><fo:basic-link external-destination="url(http://www.sandre.eaufrance.fr/?urn=urn:sandre:dictionnaire:LAB::attribut:RsAna:ressource:1:::html)">RESULTATS</fo:basic-link></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value10 cellH" number-columns-spanned="3"><fo:block>Valeurs seuils</fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value10 cellH" number-rows-spanned="2"><fo:block><fo:basic-link external-destination="url(http://www.sandre.eaufrance.fr/?urn=urn:sandre:dictionnaire:LAB::attribut:IncertAna:ressource:1:::html)">Incertitude analytique (%)</fo:basic-link></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value10 cellH" number-rows-spanned="2"><fo:block><fo:basic-link external-destination="url(http://www.sandre.eaufrance.fr/?urn=urn:sandre:dictionnaire:LAB::attribut:AccreAna:ressource:1:::html)">Qualification</fo:basic-link></fo:block></fo:table-cell></fo:table-row><fo:table-row><fo:table-cell xsl:use-attribute-sets="Value10 cellH"><fo:block><fo:basic-link external-destination="url(http://www.sandre.eaufrance.fr/?urn=urn:sandre:dictionnaire:LAB::attribut:LDAna:ressource:1:::html)">Seuil de détection</fo:basic-link></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value10 cellH"><fo:block><fo:basic-link external-destination="url(http://www.sandre.eaufrance.fr/?urn=urn:sandre:dictionnaire:LAB::attribut:LQAna:ressource:1:::html)">Seuil de quantification</fo:basic-link></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value10 cellH"><fo:block><fo:basic-link external-destination="url(http://www.sandre.eaufrance.fr/?urn=urn:sandre:dictionnaire:LAB::attribut:LSAna:ressource:1:::html)">Seuil de saturation</fo:basic-link></fo:block></fo:table-cell></fo:table-row></fo:table-header><fo:table-body><xsl:apply-templates select="Analyse"/></fo:table-body></fo:table></xsl:template>


	<!-- ========================================= -->
	<!-- = DETAIL D'UNE ANALYSE D'UN ECHANTILLON = -->
	<!-- ========================================= --><xsl:template match="Analyse"><fo:table-row><fo:table-cell xsl:use-attribute-sets="Value10 cell"><fo:block><xsl:value-of select="key('keyParametre', Parametre/CdParametre)/ref:NomParametre"/>(<xsl:value-of select="Parametre/CdParametre"/>)</fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value10 cell"><fo:block><xsl:value-of select="key('keyFraction', FractionAnalysee/CdFractionAnalysee)/ref:LbFractionAnalysee"/>(<xsl:value-of select="FractionAnalysee/CdFractionAnalysee"/>)</fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value10 cell"><fo:block><xsl:value-of select="key('keyMethode', Methode/CdMethode)/ref:LbLongMethode"/>(<xsl:value-of select="Methode/CdMethode"/>)</fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value10 cell"><fo:block><xsl:value-of select="key('keyNomenclature156', InsituAna)/ref:LbElement"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value10 cell"><fo:block><xsl:variable name="rsU"><xsl:value-of select="RsAna"/><xsl:text> </xsl:text><xsl:value-of select="key('keyUniteReference', UniteReference/CdUniteReference)/ref:SymUniteReference"/></xsl:variable><xsl:choose><xsl:when test="RqAna = 0">Analyse non faite</xsl:when><xsl:when test="RqAna = 1">= <xsl:copy-of select="$rsU"/></xsl:when><xsl:when test="RqAna = 2">&lt; <xsl:copy-of select="$rsU"/>(LD)</xsl:when><xsl:when test="RqAna = 3">&gt; <xsl:copy-of select="$rsU"/></xsl:when><xsl:when test="(RqAna = 4) and (RsAna = 1)">Présence</xsl:when><xsl:when test="(RqAna = 4) and (RsAna = 2)">Absence</xsl:when><xsl:when test="(RqAna = 4) and (RsAna != 2) and (RsAna != 1) ">Erreur dans le fichier</xsl:when><xsl:when test="RqAna = 5">incomptable</xsl:when><xsl:when test="RqAna = 6">taxon non individualisable</xsl:when><xsl:when test="RqAna = 7">traces &lt; <xsl:copy-of select="$rsU"/></xsl:when><xsl:when test="RqAna = 8">Dénombrement &gt; <xsl:copy-of select="$rsU"/></xsl:when><xsl:when test="RqAna = 9">Dénombrement &lt; <xsl:copy-of select="$rsU"/></xsl:when><xsl:when test="RqAna = 10">&lt; <xsl:copy-of select="$rsU"/>(LQ)</xsl:when><xsl:when test="(RqAna != 1) and (RqAna != 2) and (RqAna != 3) and (RqAna != 4) and (RqAna != 5) and (RqAna != 6) and (RqAna != 7) and (RqAna != 8) and (RqAna != 9) and (RqAna != 10)">Erreur dans le fichier</xsl:when></xsl:choose></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value10 cell"><fo:block><xsl:value-of select="LDAna"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value10 cell"><fo:block><xsl:value-of select="LQAna"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value10 cell"><fo:block><xsl:value-of select="LSAna"/></fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value10 cell"><fo:block><xsl:value-of select="IncertAna"/>%</fo:block></fo:table-cell><fo:table-cell xsl:use-attribute-sets="Value10 cell"><fo:block>- Accréditation:<xsl:value-of select="key('keyNomenclature299', AccreAna)/ref:LbElement"/><fo:block/>- Confirmation:<xsl:value-of select="key('keyNomenclature300', ConfirAna)/ref:LbElement"/><fo:block/>- Reserve:<xsl:value-of select="key('keyNomenclature335', ReserveAna)/ref:LbElement"/></fo:block></fo:table-cell></fo:table-row></xsl:template></xsl:stylesheet>