Condition Builder in a custom table.

Uncle Rob
Kilo Patron

I watched the Gamification of IT webinar the other day (if you didn't, be sure to watch the recording!) and I want to build my own version.

What really caught my eye was that they had a Condition Builder on a custom table. I had no idea such a thing were possible! So I fired up demo, built a custom table, and started adding the requisite field types. As far as I can tell, I've added all the fields necessary. One field is of a type "table_name" and the other is of type "condition". I figured this would be enough, placed both on the form, and tested.

I keep getting "please select a table" error, even though I have a table_name field on the form. Is there some other sorcery that I'm missing? I can't find anything about this in the wiki.

2 REPLIES 2

Jace Benson
Mega Sage

Anything you see in Service-now can be recreated. First find where you see that functionality and then investigate.
This same condition builder is on the UI Policy form.
In this short video I show how to recreate the condition filter. The condition filter returns the condition as an encoded string.

Hopefully this answers your questions.

http://www.youtube.com/watch?v=uHrO9ycABhs


abhigupta
Kilo Contributor

Hi,

You are seeing this error since your condition field is independent of the table_name field. It is very simple to create dependency between these two field. Go to dictionary of the condition field attribute, there you will find dependent field. Just write the name of your table_name field over there and its done. After this all the fields will be visible from the selected table.

Thanks
Abhishek Gupta