fix: add notiftype
This commit is contained in:
@@ -247,6 +247,25 @@ export class NotificationsService {
|
||||
}
|
||||
return this.createNotification({ title: NotificationMessage.CREATE_TICKET, type: NotifType.CREATE_TICKET, message, recipientId });
|
||||
}
|
||||
//************************ */
|
||||
//TODO: fix this cause this for admin
|
||||
async createAssignTicketNotificationForAdmin(recipientId: string, data: ITicketNotificationData, queryRunner: QueryRunner) {
|
||||
const message = NotificationMessage.ASSIGN_TICKET_MESSAGE.replace("[ticketId]", data.ticketId);
|
||||
//sent notification based on the userSettings
|
||||
// const { isActive } = await this.userSettingsService.getUserNotificationSettingWithType(
|
||||
// NotifType.ANSWER_TICKET,
|
||||
// recipientId,
|
||||
// queryRunner,
|
||||
// );
|
||||
// if (isActive) {
|
||||
await this.smsService.sendTicketAssignedToAdminSms(data.userPhone, data.ticketId, data.subject, data.user!);
|
||||
//send email too
|
||||
// }
|
||||
return this.createNotification(
|
||||
{ title: NotificationMessage.ASSIGN_TICKET, type: NotifType.ASSIGN_TICKET, message, recipientId },
|
||||
queryRunner,
|
||||
);
|
||||
}
|
||||
|
||||
//************************ */
|
||||
|
||||
|
||||
Reference in New Issue
Block a user