Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

Trouble with repeating-section

New Here ,
May 23, 2023 May 23, 2023

Hi,

I have a simple JSON like below, but my template are not filled with data.
Instead, the template tags appears.

Any idea?

Template tag in my docx file.

{% repeating-section actionSites %}
{{address}} {{zipCode}} {{city}} {{country}}
{% end-section %}

 

JSON

{
	"actionSites": [{
		"id": "addr_0CECVBMCH4M64",
		"address": "7 rue TOTO",
		"complement": "",
		"city": "Lor",
		"zipCode": "56789",
		"country": "FR"
	}, {
		"id": "addr_0CECVFG6H4PAZ",
		"address": "addr 2",
		"complement": "",
		"city": "city 2",
		"zipCode": "postal2",
		"country": "FR"
	}, {
		"id": "addr_0CECVE01S4M6N",
		"address": "Site 1",
		"complement": "",
		"city": "City 1",
		"zipCode": "Post code 1",
		"country": "FR"
	}]
}

 

841
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
May 23, 2023 May 23, 2023

Hi @Stephane29154717bl5j 

 

Are you using the document generation add-in for Word? I added multiple variations based on your JSON structure and did not have any issues with the resulting output.

Mikolz_0-1684848548536.png

Mikolz_1-1684848621858.png

 

 

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
May 24, 2023 May 24, 2023

I'm not using the addon.
I asked a colleague to try with it, but whithout more success.

 

I have the same problem with conditional-expression. Sometimes it works sometimes not.
In the  below image I tried some stuff, but in the result, it displays as if it were text on the generated PDF.

Screenshot 2023-05-24 at 17.47.36.png

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
May 31, 2023 May 31, 2023
LATEST

The only time I have seen this happen is when the JSON you are sending with the document generation request does not match the tags defined in your template. Are you able to confirm that the JSON you are sending in the jsonDataForMerge propery is what you are expecting and more importantly matches the tags in your template?

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources