Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Section
indextrue
show-titlefalse
titleDescription

The macro allows to merge tables from different sources into one table.

Example sources may be the Transclusion Macro transcluding a table or the Display Table Macro.

Note Box

The current version of the macro only processes tables where the heading is found in the first table row (either inside an HTML thead element or not).

The Table Merger Macro does only merge rows of two tables and allows a row mapping. In case cells of two tables should be merged into one row, use the 

Static Document Link
documentTable Set Macro
. For details on this use case, refer to
Static Document Link
anchorMerging Table Columns into Rows
documentTable Set Macro
labelMerging Table Columns into Rows


Section
titleProperties


Section
titleColumn Names

List of column names to render.

If blank the columns from the tables are used.


Section
titleDiscard

Allows to discard list items or rows.

emptyDiscard empty list items or table rows without cell content.
no-linksDiscard list items or table rows if there is not at least one link.
no-itemsDiscard list items or table rows if link has class projectdoc-no-docs
fullDiscard list items or table rows if fully set (all cells have content).
partialDiscard table rows if there is at least one empty cell.  
is-checkedDiscard list items or table rows if a task list with at least one checked checkbox is found.
is-not-checkedDiscard list items or table rows if a task list with at least one checkbox is found that is not checked.
strikethroughDiscard list items or table rows if at least some text is tagged with strikethrough.


Content Marker
iddiscard-use-cases

The values empty, no-links, no-items, and no-links + no-items are typically used for definition, numbered, and bullet lists.

The values empty, full, and partial are typically used for tables. The value partial only has meaning for tables.

The value can be controlled by the space property

Static Document Link
documentTable Merger Macro Param Discard
. The space property 
Static Document Link
documentTable Merger override empty Items
 overrides the macro configuration.

Example Box
titleFilter Examples with Discard

For examples please refer to the tip Filter on Table Rows.


Content Marker
iddiscard-since-4-5


Version Box
titleNew Values
since4.5

The values full and partial are supported since version 4.5.

The values is-checked and is-not-checked are supported since version 4.6.



Version Box
since5.0

The value strikethrough is available since version 5.0.4.



Section
titleHeader Translations

Comma-separated list of key list-value pairs to map columns from tables. This allows to rename columns to match.

Format: k1=v1|v2, k2=v3.

In case the column header should be renamed, simply specify the new column name with the Column Names parameter and map the columns of the merged tables here.

Example Box

If the column on both tables to be merged is "A" but it should be named "X" and the second column "Short Description" should be not renamed, then:

  1. Column Names: X, Short Description
  2. Header Translations: X=A

In case the column to be named "X" is merged from columns named "A" and "B" then:

  1. Column Names: X, Short Description
  2. Header Translations: X=A|B



Section
titleSort By

Specify the column names for a sort order. The suffix "-" will invert the sort order (descending).

Example Box
titleTable Sort Orders
  • Name-
  • Bonus Points, Name

Any string will turn on sort on list items.

Version Box
until6.0.3

Up to version 6.0.3 the sort column for tables is limited to one column and the order is always ascending.

Note that sorting is executed on table rows. If the rows reference documents, the properties used for sorting must be rendered in the tables.


Section
titleCSS Class

Set to the table or definition list.


...