Select to view content in your preferred language

Connect Version 3.17 inputMask is submitting data when users do not provide values in form. It also overwrites the default value.

638
2
02-23-2023 10:55 AM
Alex-Santos
Frequent Contributor

Hi, I just upgraded to version 3.17 and I'm noticing that inputMasks are entering values matching the mask even when a user does not enter values in the question. This wasn't happening in version 3.16, arg. 

For example, I have an inputMask set to 99:99 \AM - 99:99 PM so users can enter hours of operation - 08:00 AM - 08:00 PM. Well now if users enter nothing, I get  :  AM -  :  PM.

Additionally, I have a default value 'Closed' if user answered previous question as 'Closed.' I am using body::esri:visible in hours of operation to hide the question and not clear out default.

inputMask-overwrite.PNG

Is there a way to fix this so that the attribute is just left blank or it respects default value?

2 Replies
abureaux
MVP Frequent Contributor

I noticed a potential 3.17 issues as well. This is related to the conditional required fields and body::esri::visible.

When a field is hidden by body::esri::visible, it seems to be ignoring conditional required statements.

Everything was working find in 3.16

Found the issue. The logic behind hidden fields and required was the issue. I had a couple fields that were hidden that I forgot about. They had required==yes and appearance==hidden. In 3.16, these would be ignored. This has changed in 3.17.

Seems like 3.17 is going to make a few new challenges.

@Alex-Santos  I would consider using a new calculated field.

  1. Create a new calculate field and name is whatever your current field with the input mask is.
  2. Change your old input mask field's name and make it null.
  3. And add conditional logic to the new calculate field. Something like if(string-length(${field}>5,${field},'')
0 Kudos
Alex-Santos
Frequent Contributor

Hey thanks for the suggestion, but haven't been able to resolve just yet. The 3.17 field app still submits empty input mask values so for now I think I'll remove input masks.

0 Kudos