Ash33
Tera Expert

I configured this solution and it has worked for me.

Step 1: Create an event in the sysevent_register table.

for eg;

Name = knowledge.retire.rejected;
Table = kb_knowledge

Step 2:
After Update BR on kb_knowledge table
Script:

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

    // Only run when state changes from pending_retirement to published
    if (previous.workflow_state == 'pending_retirement' &&
        current.workflow_state == 'published') {
var authorSysId = current.author.toString();
gs.eventQueue('kb.retirement.rejected', current, authorSysId);
    }
})(current, previous);

Step 3: Create notification on kb_knowledge table
When to send: event is fire
Event name: select event created in step 1
Who will receive:
Event parm 1 contains recipient;
 

View solution in original post