Commit 69b096a3 authored by Esquilax76's avatar Esquilax76

fix pb aims and exercices

parent 6ecd9423
......@@ -27,7 +27,18 @@
<xsl:template match="body/section/section">
MERGE (i:<xsl:value-of select="./@data-hdoc-type"/> {title:"<xsl:value-of select="concat(./header/h1,' (',string-length(.), ')')"/>"});
MATCH (l1 {title:"<xsl:value-of select="concat(./header/h1,' (',string-length(.), ')')"/>"}), (l2 {title:"<xsl:value-of select="concat(parent::section/header/h1,' (',string-length(parent::section), ')')"/>"}) MERGE (l2)-[:LIEN]->(l1);
<!--<xsl:apply-templates select="./div"/>-->
<xsl:apply-templates select="./section"/>
</xsl:template>
<!-- Traitement spécial pour les objectifs, ils ont parfois la même longueur -->
<xsl:template match="body/section/section/section[@data-hdoc-type='aims']">
MERGE (i:<xsl:value-of select="./@data-hdoc-type"/> {title:"<xsl:value-of select="concat(./header/h1,' - ', parent::section/header/h1, ' (',string-length(.), ')')"/>"});
MATCH (l1 {title:"<xsl:value-of select="concat(./header/h1,' - ', parent::section/header/h1, ' (',string-length(.), ')')"/>"}), (l2 {title:"<xsl:value-of select="concat(parent::section/header/h1,' (',string-length(parent::section), ')')"/>"}) MERGE (l2)-[:LIEN]->(l1);
</xsl:template>
<xsl:template match="body/section/section/section[not(@data-hdoc-type='aims')]">
MERGE (i:<xsl:value-of select="./@data-hdoc-type"/> {title:"<xsl:value-of select="concat(./header/h1,' (',string-length(.), ')')"/>"});
MATCH (l1 {title:"<xsl:value-of select="concat(./header/h1,' (',string-length(.), ')')"/>"}), (l2 {title:"<xsl:value-of select="concat(parent::section/header/h1,' (',string-length(parent::section), ')')"/>"}) MERGE (l2)-[:LIEN]->(l1);
</xsl:template>
</xsl:stylesheet>
\ No newline at end of file
......@@ -257,6 +257,9 @@
<header>
<xsl:apply-templates select="op:practUc/op:exeM/sp:title"/>
</header>
<div>
<xsl:value-of select="./*"/>
</div>
</section>
</xsl:template>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment