On change client script not to run once template applied
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎04-18-2025 11:19 AM
Hi,
I created on change client script to populate assignment group when subcategory changes in interaction table.but when i applied template then also on change client script overriding.
if (isTemplate) {
return;
} else {
code;
}
Please guide here to not to run when template is applied and when subacategory manually changes then on change client script runs.
1 REPLY 1
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎04-18-2025 11:41 PM
Hi @FareedaS
Try below script.
The assignment group value remains unchanged when the subcategory value is preset by the template.
function onChange(control, oldValue, newValue, isLoading, isTemplate) {
if (isLoading || newValue === '') {
return;
}
if (!isTemplate) {
g_form.setValue('assignment_group', '<GROUP SYS ID>');
}
}
Regards,
Siva