Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Template #5 - Enketo template #23

Open
joeflack4 opened this issue Jul 11, 2018 · 0 comments
Open

Template #5 - Enketo template #23

joeflack4 opened this issue Jul 11, 2018 · 0 comments
Labels
issue in development Not yet ready to be worked on. new feature P4 Priority: 4/5 (1=High, 5=Low)

Comments

@joeflack4
Copy link
Contributor

joeflack4 commented Jul 11, 2018

Description

Enketo has pretty templates. Since these are HTML, it should be possible Enketo as a dependency, and generate forms in any file output format.

Additional information

From Martijn van de Rijdt, July 12:

Cool stuff @Joseph_E_Flack_IV! I think it's great to have another tool in the ODK Ecosystem that can be used for printing/pdf-ing/converting!

If you're going the Enketo route in the future, here is some (perhaps) useful info:

API for direct PDF creating in multiple paper formats, orientation, margins and themes: https://apidocs.enketo.org/v2#/post-survey-view-pdf. This is another example output using the Grid Theme: Fatal injury surveillance data collection form (short version).pdf (108.7 KB). So far I don't think this feature has been made available to users yet (in e.g. KoBo or Ona). I'm particularly excited about this as it takes away the pain of dealing with printing consistently across multiple browsers (it uses Chrome headless (puppeteer) on the server - which maybe you are using as well?).
If you're ever considering using XForms as the basis, this is the XSL stylesheet (using XSLT) Enketo is using to transform XML to HTML: https://github.com/enketo/enketo-xslt/tree/master/xsl
Creating another theme: https://github.com/enketo/enketo-core#notes-for-css-developers (sorry, this really needs better documentation) and https://github.com/kobotoolbox/enketo-express#themes.


Attachments

  1. example_pdf.pdf
@joeflack4 joeflack4 self-assigned this Jul 11, 2018
@joeflack4 joeflack4 changed the title Template 5 - Utilization of Enketo print mode Template #5 - Enketo template Jul 11, 2018
@joeflack4 joeflack4 removed their assignment Aug 17, 2018
@joeflack4 joeflack4 added P4 Priority: 4/5 (1=High, 5=Low) and removed low priority labels Aug 17, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
issue in development Not yet ready to be worked on. new feature P4 Priority: 4/5 (1=High, 5=Low)
Projects
None yet
Development

No branches or pull requests

1 participant