Hi,
I would like to insert a blank line in a table as a repeating block if a certain condition is met. I use the template as attached and a JSON code as follows:
{
"Mangel-ID": 391,
"Bild1": {
"Displayname": "Mangel_391_1.jpg",
"Bild": "data:image/png;base64,/9j/4AA..."
},
"Bild2": {
"Displayname": "Mangel_391_2.jpg",
"Bild": "data:image/png;base64,/9j/4AAQS..."
},
"Bild3": {
"Displayname": "Mangel_391_3.jpg",
"Bild": "data:image/png;base64,/9j/4A..."
},
"Bild4": {
"Displayname": "Mangel_391_4.jpg",
"Bild": "data:image/png;base64,/9j/4AAQS..."
},
"Bildanzahl": 4
},
{...
Now I want that if the number of images is >3, a line break is inserted after the image in the cell (
) as html code.
The aim is, in the case that there is no 2nd image row, the then empty table row works as a separation to the next block and in the other case the empty row is simulated by
, so that the appearance is the same. The frames of the table are finally removed.
Any ideas?
Best regards
Thomas
Mangelbericht_Vorlage_Bilderanlage.docx (26.0 KB)
Complete JSON
Hi @t.porstein,
You can try to use a table cell with the * hide-block-if formatter.
So, the token is {{Bildanzahl}:hide-block-if(value <= 3)}
, otherwise the block will exist if the value is > 3 and separate the pictures. It can be also a rich text control.
Best regards,
Petr
Plumsail team