Skip to content

Commit

Permalink
keep the streamText's xml:id through compilation via jf:merged/jf:com…
Browse files Browse the repository at this point in the history
…bined
  • Loading branch information
EfraimFeinstein committed Mar 28, 2014
1 parent c709572 commit 03ee2bb
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
6 changes: 6 additions & 0 deletions opensiddur-server/src/transforms/flatten.xqm
Expand Up @@ -157,6 +157,12 @@ declare function flatten:merge(
$params as map
) as element(jf:merged) {
element jf:merged {
(: jf:merged takes the place of streamText :)
$streamText/(@* except @xml:id),
if ($streamText/@xml:id)
then
attribute jf:id { $streamText/@xml:id }
else (),
flatten:order-flattened(
(
$layers/(node() except jf:placeholder),
Expand Down
Expand Up @@ -66,7 +66,7 @@
]]></code>
<xpath
desc="acts as an identity transform for unflattened text"
>exists(./tei:TEI/tei:text/jf:combined/tei:seg[@jf:id="seg1"][@jf:stream="stream"])
>exists(./tei:TEI/tei:text/jf:combined[@jf:id="stream"]/tei:seg[@jf:id="seg1"][ends-with(@jf:stream,"#stream")])
</xpath>
<xpath
desc="a license statement is added"
Expand Down

0 comments on commit 03ee2bb

Please sign in to comment.