entry-form: Correct rendering of params using imported typedefs
If a param referenced a typedef that was imported from another package, the summary page displayed an error rather than rendering the field. This is a problem for testing using summary pages! Long-standing bug with a fairly easy fix. * src/current/include/entry-form.xsl: (entry-form-field lv:param): Consider correct symbol (was using param symbol, not typedef). [typesrc]: Modernize syntax. [typedef]: Allow for non-root-child elements. The old version of TAME required toplevel typedefs; that's no longer the case.master
parent
e52d6c1eb0
commit
ef1e6735b6
|
@ -247,21 +247,15 @@
|
|||
|
||||
<!-- if the @src attribute is empty, then it resides within the same package
|
||||
-->
|
||||
<xsl:variable name="typesrc">
|
||||
<xsl:choose>
|
||||
<xsl:when test="@src">
|
||||
<xsl:value-of select="@src" />
|
||||
</xsl:when>
|
||||
|
||||
<xsl:otherwise>
|
||||
<xsl:value-of select="$sym/@src" />
|
||||
</xsl:otherwise>
|
||||
</xsl:choose>
|
||||
</xsl:variable>
|
||||
<xsl:variable name="typesrc"
|
||||
select="if ( $typesym/@src ) then
|
||||
$typesym/@src
|
||||
else
|
||||
$sym/@src" />
|
||||
|
||||
<!-- load the typedef from the appropriate package -->
|
||||
<xsl:variable name="typepkg" select="
|
||||
if ( @src and not( @src='' ) ) then
|
||||
if ( $typesrc and not( $typesrc='' ) ) then
|
||||
document( concat( $typesrc, '.xmlo' ), $sym )/lv:*
|
||||
else
|
||||
$pkg
|
||||
|
@ -269,8 +263,8 @@
|
|||
<!-- this makes maintinance more difficult, but speeds up searching large
|
||||
trees -->
|
||||
<xsl:variable name="typedef" select="
|
||||
$typepkg/lv:typedef[ @name=$type ]
|
||||
|$typepkg/lv:typedef/lv:union/lv:typedef[ @name=$type ]
|
||||
$typepkg//lv:typedef[ @name=$type ]
|
||||
|$typepkg//lv:typedef/lv:union/lv:typedef[ @name=$type ]
|
||||
" />
|
||||
|
||||
<xsl:choose>
|
||||
|
|
Loading…
Reference in New Issue