Service portal widget error - Server JavaScript error Cannot read property "view" from undefined

Amit Kumar21
Tera Contributor

I have got this error -  'Server JavaScript error Cannot read property "view" from undefined' after changes on a widget and loading the form. 

Any idea why this is coming?

error screenshot:

AmitKumar21_0-1666161198604.png

 

Code screenshots:

AmitKumar21_1-1666161229522.png

 

AmitKumar21_2-1666161257707.pngAmitKumar21_3-1666161286753.pngAmitKumar21_4-1666161311313.png

 

1 ACCEPTED SOLUTION

Dan Ostler
Tera Guru

This is being caused by your server script on line 10. The input object is the data object received from the client controller. If you adjust the script to something like this that error should go away:

 

 

 

if (input) {
   var localInput = input;

 

 

View solution in original post

1 REPLY 1

Dan Ostler
Tera Guru

This is being caused by your server script on line 10. The input object is the data object received from the client controller. If you adjust the script to something like this that error should go away:

 

 

 

if (input) {
   var localInput = input;