Home Analyst Portal

Setting fields to be conditionally required in the portal

Josh_ReedJosh_Reed Customer IT Monkey ✭

Hello!

I am trying to see if there is a way that when the "Escalated" box is checked on an IR, I can set it so that it makes another field required. I have went in and extended the IR class to include an "Escalation Reason" field and have added that extension to our Incident.js so it shows up on the portal. However, I cannot seem to find a way to make it so that if the "Escalated" box is checked, it makes the "Escalation Reason" field required. I feel like this would have to be done in the Custom.js file and has to do with the Kendo UI in some way. Has anyone ran into this before?

Any help is greatly appreciated!

Answers

  • Justin_WorkmanJustin_Workman Cireson Support Super IT Monkey ✭✭✭✭✭

    @Josh_Reed - I just answered a similar question over here this week. I have tweaked that code a bit to accomplish your purpose. You will just need to set the fieldToShowOrHide at the top of the code. Make sure you set it to the field name that you used in the Incident.js.

  • Josh_ReedJosh_Reed Customer IT Monkey ✭

    As always, thanks Justin! I pulled the code down, set the variable at the top to the field to the same as is defined in the Incident.js, and popped it into our custom.js. Unfortunately, it doesn't seem to be doing anything. Is there anything special other than defining the variable at the top that needs to be done?

  • Justin_WorkmanJustin_Workman Cireson Support Super IT Monkey ✭✭✭✭✭

    @Josh_Reed - Did you load it in with loadScript?

  • Josh_ReedJosh_Reed Customer IT Monkey ✭

    @Justin_Workman - No, I added it directly to our custom.js. I am not familiar with loadscript. I checked the other article, but I am not understanding it completely. Should I be using loadScript instead?

Sign In or Register to comment.