How to map subflow to assessment template category in Smart Assessment Engine(GRC)?

anandwakode
Tera Contributor
 
3 REPLIES 3

Community Alums
Not applicable

Hi @anandwakode ,

There is no way OOTB you can map a Subflow toassessment template category unfortunately, However what is possible is to add a action called "Trigger Smart Assessment" as a action from flow :

SandeepDutta_0-1740747953873.png

 

 

jwalk_yota
Tera Expert

Have you been able to figure this out, currently trying to do the same thing for a post assessment action @anandwakode 

Aniket_sen
Tera Contributor

Hi, so I was facing this same issue. I wasn't able to figure out where the mapping exists but I was able to do the post assessment mapping using a workaround. For this solution to work, you need to write an After Update Business Rule in "sn_smart_asmt_instance" table. The filter condition would be Assessment template is <your template name> AND State Changes to Completed. The script inside the Business Rule would look something like this: 

(function executeRule(current, previous /*null when async*/ ) {
	var asmtResult = new GlideRecord("sn_smart_asmt_question_instance"); // Assessment question table, this can be found as a related list in sn_smart_asmt_instance
    asmtResult.addEncodedQuery("assessment_instance=" + current.sys_id + "^assessment_question=a3b60fed8dda5610f877e541e5103811"); // assessment question whose result needs mapping
    asmtResult.query();
    if (asmtResult.next()) {
		
		//Perform your logic inside this if statement, the result of the question would sit inside fields (in the sn_smart_asmt_question_instance table) like Reference response if its a list or reference field, Text response if its a string field, selected Response options if its a choice field
       
}

})(current, previous);

 Refer to the comments inside the Business to understand how the responses to the questions are stored and how you can use them.