I have a use case where I need to generate patient identifier following certain sequence(need to take a location attribute and concatenation with a random string) during registration(am using xform for capturing registration details). What is needed is to add a button after the identifier input filed, which when clicked, the input field is populated. My questions follows
-Can a button be added on a form to effect that in xform?
-Is it possible to call a service method that would fetch location attribute value?
-Can I use Idgen module for that purpose?(I know doing that from a java code, but how can that be called on an xform?)
If there is an already existing solution to this please point me to it, or if you can advice a way of accomplishing that. I would easily do that on a fragment and an HTML form, the challenge comes in when dealing with xform.