+++ /dev/null
-<?xml version="1.0" encoding="ISO-8859-1"?>
-<!DOCTYPE xsl:stylesheet [
-<!ENTITY nbsp " ">
-<!ENTITY egrave "è">
-<!ENTITY euro "€">
-<!ENTITY agrave "à">
-<!ENTITY eacute "é">
-]><!-- xmlns="http://www.xemelios.org/namespaces#cge" -->
-<xsl:transform
- xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
- xmlns="http://www.w3.org/1999/xhtml"
- xmlns:n="http://www.xemelios.org/namespaces#cge"
- xmlns:added="http://www.xemelios.org/namespaces#added"
- version="2.0"
- exclude-result-prefixes="added n xsl">
- <xsl:character-map name="accents">
- <xsl:output-character character="à" string="&#224;"/>
- <xsl:output-character character="é" string="&#233;"/>
- <xsl:output-character character="è" string="&#232;"/>
- <xsl:output-character character="ê" string="&#234;"/>
- <xsl:output-character character="ë" string="&#235;"/>
- <xsl:output-character character="î" string="&#238;"/>
- <xsl:output-character character="ï" string="&#239;"/>
- <xsl:output-character character="ô" string="&#244;"/>
- <xsl:output-character character="ù" string="&#249;"/>
- </xsl:character-map>
-
- <xsl:decimal-format name="decformat" decimal-separator="," grouping-separator=" " digit="#" pattern-separator=";" NaN="NaN" minus-sign="-"/>
-
- <!-- Inclusion des XSL externes -->
- <xsl:include href="./common-xsl/Style.xsl"/>
- <xsl:include href="./common-xsl/Error.xsl"/>
- <xsl:include href="./common-xsl/Navigate.xsl"/>
- <xsl:include href="./common-xsl/Header.xsl"/>
- <xsl:include href="./common-xsl/Number.xsl"/>
-
- <!-- Paramètres d'entrée -->
- <xsl:param name="show.formulaire"/>
- <xsl:param name="browser-destination"/>
-
- <!-- Paramètres Web -->
- <xsl:param name="is.web">-1</xsl:param>
- <xsl:param name="context.path"/>
-
- <!-- Paramètres d'entrée de la liste de résultat -->
- <xsl:param name="libPoste">0</xsl:param>
-
- <!-- Paramètres d'erreur -->
- <xsl:param name="error.message">nomessage</xsl:param>
-
- <!-- Paramètres d'entrée de la liste de résultat -->
- <xsl:param name="numCompte">0</xsl:param>
- <xsl:param name="ministere">0</xsl:param>
- <xsl:param name="programme">0</xsl:param>
- <xsl:param name="article">0</xsl:param>
-
- <!-- Variables -->
- <xsl:variable name="page-format" select="paysage"/>
- <xsl:variable name="NumPage" select="/n:CompteGestionEtat/n:DeveloppementDepense/n:PageDeveloppementDepense/n:Pied/@NumPage"/>
- <xsl:variable name="LastPage" select="/n:CompteGestionEtat/n:DeveloppementDepense/n:PageDeveloppementDepense/@added:LastPage"/>
- <xsl:variable name="isLastPage" select="/n:CompteGestionEtat/n:DeveloppementDepense/n:PageDeveloppementDepense/@added:isLastPage"/>
- <xsl:variable name="Entete">
- <xsl:copy-of select="/n:CompteGestionEtat/n:Entete"/>
- </xsl:variable>
-
- <xsl:output method="xhtml" indent="yes" use-character-maps="accents" encoding="ISO-8859-1"/>
-
- <!-- pour eviter les sorties parasites de tags non matches -->
- <xsl:template match="*"/>
-
- <xsl:template match="/n:CompteGestionEtat">
- <html>
- <head>
- <title>Développement des dépenses budgétaires par ministère et programme</title>
- <xsl:call-template name="style"/>
- </head>
- <body>
- <xsl:if test="$error.message!='nomessage'">
- <xsl:attribute name="onload">javascript:showDialog('<xsl:value-of select="$error.message"/>');</xsl:attribute>
- </xsl:if>
- <xsl:call-template name="Error"><!--xsl:with-param name="error.message" select="$error.message"/--></xsl:call-template>
- <xsl:call-template name="navigate">
- <xsl:with-param name="docId">compteGestionEtat</xsl:with-param>
- <xsl:with-param name="etatId">DeveloppementDepense</xsl:with-param>
- <xsl:with-param name="elementId">PageDeveloppementDepense</xsl:with-param>
- <xsl:with-param name="sous.elementId">LigneDeveloppementDepense</xsl:with-param>
- <xsl:with-param name="NumPage" select="$NumPage"/>
- <xsl:with-param name="LastPage" select="$LastPage"/>
- <xsl:with-param name="isLastPage" select="$isLastPage"/>
- <xsl:with-param name="Entete" select="$Entete"/>
- <xsl:with-param name="show.formulaire" select="$show.formulaire"/>
- <xsl:with-param name="show.formulaire.compte" select="1"/>
- <xsl:with-param name="show.depense.recette" select="0"/>
- <xsl:with-param name="is.web" select="$is.web"/>
- <xsl:with-param name="context.path" select="$context.path"/>
- </xsl:call-template>
- <xsl:call-template name="header" >
- <xsl:with-param name="Entete" select="$Entete"/>
- <xsl:with-param name="Titre">Développement des dépenses budgétaires par ministère et programme</xsl:with-param>
- </xsl:call-template>
- <xsl:call-template name="mainTable">
- <xsl:with-param name="el" select="n:DeveloppementDepense/n:PageDeveloppementDepense"/>
- </xsl:call-template>
- <p>
- <center>Page <xsl:choose><xsl:when test="$LastPage and string-length($LastPage) > 0"><xsl:value-of select="$NumPage"/> / <xsl:value-of select="$LastPage"/></xsl:when><xsl:otherwise>- <xsl:value-of select="$NumPage"/></xsl:otherwise></xsl:choose></center>
- </p>
- <xsl:call-template name="navigate">
- <xsl:with-param name="docId">compteGestionEtat</xsl:with-param>
- <xsl:with-param name="etatId">DeveloppementDepense</xsl:with-param>
- <xsl:with-param name="elementId">PageDeveloppementDepense</xsl:with-param>
- <xsl:with-param name="sous.elementId">LigneDeveloppementDepense</xsl:with-param>
- <xsl:with-param name="NumPage" select="$NumPage"/>
- <xsl:with-param name="LastPage" select="$LastPage"/>
- <xsl:with-param name="isLastPage" select="$isLastPage"/>
- <xsl:with-param name="Entete" select="$Entete"/>
- <xsl:with-param name="show.formulaire" select="$show.formulaire"/>
- <xsl:with-param name="show.formulaire.compte" select="1"/>
- <xsl:with-param name="show.depense.recette" select="0"/>
- <xsl:with-param name="ancre">#footer</xsl:with-param>
- <xsl:with-param name="display.logos.entete">0</xsl:with-param>
- <xsl:with-param name="is.web" select="$is.web"/>
- <xsl:with-param name="context.path" select="$context.path"/>
- </xsl:call-template>
- <p id="footer"/>
- </body>
- </html>
- </xsl:template>
-
- <xsl:template name="mainTable">
- <xsl:param name="el"/>
- <table width="100%" class="bordered" id="main">
- <colgroup>
- <col width="20%"/>
- <col width="25%"/>
- <col width="10%"/>
- <col width="20%"/>
- <col width="10%"/>
- <col width="15%"/>
- </colgroup>
- <thead>
- <tr class="titre">
- <td class="titre2 center bold bordered">Comptes</td>
- <td class="titre2 center bold bordered">Montant OAD</td>
- <td class="titre2 center bold bordered">Ministère</td>
- <td class="titre2 center bold bordered">Programmes</td>
- <td class="titre2 center bold bordered">Article<br/>exécution</td>
- <td class="titre2 center bold bordered">Dépenses admises</td>
- </tr>
- </thead>
- <tbody>
- <xsl:variable name="nums.comptes" select="distinct-values($el/n:LigneDeveloppementDepense/@NumCompte)"/>
- <xsl:for-each select="$nums.comptes">
- <xsl:sort select="."/>
- <xsl:variable name="this.compte" select="."/>
- <xsl:variable name="lignes.this.compte" select="$el/n:LigneDeveloppementDepense[@NumCompte=$this.compte]"/>
- <xsl:variable name="nb.lignes.this.compte" select="count($lignes.this.compte)"/>
-
- <xsl:variable name="ministeres.lignes.this.compte" select="distinct-values($lignes.this.compte/@Ministere)"/>
-
- <xsl:variable name="min.ministere" select="min($lignes.this.compte/@Ministere)"/>
- <xsl:variable name="min.ministere.lignes" select="$lignes.this.compte[number(@Ministere)=$min.ministere]"/>
-
- <xsl:variable name="min.article.ministere.lignes" select="min($min.ministere.lignes/@ArticleExec)"/>
-
- <xsl:variable name="first" select="$min.ministere.lignes[1]/@added:generated-id"/>
-
-
- <xsl:variable name="position.compte" select="position()"/>
-
-
- <tr class="mask">
- <td class="titre center bold bordered">
- <xsl:attribute name="rowspan" select="$nb.lignes.this.compte"/>
- <h3 style="color: black;"><xsl:value-of select="."/></h3>
- </td>
- <td colspan="5"> </td>
- </tr>
- <xsl:for-each select="$ministeres.lignes.this.compte">
- <xsl:sort select="." data-type="text"/>
- <xsl:variable name="this.ministere" select="."/>
- <xsl:variable name="lignes.this.ministere" select="$lignes.this.compte[@Ministere=$this.ministere]"/>
-
- <xsl:variable name="position.ministere" select="position()"/>
-
- <xsl:variable name="programme.this.ministeres.lignes.this.compte" select="distinct-values($lignes.this.ministere/@Programme)"/>
-
- <xsl:for-each select="$programme.this.ministeres.lignes.this.compte">
- <xsl:sort select="."/>
- <xsl:variable name="this.programme" select="."/>
- <xsl:variable name="lignes.this.programme" select="$lignes.this.ministere[@Programme=$this.programme]"/>
-
- <xsl:for-each select="$lignes.this.programme[string-length(@ArticleExec) > 0]">
- <xsl:sort select="@ArticleExec" data-type="text"/>
- <xsl:variable name="articleExec" select="@ArticleExec"/>
- <xsl:variable name="position.programme" select="position()"/>
- <tr>
- <xsl:choose>
- <xsl:when test="$numCompte != '0' and @NumCompte=$numCompte and $this.ministere=$ministere and $this.programme=$programme and $articleExec=$article">
- <xsl:attribute name="id">highlighted</xsl:attribute>
- </xsl:when>
- <xsl:otherwise>
- <xsl:choose>
- <xsl:when test="(position() mod 2) = 0">
- <xsl:attribute name="id">colorised3</xsl:attribute>
- </xsl:when>
- <xsl:otherwise>
- <xsl:attribute name="id">colorised2</xsl:attribute>
- </xsl:otherwise>
- </xsl:choose>
- </xsl:otherwise>
- </xsl:choose>
- <xsl:choose>
- <xsl:when test="@MtDebit"><xsl:attribute name="class">NotTotal</xsl:attribute></xsl:when>
- </xsl:choose>
-
- <td class="montant bordered"><xsl:call-template name="number"><xsl:with-param name="num" select="@MtDebit"/></xsl:call-template> €</td>
- <td class="bordered center"><xsl:value-of select="$this.ministere"/></td>
- <xsl:if test="$position.programme eq 1">
- <td class="bordered center">
- <xsl:attribute name="rowspan" select="count($lignes.this.programme) - 1"/>
- <xsl:value-of select="$this.programme"/>
- </td>
- </xsl:if>
- <td class="bordered center"><xsl:value-of select="@ArticleExec"/></td>
- <!--td class="montant bordered"><xsl:call-template name="number"><xsl:with-param name="num" select="@MtDebit"/></xsl:call-template> €</td-->
- <xsl:element name="a">
- <xsl:attribute name="href">
- <xsl:text disable-output-escaping="yes">xemelios:/customLink?srcDocId=compteGestionEtat&srcEtatId=DeveloppementDepense&srcElementId=PageDeveloppementDepense&srcCollectivite=</xsl:text><xsl:value-of select="$Entete//n:Collectivite/@Siret"/>
- <xsl:text disable-output-escaping="yes">&srcBudget=</xsl:text><xsl:value-of select="$Entete//n:Collectivite/@CodeBudget"/>
- <xsl:text disable-output-escaping="yes">&sp1=</xsl:text><xsl:value-of select="$Entete//n:Collectivite/@Exercice"/>
- <xsl:text disable-output-escaping="yes">&comptable=</xsl:text><xsl:value-of select="$Entete//n:Collectivite/@Siret"/>
- <xsl:text disable-output-escaping="yes">&ministere=</xsl:text><xsl:value-of select="$this.ministere"/>
- <xsl:text disable-output-escaping="yes">&programme=</xsl:text><xsl:value-of select="$this.programme"/>
- <xsl:text disable-output-escaping="yes">&articleExec=</xsl:text><xsl:value-of select="@ArticleExec"/>
- </xsl:attribute>
- <xsl:call-template name="number"><xsl:with-param name="num" select="@MtDebit"/></xsl:call-template> €</xsl:element>
- </tr>
- </xsl:for-each>
- <xsl:variable name="ligne.total.this.programme" select="$lignes.this.programme[string-length(@ArticleExec) eq 0]"/>
- <tr>
- <!--td class="libelleLigne bold bordered"> <xsl:value-of select="$this.compte"/></td-->
- <td class="bold bordered center totalAnnexeII" colspan="4">Total Programme <xsl:value-of select="$this.programme"/></td>
- <td class="montant bold bordered totalAnnexeII"><xsl:call-template name="number"><xsl:with-param name="num" select="$ligne.total.this.programme/@MtDebit"/></xsl:call-template> €</td>
- </tr>
- </xsl:for-each>
- </xsl:for-each>
- <xsl:variable name="ligne.total.this.compte" select="$lignes.this.compte[string-length(@Ministere) eq 0]"/>
- <tr>
- <td class="bold totalAnnexeII1 bordered right">Total du compte <xsl:value-of select="$this.compte"/></td>
- <td class="montant bold bordered totalAnnexeII1"><xsl:call-template name="number"><xsl:with-param name="num" select="$ligne.total.this.compte/@MtDebit"/></xsl:call-template> €</td>
- <td class="montant bold bordered totalAnnexeII1" colspan="4"><xsl:call-template name="number"><xsl:with-param name="num" select="$ligne.total.this.compte/@MtDebit"/></xsl:call-template> €</td>
- </tr>
- </xsl:for-each>
- </tbody>
- </table>
- </xsl:template>
-
-</xsl:transform>