how to assign a user to default assigned_to in SC-Task

tGhadage
Tera Contributor

Hi Guys,

 

How to default assign a particular user as default assigned to in SC_TASK.

 

Thank!! 

8 REPLIES 8

Sid_Takali
Kilo Patron
Kilo Patron

Hi @tGhadage  Can you rephrase your question? 

Hi @Sid_Takali ,

 actually what I want to implement is if the SC_TASK with the description ( For Eg: Testing please ignore ) then it should get assigned to user name Abel Tuter.

 

Thanks!!

Hi @tGhadage  I have tested the below script on my PDI on Incident form. 

1. Create before insert Business Rule on sc_task table.

2. Use below code 

(function executeRule(current, previous /*null when async*/ ) {

    if (current.short_description.indexOf("Testing please ignore") > -1) {
        current.assignment_group = "add sys_id of assignment group";
        current.assigned_to = "add sys_is of assigned to user";
    }

})(current, previous);

 

Please mark my reply Correct/Helpful

Regards,

Sid

 

here also we need to check if the sc_task is open or close if the task is open (Newly created) then only we need to assign the task to Abel Tuter.