When the user assigned to a case change, we need to inform the person who is the new assignee to that case.
Notification type = case_assignee_updated
The JSON payload:
{"notification_type": "case_assignee_updated"
, "bz_source_table": "ut_notification_case_assignee"
, "notification_id": "ut_notification_case_assignee-xxx"
, "created_datetime" : "the timestamp when this was done ex: 2018-06-12 09:21:08"
, "unit_id" : "unit_id (the BZ id for the unit)"
, "case_id" : "case_id (the BZ case id)"
, "case_title" : "case_title (the title of the case)"
, "invitor_user_id" : "0 (this is a placeholder as we want to record who assigned this user to this case at a later stage)"
, "assignee_user_id" : "invitee_user_id (the BZ user id for the invited user)"}
What we need to do:
Send an email notification to the "assignee_user_id" to inform him/her that he/she has been assigned to this case.
Unsubscribe:
- We need to allow the user to unsubscribe from this type of notification (
case_assignee_updated
) if he/she chooses to.
- When a user has decided to unsubscribe, we should NOT send this user more notification if the notification type is
case_assignee_updated