Is there any way to check all mandatory fields on a change

gosp
Kilo Contributor

Hi, I try to find a way to check if all mandatory fields in the change are filled in.

I try the g-form.getMissingFields(), but it seems that this command only check fields in the form and not in the sections in the form.

Is there any other way to check all mandatory fields in a change, include fields in the sections of the form.

Thanks in advanced,

Patrick

3 REPLIES 3

paulblair
Kilo Explorer

Hi Patrick,



When you want this "check" to occur. If you attempt to save or submit the Change before all the required fields are filled in you should receive an error message letting you know which required fields still need to be filled in.



-Paul


CloudSherpas


gosp
Kilo Contributor

Hi Paul, Tanks for the reply.


But I want to check it in a script so I can change the status e.g. to "next phase" automatically.





Ah ok. I have something similar that used a UI action with a Server Side


and Client Side call. Then set onclick to something


like makeFieldMandatory() or checkFieldMandatory() after that you can set


your condition to check for an empty field and then I would do a script


something to the effect of




g_form.setMandatory('change_plan', false);


g_form.setMandatory('backout_plan', True);



This isn't an exact script but something to the effect of this should get


you to what your after.



On Wed, Jun 24, 2015 at 8:22 AM, Patrick Gosseye <