Skip to main content
Nintex Community Menu Bar
Question

How can I make a field conditionally required in bonzai version?

  • July 9, 2024
  • 8 replies
  • 26 views

Forum|alt.badge.img+4

Hi I have 3 fields. I need to require at least one of them having a value. How should I do this? I tried the field renderer, but that made the field read only?

This topic has been closed for replies.

8 replies

Forum|alt.badge.img+20

Conditionally render two fields. One required and one not required.


Forum|alt.badge.img+4

I want to show all 3 fields at all times though.
Field 1: not required.
Field 2: required. render condition: field 2 is null
Field 3: not required. render condition: field 1 and 2 is null?

What would be the right set up? Thanks!



Forum|alt.badge.img+4

Can I use action on Model to achieve this? I’m new to Skuid. Can you provide a snippet that does that for 2 fields maybe for demo?


Forum|alt.badge.img+20

Sorry. I’ve got to pass the baton. My own work is pressing. :S


Forum|alt.badge.img+18

I haven’t tested this, but you could try enable conditions on fields 2 and 3 instead of render conditions. That way they would be visible, but not editable unless the condition was met.


Forum|alt.badge.img+4

Thanks! I will actually need to have them editable at all times. So I did this by running validations in javascript. The element.html() was causing the trouble.


Forum|alt.badge.img

Hi J!  Did you ever implement your solution in JS and if so, would mind sharing it?  Thanks!


Forum|alt.badge.img

Hey Pat, very clever fix. Just create a duplicate set of fields with one set being set as required in Skuid and the others not and then set your rendering conditions accordingly. I had the same issue with just needing 1 field required but still render the rest of the fields as optional.