Knowledge Result Widget

djordjeg
Giga Contributor

I've  cloned Knowledge Result widget, and when I placed cloned instance on the Service portal page without any modifications, I started getting JavaScript error:  "Server JavaScript error "KBPortalService" is not defined." and it started prompting me to login into the portal although I am already logged in. It is exactly the same as the original.  

Any idea why is this happening?

Thank you,

Goran 

1 ACCEPTED SOLUTION

Hi Goran,

 

It is read only script include. We cannot modify it . Instead create a new custom script include and add the contents of this script include and in your custom widget add the custom script include. Please note , that the script include is calling KBPortalServiceImpl. 

 

Regards,

Swathi

View solution in original post

7 REPLIES 7

Andrej4
Kilo Explorer

@Swathi @djordjeg 

Hello guys.

I am getting the same error KBPortalService is not defined

afther cloning the Knowledge Featured Articles.

 

I go in  the background in Scripts Includes and there i am making new custom script

with same code from the KBPortalService but avalable to all aplication scopes.

I named this custom script CopyOfKBPortalService.

After that in the cloned widget from the Knowledge Featured Articles

i am using var kbService = new CopyOfKBPortalService();

and after that i am getting again the same error.

 

Please help

Thanks in advance

 

Then in the Knowledge 

Please help

Thanks in advance

Amanda Oliveira
Tera Contributor
Hello guys!

To solve this problem when we clone a KB widget, we need to go directly to:

Script Include > search for: KBPortalService > Right click on the record header > insert And so, it will be added to Global application. If I helped you leave your Like!!!
????

find_real_file.png

Hi @Amanda Oliveira now after clicking insert and adding itto global application it says "Knowledge record not found"