- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎11-17-2019 05:17 AM
I wanted to remove the standard option from the select article template under knowledge category .
Please help me .!!
Solved! Go to Solution.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-10-2020 10:26 AM
Hi
Within the ArticleTemplateUtil script include, you can add a method that overrides the getArticleTemplatesForKnowledgeBase method in the ArticleTemplateUtilSNC script.
Within the ArticleTemplateUtil script, the code is as follows:
var ArticleTemplateUtil = Class.create();
ArticleTemplateUtil.prototype = Object.extendsObject(ArticleTemplateUtilSNC,{
// script override to disable Standard KB template
getArticleTemplatesForKnowledgeBase: function(kbId, addNames) {
var gr = new GlideRecord('kb_template_m2m_knowledge_base');
gr.addQuery('kb_knowledge_base',kbId);
gr.query();
var templates = {};
if(!addNames)
templates['kb_knowledge'] = true;
if(!gr.hasNext()){
var template = new GlideRecord('kb_article_template');
template.addActiveQuery();
template.query();
while(template.next()){
if(addNames)
templates[template.child_table] = template.getDisplayValue('article_template');
else
templates[template.child_table] = true;
}
return templates;
}
else {
while(gr.next()){
if(gr.kb_article_template.active){
if(addNames)
templates[gr.kb_article_template.child_table] = gr.kb_article_template.getDisplayValue();
else
templates[gr.kb_article_template.child_table] = true;
}
}
}
return templates;
},
// --
type: 'ArticleTemplateUtil'
});
Hopefully this helps.
Regards,
Jay
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎11-17-2019 06:37 AM
go to Knowledge > Administration > Article Templates. and set the active to false for standard
Mark correct if this helps

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎12-18-2019 05:45 AM
Standard isn't an option there. You could do this in the old view by editing the interceptor but can't in NY+
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎11-17-2019 07:15 PM
Hi,
Deactivating knowledge article templates :
You cannot delete an article template because article templates have an associated child table. Deleting a template would also require deleting the child table. Due to the limitations on dropping tables, article templates and template columns are explicitly made non-deletable. Instead you can disable the Knowledge Article Templates feature by clearing the Active check box on the Article Template form.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-10-2020 10:26 AM
Hi
Within the ArticleTemplateUtil script include, you can add a method that overrides the getArticleTemplatesForKnowledgeBase method in the ArticleTemplateUtilSNC script.
Within the ArticleTemplateUtil script, the code is as follows:
var ArticleTemplateUtil = Class.create();
ArticleTemplateUtil.prototype = Object.extendsObject(ArticleTemplateUtilSNC,{
// script override to disable Standard KB template
getArticleTemplatesForKnowledgeBase: function(kbId, addNames) {
var gr = new GlideRecord('kb_template_m2m_knowledge_base');
gr.addQuery('kb_knowledge_base',kbId);
gr.query();
var templates = {};
if(!addNames)
templates['kb_knowledge'] = true;
if(!gr.hasNext()){
var template = new GlideRecord('kb_article_template');
template.addActiveQuery();
template.query();
while(template.next()){
if(addNames)
templates[template.child_table] = template.getDisplayValue('article_template');
else
templates[template.child_table] = true;
}
return templates;
}
else {
while(gr.next()){
if(gr.kb_article_template.active){
if(addNames)
templates[gr.kb_article_template.child_table] = gr.kb_article_template.getDisplayValue();
else
templates[gr.kb_article_template.child_table] = true;
}
}
}
return templates;
},
// --
type: 'ArticleTemplateUtil'
});
Hopefully this helps.
Regards,
Jay