How to get RITM AND SCTASK for a record producer once it submitted?

jothi3
Tera Contributor

How to trigger sc_task and ritm for a record producer with incident table

based on the requirement I need to trigger sc_task or incident record.

1 ACCEPTED SOLUTION

I am assuming this select option is on your record producer right?

View solution in original post

11 REPLIES 11

Hi,

You can try something like this in your record producer script :

 

if(producer.select_option=='1'){
    current.short_desc='test12';
    
}else if(producer.select_option=='2')
    
    {
        current.setAbortAction(true);
        var gr=new GlideRecord('sc_task');
        gr.initialize();
        gr.short_desc='test';
        gr.insert();
        
    }

Palak Gupta
Tera Guru
Tera Guru

Hi there!

Record Producer creates record in the table which was selected while creating Record Producer.

Can you explain what exactly are the requirements?

Regards,

Palak

Musab Rasheed
Tera Sage
Tera Sage

Hello,

RP doesn't create RITM or SCTASK it creates task based records like INC etc so if you want to create RITM or SCTASK please write BR or control this with Workflow or Flow designer.

Mark my answer as correct if that helps

Regards

Please hit like and mark my response as correct if that helps
Regards,
Musab

Ankur Bawiskar
Tera Patron
Tera Patron

Hi,

Your requirements seems to be using record producer instead of catalog item

Why not have catalog item?

Regards
Ankur

Regards,
Ankur
✨ Certified Technical Architect  ||  ✨ 9x ServiceNow MVP  ||  ✨ ServiceNow Community Leader

Ian Mildon
Tera Guru

Would this be using a pre-existing Catalog Item to generate the REC/RITM/SCTASK?

Thinking that you could add a script query to the record Producer that if "option b" is selected that you redirect to the Catalog Item.