roam-qgis / Roam

Simple data collection built using QGIS.
http://roam-docs.readthedocs.org/en/latest/
GNU General Public License v2.0
166 stars 60 forks source link

Set value and Show Actions do not work with the same field combos #460

Open she-weeds opened 4 years ago

she-weeds commented 4 years ago

I have a multiselect option box field, and a text field (both string datatype in shapefile) that is set to be hidden by default. The text field is set via Actions so that it shows when the option box field is updated and includes the option 'Manual' (@value ilike '%Manual')

However, I also want to set an Action such that when the option box field is updated, the option box value is also carried across to the text box field. (doesn't matter if it overwrites what's already in there)

Right now I can only seem to do one or the other. I can either get the Manual button to show or hide the text field, without setting any values....

hidden1

...by putting the Show action above the Set value action in the Actions tab.... (so Show works but Set value doesn't)

hidden1_set

...or I can get the option row values to show in the text field, but can't use Manual to hide/unhide the text field.

hidden2

...by putting the Set value action above the Show action in the Actions tab (so Set value works but Show doesn't) hidden2_set

I have tried every combination of: having the text field not be hidden by default, using 'Hide' and 'Show' actions, having 2x 'Set value' actions (one before the 'Show' action and one after), tested in ROAM 2.7.1 and ROAM 3 beta 3...

Is this the expected behaviour? Wondering how to set the value in Python if it can't be done via the GUI.