Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Stephane Crozat
hdoc
Commits
69b096a3
Commit
69b096a3
authored
Dec 28, 2016
by
Esquilax76
Browse files
fix pb aims and exercices
parent
6ecd9423
Changes
2
Hide whitespace changes
Inline
Side-by-side
hdoc_to_neo4j/xsl/hdoc_to_neo4j.xsl
View file @
69b096a3
...
...
@@ -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
opale_to_hdoc/xsl/opale_to_hdoc_regle2.xsl
View file @
69b096a3
...
...
@@ -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>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment