How to override function from This item is read-only based on its protection policy script include ?

Serj
Tera Contributor

Hi guys, I need to override two functions in script include which is 'This item is read-only based on its protection policy'

how can I resolve it? 

 

 
1 ACCEPTED SOLUTION

Yes you can extend it similar to what I posted.

InteractionFacadeCustom = Class.create();

InteractionFacadeCustom.prototype = Object.extendsObject(InteractionFacade, {

	functionNameYouWantToOverride: function() {
		...
	},

	type: "InteractionFacadeCustom"
});

If my answer helped you in any way, please then mark it as helpful.

Kind regards,
Mark
2020 ServiceNow Community MVP
2020 ServiceNow Developer MVP

---

LinkedIn
Community article list

 

Kind regards,

 

Mark Roethof

Independent ServiceNow Consultant

10x ServiceNow MVP

---

 

~444 Articles, Blogs, Videos, Podcasts, Share projects - Experiences from the field

LinkedIn

View solution in original post

8 REPLIES 8

Yes you can extend that as well and use the new script include in calling the script include.

Yes you can extend it similar to what I posted.

InteractionFacadeCustom = Class.create();

InteractionFacadeCustom.prototype = Object.extendsObject(InteractionFacade, {

	functionNameYouWantToOverride: function() {
		...
	},

	type: "InteractionFacadeCustom"
});

If my answer helped you in any way, please then mark it as helpful.

Kind regards,
Mark
2020 ServiceNow Community MVP
2020 ServiceNow Developer MVP

---

LinkedIn
Community article list

 

Kind regards,

 

Mark Roethof

Independent ServiceNow Consultant

10x ServiceNow MVP

---

 

~444 Articles, Blogs, Videos, Podcasts, Share projects - Experiences from the field

LinkedIn

Hello Mark,

 

If I have to make changes only in a particular part of the function, do I need to write the whole function again in the override script include and then make required changes to it, or is it possible to change only a particular part of the main function in the override script include?

 

Regards,

Ramkrishna Bhat

Hi, what do you think about Scripted Extension Points?

Thanks