Where to assign docx file to template using docxtemplater?



  • I am using the docxtemplater recipe on my template. I want to switch it to use a different docx file, but I can't remember where to do that. Looking at the video at https://jsreport.net/learn/docxtemplater it shows that after creating a template and selecting the docxtemplater recipe I should be able to select from the 'docxtemplater asset' dropdown. On my instance of jsreport I don't have that. I know the setting exists because this template is already hooked up and running against this docx file.

    I'm on jsreport version 2.5.0

    Here's an image:

    0_1576273652304_upload-8c330acd-445b-4f0c-9c49-efa592396be4

    So, where is this setting? I can't find it.



  • I believe it is a version collision. The latest jsreport-docxtemplater isn't compatible with jsreport@2.5.0.
    You should be able to use older version jsreport-docxtemplater@0.2.0 or update jsreport to the latest.



  • Hmm.. It's an older version of jsreport-docxtemplater. I will repeat that I do have this working - I am using a docx as a template, but now I can't change it.

    jsreport-cli@2.0.7
    jsreport@2.5.0
    jsreport-docxtemplater@1.0.0
    jsreport-unoconv@0.2.0



  • Can you try the mentioned jsreport-docxtemplater 0.2.0?


Log in to reply
 

Looks like your connection to jsreport forum was lost, please wait while we try to reconnect.