Notification

Community Alums
Not applicable

Hello Team,

 

I have requirement on change table  if outage is not der  then we need to send the notification of affected Cis and Affected Services to the owned by , managed by,  and Approval Group .

 

Please advise me how we can do this step by step .

 

Thank you. 

4 REPLIES 4

Amit Gujarathi
Giga Sage
Giga Sage

HI @Community Alums ,
I trust you are doing great.

  1. Navigate to System Definition > Business Rules.
  2. Click on New to create a new Business Rule.
  3. Fill in the necessary fields:
    • Name: "Send Notification for Outage"
    • Table: "Change Request [change_request]"
    • When: "After"
    • Insert: Unchecked
    • Update: Checked

Step 2: Define the Condition

In the "Advanced" tab of the Business Rule, you'll need to write a script to check the condition of the outage and gather the necessary details.

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

    // Check if outage is not there
    if (!current.outage) { // Assuming 'outage' is a field on the change_request table

        // Send notification
        gs.eventQueue('custom.change.no.outage', current, current.owned_by, current.managed_by);
    }

})(current, previous);

Was this answer helpful?


Please consider marking it correct or helpful.


Your feedback helps us improve!


Thank you!


Regards,


Amit Gujrathi



Community Alums
Not applicable

@Amit Gujarathi  custom.chnage.no.outage this we need to create event right , But event will generate on which table ?

Amit Gujarathi
Giga Sage
Giga Sage

Change request


Was this answer helpful?


Please consider marking it correct or helpful.


Your feedback helps us improve!


Thank you!


Regards,


Amit Gujrathi



Community Alums
Not applicable

Hello @Amit Gujarathi  Code is not working  and it was not triggering the notification as expected