Custom scripted form
Hello,
We need to use a custom form that has more features than just what the default forms support. We solve that on Desktop by using a custom ui file and a python file that can add some extra functionality
Is there any way to do that on QField? I imagine it doesn't support running custom python code, but is there any scripting language I could use? Any plugin support?
My last alternative would be to fork the repository and make a custom build with our custom forms
Cheers, Abel Toy
There is an idea to integrate qml/js based forms as a replacement for ui/py based forms. So far we are still looking for a project where this is required, that's why we have nothing like that implemented yet. Improvements in this area would be very welcome.
Abel are working with me in a project. We have some hours (20-30 aprox.) to improve QField, not much, but Abel can spent this hours to improve these custom forms. We've develop 2 custom form (ui/py) for QGIS and we want to see the same forms in QField.
Can you help us to continue this work?
Thanks in advance.
See you in Nodebo!
Great that you have some time to work on QField.
To make this work generic, the main questions are how to deploy those files, how configuration happens and what exactly the requirements are (Is it just required to make dynamic changes to widgets or are there other API calls required).
This kind of functionality will be really good to have in QField.
Booking to Nodebo soon, looking forward to seeing you there :)
Any update on this point ? Running custom scripts would be super usefull...
Not yet. But I agree it would be nice :slightly_smiling_face:
The enhancement request has not been done, but dropping a note to inspire others: feature form's QML widgets can do wonder on that front. We recently used QML widgets to provide a live "board" buses arrival times attached to point features and it worked wonders.
I'm sure that work from each one of you should be shared to the community to inspire users even more ! 😉
For those interested in the arrival times board I mentioned above, it looks like this:
The QGIS project itself can be downloaded here (https://github.com/opengisch/qfield.org/blob/main/conferences-projects/uc2025.zip). The project showcases quite a few cool functionalities, including QML widgets embedded within feature forms as well as QField project plugins.
For the QML widget, the script is available through the 'stops' vector layer properties dialog's attribute form panel. From there, you can double click on the 'Departures board' item in the feature form's drag and drop list: