Manage forms and submissions by my own web application

Hello

I need to build my own web application to show forms and their related submissions by reading from the Aggregate Database.

I have many issues to work around:

  • Showing <label = value> of each question on my web page, I don't find where the labels are stored on the Database ?
  • How to parse and read each submission to show it in lisible way on my web page ?

thx

aymenelj,

Take a look at my website https://accounts.gocollectinfo.com base on odk. This is built on php and mysql with java and html5. Logon using username: demo@gocollectinfo.com password: 1234567

2 Likes

thx clickuinternet
it's a bad link, i got "502 Bad Gateway"

It's not a good idea to pull data directly from the database because those structures can change. Why not use the existing APIs to pull data from Aggregate into an application that you control?

Or even at a high-level, why build your own application when you can use and customize Aggregate (or Ona or Kobo or ELMO)?

It should work now. Sorry, there was a scheduled maintenance at that time

Hi Yaw,
First, I want to thank you andthe community for odk. Its a beautiful app that helps alot of people.
And yes its true that the structure of the database changes but I already have addressed this problem and my app adapts automatically to the changes without interventions.

thx Yaw for your replay

what do you mean by existing APIs ? wich ones? I thing maybe by that I still need to interroge the database directly.. what do you thing?
my need is that I have people (in many levels) who need to contol the submissions and give remarks for the collectors on each submission and even every form element. (collectors use GeoODK to upload submissions)

for updating Aggregate, it's writen by GWT wich I'm not familiar with.

thank you very much for help

best regards

See https://docs.opendatakit.org/aggregate-data-access for how to get data out of Aggregate. And if you really want to touch the DB, https://github.com/opendatakit/opendatakit/wiki/Aggregate-Database-Structure is the document for that.

If the need is to comment on submissions, my approach is always to decouple those things. That is, take the data from Aggregate, use the methods described above to send into another system that you control and let people comment on that system.

Anyway, that's about as much guidance as I can offer. Good luck!

1 Like

Oh, and if it's Windows support you need, I think most of those servers can be made to run on Windows. Or, do the install in a virtual machine.

thank you very much Mr Yaw for your answers, I try doing as you said.

Hello Mr Yaw

I begun to work with Aggregate API, it's what I really need to have clean work.
Now I'm faced to a challenge to show the submissions to the user, you know that data of submissions returned by call to view/downloadSubmission are composed of xml tags and values, tags represent the names of fileds of the origin XForms items.
I need to show the submission data by their labels (example: "Name" instead of "g_name_charged_person") and labels instead of vaues in select tag ...
I thought to call the original xml: http://localhost/ODKAggregate/www/formXml?formId=form_id&readable=true and then parse the returned XML to find the labels , .. but may be there is a cleaner way to do it
also I thought maybe there is another API to use to have labels on aggreagte by giving related items names ...

can you give advice, please ?