No page margin on cover page included with #child
-
Hi @jan_blaha
I have one scenario where I need to repeat the cover page as per data. and I need to pass the data on that cover page as well. but because it's a cover page I do not want the margin on the cover page but other pages can contain the table designs and I want margins for other pages.if I will prepend the cover page with pdf utils I can not able to repeat that and If I'll use it as a #child I am not able to do the margin zero on that page.
https://playground.jsreport.net/w/happypatel20/JiEYjjJH
Can we do anything here? Or is there any other option to achieve the requirements?
Thanks!!
-
The pdf utils can be used dynamically using script
https://jsreport.net/learn/pdf-utils#usage-in-scriptUpdated demo
https://playground.jsreport.net/w/anon/c5Vrc5lX
-
@jan_blaha we need to repeat the cover page like below for each candidates the cover page will be there along with other pages. and we do not need the margin on every cover pages. moreover at the same time we need to hide the footer on the cover page
https://playground.jsreport.net/w/happypatel20/JiEYjjJH
Thanks!
-
Yes the same story, you can use the script with dynamically called pdf utils operations
https://playground.jsreport.net/w/anon/c5Vrc5lX
-
Got it, Thanks much !! @jan_blaha
-
@jan_blaha when we are using this approach and there are many amount of data and many pages present in original report, it's throwing timeout error for loading the script. can we do something for the same?
https://playground.jsreport.net/w/happypatel20/q7mze0Vn
Error: Timeout during execution of user script at Timeout._onTimeout (/app/node_modules/script-manager/lib/manager-processes.js:29:10) at listOnTimeout (internal/timers.js:549:17) at processTimers (internal/timers.js:492:7)
Thanks!
-
Yes, increase the timeout.
I see you use quite an old version of jsreport based on the stack trace.
If you see propreportTimeout
, try to increase it.
If you havetemplatingEngines.timeout
orextensions.scripts.timeout
there, try to increase it as well.
-
Hi @jan_blaha
I have increased timeout in config file still getting error of timeout, can you please take a look at config file. Before I had only
chrome-pdf.timeout
there in my file. I have added others and tried but not working. Thanks"extensions": { "fs-store": { "dataDirectory": "data", "syncModifications": { "updateStudio": true } }, "chrome-pdf": { "timeout": 600000000 }, "scripts": { "timeout": 600000000 } }, "store": { "provider": "fs" }, "allowLocalFilesAccess" : true, "reportTimeout": 600000000, "templatingEngines" : { "allowedModules": ["handlebars-group-by"], "timeout": 600000000 } }
-
The config looks ok for v2 so I don't know.
Could you try to update to the latest v2 and test again?
-
@jan_blaha do you mean need to update jsreport version?
-
You didn't mention what version you use... but if you have some problems, testing it with the updated version is a good thing to do for better problem isolation.