What is the purpose of the Type drop-down field on the Policy form?

tsylte
Tera Contributor

Can anyone share the purpose or source of the Policy Type field? It is a drop down, and I'd like to understand how the values are intended to be used. 

find_real_file.png

1 ACCEPTED SOLUTION

Balaji Jagannat
Kilo Guru

It refer to the type of document and the data is coming from Choice (i.e GRC Choice) table with the following filter [new sn_grc.GRCChoiceUtils().getGRCChoices('type', current.sys_class_name)]

View solution in original post

10 REPLIES 10

Jan Spurlin
ServiceNow Employee
ServiceNow Employee

There is no workflow associated with these values, however I believe that these were selected to be in the baseline because they match with the values used by UCF. So, if you have a UCF integration you will see these values.

Jan

just re-read , sorry! 

 

however they are populated in baseline, with or without UCF.

 

The workflow is when publishing to KB 

Agreed - you just might not want to remove them if you are using the UCF integration.  My bet is that the UCF integration would still populate using these values - unless you changed the integration code. Just something else to think about!

Community Alums
Not applicable

All responses mentioned below are right but to give you a bit more detail, probably would be easier to get there.

Policies have a type, such as a policy, procedure, standard, plan, checklist, framework, or template. This is mentioned in the official documentation (https://docs.servicenow.com/bundle/kingston-governance-risk-compliance/page/product/grc-policy-and-c...).

About field "Type":

  • Useful for reporting purposes where you can group by Type.
  • The values have origin on the table "sn_grc_choices" where category = 'Type' as mentioned by Balaj.
  • They match to UCF common controls categories as Jan mentioned.
  • If a record a Policy (sn_compliance_policy) changes their state to "Published" e.g. is published, a KB article will be generated based on the field Article Template (business rule "Publish to KB"). This has been mentioned by Phil.

Policy:

find_real_file.png

Article:

find_real_file.png

 

Technically speaking, if you follow the business rule "Publish to KB", you can notice the type will be assigned to the category of the KB article as you can see in the following code.

// script include GRCKnowledgeBase (Base functionality for publishing policies/engagements as KB articles)
	_getPolicyKBCategory: function(targetRecord, kb) {
		if (targetRecord.type.nil())
				return null;
			
		var category = new GlideRecord('kb_category');
		var choice = new GlideRecord('sn_grc_choice');
		
		if (choice.get(targetRecord.type)) {
			category.addQuery('parent_table', 'kb_knowledge_base');
			category.addQuery('parent_id', kb.sys_id);
			category.addQuery('value', choice.name);
			category.setLimit(1);
			category.query();
			if (category.next())
				return category.sys_id + '';
		}

		category = new GlideRecord('kb_category');
		category.label = choice.label;
		category.value = choice.name;
		category.parent_table = 'kb_knowledge_base';
		category.parent_id = kb.sys_id;
		return category.insert();
	},

Hopefully this gives you a bit more detail.

Raf

tsylte
Tera Contributor

Thank you all very much for the detailed answers! All very helpful, appreciate it!