Checklist : OnChange client script

Community Alums
Not applicable

Hello , 

 

We need to Add a "Select All" option above the checklist that selects all the checkboxes. When this is selected, have a pop-up that says "By selecting all, you confirm you have gone over each item on the checklist."

For the above requirement, how to configure a client script on the checklist present on sc_task?

6 REPLIES 6

Community Alums
Not applicable

Hello @Allen Andreas ,

We need to access the checklist item in the above script. If the checklist item "Select all" is selected then we need to show a popup. Is there any means to access a checklist item?
We have created a checklist template as follow:

SrushtiJadhav_0-1712830724700.png

Checklist on sc_task:

SrushtiJadhav_1-1712830841015.png

 

Community Alums
Not applicable

Hi @Community Alums ,

I checked your problem in my PDI and I got answer I hope this will work for you!

 

I created onChange client script which works on "select all" variable.

 

 

alert("newValue = " + newValue);
    if (newValue == 'true') {
        alert('By selecting all, you confirm you have gone over each item on the checklist.');
        g_form.setValue('st_option', true);
        g_form.setValue('nd_option', true);
    }if(newValue == 'false') {
        g_form.setValue('st_option', false);
        g_form.setValue('nd_option', false);
    }

 

Result : 

SarthakKashya2_0-1712832806231.png

Please mark helpful and correct if it works for you 

 

Thanks and Regards 

Sarthak 

 

Community Alums
Not applicable

Hi @Community Alums ,

We cannot fetch checklist backend values as  checklist items are not variables. After all, we created a checklist in the checklist_template table.

Community Alums
Not applicable

@Community Alums , 

Can you send me the template that you added in the image, I'll try it in my PDI

 

Thanks 

Sarthak