Add Comments in the notifcations

avinashdubey103
Tera Guru

Hi i have created a noitification on request table

i want to add approver comments and name of rejector  in the template but it is not working :


Dear   ${u_requested_for},

Your request ${number} for new GenAI software was declined.

Software: ${mail_script:amd.genai.model.name} 

Reason: ${comments}

For more information, please contact  ${approver}
.

 

Regards,

 

 

3 REPLIES 3

Prathamesh G
Kilo Sage
Kilo Sage

Hello @avinashdubey103 ,

 

Can you share your code for the email that you are referring in your email notification - 'amd.genai.model.name'?

 

Thank You.

that is  prebuild code , no necessary for this 

LuzAcosta
Tera Contributor

 you need to ensure that the variables you're referencing are correctly defined and available within the context of the notification script.

Here's an example of how you might adjust your template to include the approver comments and rejector's name:

 

Dear ${u_requested_for},

Your request ${number} for new  software was declined.

Software: ${mail_script:amd.genai.model.name}

Reason for rejection: ${comments}

Approver comments: ${comments.approver_comments}

Rejected by: ${comments.rejector_name}

For more information, please contact ${approver}.

>> ${comments.approver_comments} and ${comments.rejector_name}: Replace them with the correct field names that store this information.

 

Check the field names, script logic, and configuration to ensure that the correct data is being fetched and populated in the notification template. Adjust the variable names or script logic accordingly to ensure accurate data retrieval and display in the notification.