Hi,
the following template is used to construct a table (parenthesis are intentionally left out):
m:template createExchangeItemTable(exchangeItem:information::ExchangeItem)
m: testExchangeItem.createHeader()
m:for exchangeItemElement | testExchangeItem.ownedElements
m: 1.createBlockOfRows(exchangeItemElement)
m:endfor
m:endTemplate
m: testExchangeItem.createExchangeItemTable()
The issue is that the rows are reversed (LIFO) in the generated document, when the above template is used:
… as opposed to simply using the exactly same code not wrapped in a template:
m: testExchangeItem.createHeader()
m:for exchangeItemElement | testExchangeItem.ownedElements
m: 1.createBlockOfRows(exchangeItemElement)
m:endfor
which generates the correct table:
We are using m2doc 3.0.0. Is this issue known and corrected in a newer version of m2doc?
The list of known issues are listed here .
We had some issues in the past regarding tables and/or templates constructs. It’s possible that one of the following bug fixes resolve your issue using a newer version of M2Doc:
opened 06:33PM - 05 Jun 19 UTC
closed 07:11AM - 06 Jun 19 UTC
When sub-tempates are called reqursively tables are placed in the wrong place.
In the attached test two templates are defined.
One tempate is...
opened 03:52PM - 11 Apr 19 UTC
closed 03:35PM - 13 Feb 20 UTC
I'm submitting a...
[ ] Regression (a behavior that used to work and stopped working in a new release)
[x] Bug report
[...
opened 03:31PM - 26 Feb 18 UTC
closed 01:29PM - 30 Jan 19 UTC
In repetitions with a paragraph and a table, paragraphs are repeated then tables. We should have a a paragraph, a table,...
If the problem is still present with M2Doc 3.1.0 please open an issue.