onSubmit Catalog Client Script not working on Portal

nirwan_ritik
Tera Contributor

I have below code in onSubmit client script:

 

var flag = 0;

 

if (something is true) {

    flag = (flag + 1);

}

 

if (flag > 0){

    return false;

} else {

    return true;

}

 

This is working fine in Native view but not on Portal. Kindly help 🙂

 

1 ACCEPTED SOLUTION

AshishKM
Kilo Patron
Kilo Patron

Hi @nirwan_ritik ,

Please check the UI Type selection, it should be "All". 

 

AshishKMishra_0-1704287038676.png

 

-Thanks,

AshishKMishra

 

 


Please mark this response as correct and helpful if it helps you can mark more that one reply as accepted solution

View solution in original post

7 REPLIES 7

Anurag Tripathi
Mega Patron
Mega Patron

Hi,

Can you check the ui type field on the Catalog client script. It should be set to All.

AnuragTripathi_0-1704287023812.png

 

-Anurag

Hi, 

UI Type is selected to All.

 

Thanks

Add alert to see if the script is even running or not. 

Remove the if conditiona nd just add alert('test')l in the script

-Anurag

AshishKM
Kilo Patron
Kilo Patron

Hi @nirwan_ritik ,

Please check the UI Type selection, it should be "All". 

 

AshishKMishra_0-1704287038676.png

 

-Thanks,

AshishKMishra

 

 


Please mark this response as correct and helpful if it helps you can mark more that one reply as accepted solution