Select to view content in your preferred language

Custom Report In WAB

1371
7
04-29-2019 09:11 AM
joerodmey
MVP Alum

Looking to build on reporting in WAB based on this blog post: Creating a Custom Widget for Web AppBuilder for ArcGIS using the Report Class | ArcGIS Blog

I want to automatically pull data and pictures from my feature service and plunk it into my report. Need my user to have a one click report button

0 Kudos
7 Replies
VictorTey
Esri Contributor

No reason why you cannot do that. You will just need to make sure you have those data available in your printdata html before you send it to be printed.

If you are printing image via a uri, you just need to make sure your print access has access to it else you get encode it in base64

0 Kudos
joerodmey
MVP Alum

Can you provide some examples? I'm currently stuck here

Thanks

0 Kudos
VictorTey
Esri Contributor

without more context, I am not sure how to provide you with more examples. I can however point you to resource that may aid you.

PrintServer: ( you can customize the print template)  

https://enterprise.arcgis.com/en/server/latest/create-web-apps/windows/printing-in-web-applications....

if you want to customize the html portion in your widget, you can request the data from your feature service and modify the data portion of your json file. the <div> portion

https://enterprise.arcgis.com/en/server/latest/create-web-apps/windows/printing-in-web-applications....

0 Kudos
Henry_PeleshBW
Occasional Contributor

Victor,

Are you able to provide an example of how to write the code from the data portion of the json to populate attribute data from an existing feature service? Rather than hard coding the table columns and rows, I would like to pull the field names and rows of data to input them into the table when printing.

Thanks,

Henry

0 Kudos
LouieRodriguez
New Contributor III

Was a solution ever found for this issue?

0 Kudos
MarkCooper5
Occasional Contributor II

joe rodmey‌ Did you ever manage to get a report produced? We are looking to do something very similar but we are completely stuck!

Thanks

0 Kudos
joerodmey
MVP Alum

Hi Mark,

I ended up creating my report in Survey123 using the custom report function, webhooks, and Integromat. The route shown here would be nice but it doesn't work as nicely as expected without tons of new development. For my purposes the Survey123 report actually works better because I can send it in an email to the user very easily. The report also handles the complexities like related tables and pictures.

Let me know if you need any specifics and I would be more than happy to provide you more info.

0 Kudos