Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions Core/Resgrid.Config/ChatConfig.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,11 @@ public static class ChatConfig
public static string NovuSecretKey = "";

public static string NovuUnitFcmProviderId = "";
public static string NovuUnitApnsProviderId = "";
public static string NovuResponderFcmProviderId = "";
public static string NovuDispatchUnitWorkflowId = "unit-dispatch";
public static string NovuDispatchUserWorkflowId = "user-dispatch";
public static string NovuMessageUserWorkflowId = "user-message";
public static string NovuNotificationUserWorkflowId = "user-notification";
}
}
1 change: 1 addition & 0 deletions Core/Resgrid.Model/Messages/StandardPushMessage.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,6 @@ public class StandardPushMessage
public string Title { get; set; }
public string SubTitle { get; set; }
public string Id { get; set; }
public string DepartmentCode { get; set; }
}
}
21 changes: 11 additions & 10 deletions Core/Resgrid.Model/Platforms.cs
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,16 @@
{
public enum Platforms
{
WindowsPhone7 = 0,
iPhone = 1,
iPad = 2,
Android = 3,
None = 0,
iOS = 1,
Android = 2,
Web = 3,
Windows8 = 4,
WindowsPhone8 = 5,
Blackberry = 6,
UnitIOS = 7,
UnitAndroid = 8,
UnitWin = 9
//Windows8 = 4,
//WindowsPhone8 = 5,
//Blackberry = 6,
//UnitIOS = 7,
//UnitAndroid = 8,
//UnitWin = 9
Comment on lines +5 to +15
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue

Breaking enum value changes will corrupt persisted platform mappings and conflict with hard-coded checks

Previous code (and likely persisted DB values) use 1=iPad, 2=iPhone, 3=Android, 4=Windows8. This change sets iOS=1, Android=2, Web=3, which:

  • Mislabels existing devices in the UI (3 now renders as Web).
  • Breaks provider logic using numeric checks (e.g., NotificationProvider treats 3 as Android).

Preserve legacy numeric values and introduce new names without reassigning existing numbers. Optionally re-add legacy members marked [Obsolete] for compatibility.

Apply this diff to restore stable values and keep compatibility:

-        None            = 0,
-        iOS             = 1,
-        Android         = 2,
-        Web             = 3,
-        Windows8        = 4,
-        //Windows8       = 4,
+        None            = 0,
+        // Legacy Apple values retained for compatibility
+        [System.Obsolete("Use iOS (value 2) where possible. This remains for legacy records.")]
+        iPad            = 1,
+        // iOS aligns with former iPhone value (2)
+        iOS             = 2,
+        // Android retains legacy value (3)
+        Android         = 3,
+        Windows8        = 4,
+        // New platform should use an unused value to avoid collisions
+        Web             = 5,
         //WindowsPhone8  = 5,
         //Blackberry     = 6,
         //UnitIOS                = 7,
         //UnitAndroid    = 8,
         //UnitWin                = 9

If changing enum assignments is not feasible now, introduce centralized helpers to interpret legacy ints consistently and update UI/provider code to use them.

📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
None = 0,
iOS = 1,
Android = 2,
Web = 3,
Windows8 = 4,
WindowsPhone8 = 5,
Blackberry = 6,
UnitIOS = 7,
UnitAndroid = 8,
UnitWin = 9
//Windows8 = 4,
//WindowsPhone8 = 5,
//Blackberry = 6,
//UnitIOS = 7,
//UnitAndroid = 8,
//UnitWin = 9
None = 0,
// Legacy Apple values retained for compatibility
[System.Obsolete("Use iOS (value 2) where possible. This remains for legacy records.")]
iPad = 1,
// iOS aligns with former iPhone value (2)
iOS = 2,
// Android retains legacy value (3)
Android = 3,
Windows8 = 4,
// New platform should use an unused value to avoid collisions
Web = 5,
//WindowsPhone8 = 5,
//Blackberry = 6,
//UnitIOS = 7,
//UnitAndroid = 8,
//UnitWin = 9
🤖 Prompt for AI Agents
In Core/Resgrid.Model/Platforms.cs around lines 5 to 15, the enum numeric
assignments were changed which will corrupt persisted platform mappings and
break any numeric checks; restore the original numeric values for legacy members
(e.g., ensure 1=iPad/iOS legacy mapping, 2=iPhone/Android legacy mapping,
3=Android or previous legacy meaning, 4=Windows8) and reintroduce any removed
legacy members as distinct enum entries annotated with [Obsolete] pointing to
the new names so existing DB values and hard-coded numeric checks continue to
work; alternatively, if you cannot change enum values now, add a central
conversion helper that maps persisted ints to the new enum names and update
UI/provider code to call that helper everywhere instead of relying on raw
numeric comparisons.

}
}
}
81 changes: 81 additions & 0 deletions Core/Resgrid.Model/Providers/Models/INovuProvider.cs
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,96 @@

namespace Resgrid.Model.Providers;

/// <summary>
/// Defines operations for managing Novu notification subscribers and sending notifications.
/// </summary>
public interface INovuProvider
{
/// <summary>
/// Creates a Novu subscriber for a user.
/// </summary>
/// <param name="userId">The unique identifier of the user.</param>
/// <param name="code">The Novu integration code or API key.</param>
/// <param name="departmentId">The department the user belongs to.</param>
/// <param name="email">The user's email address.</param>
/// <param name="firstName">The user's first name.</param>
/// <param name="lastName">The user's last name.</param>
/// <returns>True if the subscriber was created successfully; otherwise, false.</returns>
Task<bool> CreateUserSubscriber(string userId, string code, int departmentId, string email, string firstName, string lastName);

/// <summary>
/// Creates a Novu subscriber for a unit (device or group).
/// </summary>
/// <param name="unitId">The unique identifier of the unit.</param>
/// <param name="code">The Novu integration code or API key.</param>
/// <param name="departmentId">The department the unit belongs to.</param>
/// <param name="unitName">The name of the unit.</param>
/// <param name="deviceId">The device identifier associated with the unit.</param>
/// <returns>True if the subscriber was created successfully; otherwise, false.</returns>
Task<bool> CreateUnitSubscriber(int unitId, string code, int departmentId, string unitName, string deviceId);

/// <summary>
/// Updates the Firebase Cloud Messaging (FCM) token for a user subscriber.
/// </summary>
/// <param name="userId">The unique identifier of the user.</param>
/// <param name="code">The Novu integration code or API key.</param>
/// <param name="token">The FCM token to associate with the user.</param>
/// <returns>True if the token was updated successfully; otherwise, false.</returns>
Task<bool> UpdateUserSubscriberFcm(string userId, string code, string token);

/// <summary>
/// Updates the Firebase Cloud Messaging (FCM) token for a unit subscriber.
/// </summary>
/// <param name="unitId">The unique identifier of the unit.</param>
/// <param name="code">The Novu integration code or API key.</param>
/// <param name="token">The FCM token to associate with the unit.</param>
/// <returns>True if the token was updated successfully; otherwise, false.</returns>
Task<bool> UpdateUnitSubscriberFcm(int unitId, string code, string token);

/// <summary>
/// Updates the Apple Push Notification Service (APNS) token for a unit subscriber.
/// </summary>
/// <param name="unitId">The unique identifier of the unit.</param>
/// <param name="code">The Novu integration code or API key.</param>
/// <param name="token">The APNS token to associate with the unit.</param>
/// <returns>True if the token was updated successfully; otherwise, false.</returns>
Task<bool> UpdateUnitSubscriberApns(int unitId, string code, string token);

/// <summary>
/// Updates the Apple Push Notification Service (APNS) token for a user subscriber.
/// </summary>
/// <param name="userId">The unique identifier of the user.</param>
/// <param name="code">The Novu integration code or API key.</param>
/// <param name="token">The APNS token to associate with the user.</param>
/// <returns>True if the token was updated successfully; otherwise, false.</returns>
Task<bool> UpdateUserSubscriberApns(string userId, string code, string token);

/// <summary>
/// Sends a dispatch notification to a unit.
/// </summary>
/// <param name="title">The notification title.</param>
/// <param name="body">The notification body content.</param>
/// <param name="unitId">The unique identifier of the unit to notify.</param>
/// <param name="depCode">The department code.</param>
/// <param name="eventCode">The event code associated with the dispatch.</param>
/// <param name="type">The type of notification.</param>
/// <param name="enableCustomSounds">Whether to enable custom notification sounds.</param>
/// <param name="count">The badge or notification count.</param>
/// <param name="color">The color code for the notification.</param>
/// <returns>True if the notification was sent successfully; otherwise, false.</returns>
Task<bool> SendUnitDispatch(string title, string body, int unitId, string depCode, string eventCode, string type,
bool enableCustomSounds, int count, string color);

/// <summary>
/// Deletes a notification message by its identifier.
/// </summary>
/// <param name="messageId">The unique identifier of the message to delete.</param>
/// <returns>True if the message was deleted successfully; otherwise, false.</returns>
Task<bool> DeleteMessage(string messageId);

Task<bool> SendUserDispatch(string title, string body, string userId, string depCode, string eventCode, string type, bool enableCustomSounds, int count, string color);

Task<bool> SendUserMessage(string title, string body, string userId, string depCode, string eventCode, string type);

Task<bool> SendUserNotification(string title, string body, string userId, string depCode, string eventCode, string type);
}
4 changes: 2 additions & 2 deletions Core/Resgrid.Model/PushUri.cs
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,8 @@ public string PushLocation
{
_pushLocation = value;

if (((Platforms)PlatformType) == Platforms.Windows8 || ((Platforms)PlatformType) == Platforms.WindowsPhone7 || ((Platforms)PlatformType) == Platforms.WindowsPhone8 || ((Platforms)PlatformType) == Platforms.UnitWin)
ChannelUri = new Uri(_pushLocation, UriKind.Absolute);
//if (((Platforms)PlatformType) == Platforms.Windows8 || ((Platforms)PlatformType) == Platforms.WindowsPhone7 || ((Platforms)PlatformType) == Platforms.WindowsPhone8 || ((Platforms)PlatformType) == Platforms.UnitWin)
// ChannelUri = new Uri(_pushLocation, UriKind.Absolute);
Comment on lines +48 to +49
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🛠️ Refactor suggestion

Remove commented-out code to maintain code cleanliness

Since Windows platform support is being phased out as part of this PR, the commented code should be removed rather than left as comments. This improves code maintainability and clarity.

-//if (((Platforms)PlatformType) == Platforms.Windows8 || ((Platforms)PlatformType) == Platforms.WindowsPhone7 || ((Platforms)PlatformType) == Platforms.WindowsPhone8 || ((Platforms)PlatformType) == Platforms.UnitWin)
-//	ChannelUri = new Uri(_pushLocation, UriKind.Absolute);
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
//if (((Platforms)PlatformType) == Platforms.Windows8 || ((Platforms)PlatformType) == Platforms.WindowsPhone7 || ((Platforms)PlatformType) == Platforms.WindowsPhone8 || ((Platforms)PlatformType) == Platforms.UnitWin)
// ChannelUri = new Uri(_pushLocation, UriKind.Absolute);
🤖 Prompt for AI Agents
In Core/Resgrid.Model/PushUri.cs around lines 48-49, there is commented-out
legacy code handling Windows platform ChannelUri creation; remove these two
commented lines entirely to clean up dead code now that Windows platform support
is phased out, and ensure no remaining references depend on this commented
block.

}
}
}
Expand Down
2 changes: 1 addition & 1 deletion Core/Resgrid.Model/Services/ICommunicationService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ Task<bool> SendUnitCallAsync(Call call, CallDispatchUnit dispatch, string depart
/// <param name="title">The title.</param>
/// <param name="profile">The profile.</param>
/// <returns>Task&lt;System.Boolean&gt;.</returns>
Task<bool> SendNotificationAsync(string userId, int departmentId, string message, string departmentNumber,
Task<bool> SendNotificationAsync(string userId, int departmentId, string message, string departmentNumber, Department department,
string title = "Notification", UserProfile profile = null);

/// <summary>
Expand Down
4 changes: 2 additions & 2 deletions Core/Resgrid.Services/CalendarService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -487,9 +487,9 @@ public async Task<bool> NotifyNewCalendarItemAsync(CalendarItem calendarItem)
foreach (var member in group.Members)
{
if (profiles.ContainsKey(member.UserId))
await _communicationService.SendNotificationAsync(member.UserId, calendarItem.DepartmentId, message, departmentNumber, title, profiles[member.UserId]);
await _communicationService.SendNotificationAsync(member.UserId, calendarItem.DepartmentId, message, departmentNumber, department, title, profiles[member.UserId]);
else
await _communicationService.SendNotificationAsync(member.UserId, calendarItem.DepartmentId, message, departmentNumber, title, null);
await _communicationService.SendNotificationAsync(member.UserId, calendarItem.DepartmentId, message, departmentNumber, department, title, null);
}
}
}
Expand Down
3 changes: 2 additions & 1 deletion Core/Resgrid.Services/CommunicationService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -290,7 +290,7 @@ public async Task<bool> SendUnitCallAsync(Call call, CallDispatchUnit dispatch,
return true;
}

public async Task<bool> SendNotificationAsync(string userId, int departmentId, string message, string departmentNumber, string title = "Notification", UserProfile profile = null)
public async Task<bool> SendNotificationAsync(string userId, int departmentId, string message, string departmentNumber, Department department, string title = "Notification", UserProfile profile = null)
{
if (Config.SystemBehaviorConfig.DoNotBroadcast && !Config.SystemBehaviorConfig.BypassDoNotBroadcastDepartments.Contains(departmentId))
return false;
Expand Down Expand Up @@ -319,6 +319,7 @@ public async Task<bool> SendNotificationAsync(string userId, int departmentId, s
var spm = new StandardPushMessage();
spm.Title = "Notification";
spm.SubTitle = $"{title} {message}";
spm.DepartmentCode = department?.Code;

try
{
Expand Down
148 changes: 87 additions & 61 deletions Core/Resgrid.Services/PushService.cs
Original file line number Diff line number Diff line change
@@ -1,14 +1,16 @@
using System;
using System.IO;
using System.Linq;
using System.Reflection;
using System.Collections.Generic;
using System.Threading.Tasks;
using DnsClient;
using FirebaseAdmin.Messaging;
using Resgrid.Model;
using Resgrid.Model.Messages;
using Resgrid.Model.Providers;
using Resgrid.Model.Services;
using DnsClient;
using System;
using System.Collections.Generic;
using System.Drawing;
using System.IO;
using System.Linq;
using System.Reflection;
using System.Threading.Tasks;

namespace Resgrid.Services
{
Expand Down Expand Up @@ -36,31 +38,18 @@ public async Task<bool> Register(PushUri pushUri)
if (pushUri == null || String.IsNullOrWhiteSpace(pushUri.DeviceId))
return false;

string deviceId = pushUri.DeviceId.GetHashCode().ToString();
var code = pushUri.PushLocation;

// We just store the full Device Id in the PushUri object, the hashed version is for Azure
//var existingPushUri = _pushUriService.GetPushUriByPlatformDeviceId((Platforms)pushUri.PlatformType, pushUri.DeviceId);
List<PushRegistrationDescription> usersDevices = null;
// 1) iOS -> APNS
if (pushUri.PlatformType == (int)Platforms.iOS)
return await _novuProvider.UpdateUserSubscriberApns(pushUri.UserId, code, pushUri.DeviceId);

try
{
usersDevices = await _notificationProvider.GetRegistrationsByUserId(pushUri.UserId);

if (usersDevices == null || !usersDevices.Any(x => x.Tags.Contains(deviceId)))
await _notificationProvider.RegisterPush(pushUri);
}
catch (TimeoutException)
{ }
catch (TaskCanceledException)
{ }
// 2) Android -> FCM
if (pushUri.PlatformType == (int)Platforms.Android)
return await _novuProvider.UpdateUserSubscriberFcm(pushUri.UserId, code, pushUri.DeviceId);

//if (existingPushUri == null)
// pushUri = _pushUriService.SavePushUri(pushUri);

//if (usersDevices == null || !usersDevices.Any(x => x.Tags.Contains(deviceId)))
// await _notificationProvider.RegisterPush(pushUri);

return true;
// 3) TODO: Web Push (other platforms)
return false;
}

public async Task<bool> UnRegister(PushUri pushUri)
Expand All @@ -72,29 +61,22 @@ public async Task<bool> UnRegister(PushUri pushUri)

public async Task<bool> RegisterUnit(PushUri pushUri)
{
//string deviceId = pushUri.DeviceId;
List<PushRegistrationDescription> usersDevices = null;

//try
//{
// usersDevices = await _unitNotificationProvider.GetRegistrationsByUUID(pushUri.PushLocation);
//}
//catch (TimeoutException)
//{ }
if (pushUri == null || !pushUri.UnitId.HasValue || string.IsNullOrWhiteSpace(pushUri.PushLocation))
return false;

if (pushUri.UnitId.HasValue && !string.IsNullOrWhiteSpace(pushUri.PushLocation))
await _novuProvider.UpdateUnitSubscriberFcm(pushUri.UnitId.Value, pushUri.PushLocation, pushUri.DeviceId);
var unitId = pushUri.UnitId.Value;
var code = pushUri.PushLocation;

// 1) iOS -> APNS
if (pushUri.PlatformType == (int)Platforms.iOS)
return await _novuProvider.UpdateUnitSubscriberApns(unitId, code, pushUri.DeviceId);

//if (usersDevices == null || !usersDevices.Any(x => x.Tags.Contains(string.Format("unitId:{0}", pushUri.UnitId.ToString()))))
// await _unitNotificationProvider.RegisterPush(pushUri);
//else
//{
// await _unitNotificationProvider.UnRegisterPushByUUID(pushUri.PushLocation);
// await _unitNotificationProvider.RegisterPush(pushUri);
//}
// 2) Android -> FCM
if (pushUri.PlatformType == (int)Platforms.Android)
return await _novuProvider.UpdateUnitSubscriberFcm(unitId, code, pushUri.DeviceId);

return true;
// 3) TODO: Web Push (other platforms)
return false;
}

public async Task<bool> UnRegisterUnit(PushUri pushUri)
Expand All @@ -118,7 +100,25 @@ public async Task<bool> PushMessage(StandardPushMessage message, string userId,
profile = await _userProfileService.GetProfileByUserIdAsync(userId);

if (profile != null && profile.SendMessagePush)
await _notificationProvider.SendAllNotifications(message.Title, message.SubTitle, userId, string.Format("M{0}", message.MessageId), ((int)PushSoundTypes.Message).ToString(), true, 1, "#000000");
{
try
{
await _notificationProvider.SendAllNotifications(message.Title, message.SubTitle, userId, string.Format("M{0}", message.MessageId), ((int)PushSoundTypes.Message).ToString(), true, 1, "#000000");
}
catch (Exception ex)
{
Framework.Logging.LogException(ex);
}

try
{
await _novuProvider.SendUserMessage(message.Title, message.SubTitle, userId, message.DepartmentCode, string.Format("M{0}", message.MessageId), null);
}
catch (Exception ex)
{
Framework.Logging.LogException(ex);
}
}

return true;
}
Expand All @@ -132,8 +132,24 @@ public async Task<bool> PushNotification(StandardPushMessage message, string use
profile = await _userProfileService.GetProfileByUserIdAsync(userId);

if (profile != null && profile.SendNotificationPush)
await _notificationProvider.SendAllNotifications(message.Title, message.SubTitle, userId, string.Format("N{0}", message.MessageId), ((int)PushSoundTypes.Notifiation).ToString(), true, 1, "#000000");

{
try
{
await _notificationProvider.SendAllNotifications(message.Title, message.SubTitle, userId, string.Format("N{0}", message.MessageId), ((int)PushSoundTypes.Notifiation).ToString(), true, 1, "#000000");
}
catch (Exception ex)
{
Framework.Logging.LogException(ex);
}
try
{
await _novuProvider.SendUserMessage(message.Title, message.SubTitle, userId, message.DepartmentCode, string.Format("N{0}", message.MessageId), null);
}
catch (Exception ex)
{
Framework.Logging.LogException(ex);
}
}
return true;
}

Expand Down Expand Up @@ -167,7 +183,26 @@ public async Task<bool> PushCall(StandardPushCall call, string userId, UserProfi
color = priority.Color;

if (profile != null && profile.SendPush)
await _notificationProvider.SendAllNotifications(call.SubTitle, call.Title, userId, string.Format("C{0}", call.CallId), ConvertCallPriorityToSound((int)call.Priority, priority), true, call.ActiveCallCount, color);
{
// Legacy Push Notifications (Azure)
try
{
await _notificationProvider.SendAllNotifications(call.SubTitle, call.Title, userId, string.Format("C{0}", call.CallId), ConvertCallPriorityToSound((int)call.Priority, priority), true, call.ActiveCallCount, color);
}
catch (Exception ex)
{
Framework.Logging.LogException(ex);
}

try
{
await _novuProvider.SendUserDispatch(call.Title, call.SubTitle, userId, call.DepartmentCode, string.Format("C{0}", call.CallId), ConvertCallPriorityToSound((int)call.Priority, priority), true, call.ActiveCallCount, color);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Verification agent

🧩 Analysis chain

Verify DepartmentCode is populated in StandardPushCall

The code passes call.DepartmentCode to SendUserDispatch, but StandardPushCall may not always have this property populated. Ensure it's properly set before this method is called.


🏁 Script executed:

#!/bin/bash
# Check StandardPushCall definition and usage to verify DepartmentCode is always set
ast-grep --pattern 'class StandardPushCall {
  $$$
  public string DepartmentCode { $$$; set; }
  $$$
}'

# Check where StandardPushCall is instantiated
rg -A 5 "new StandardPushCall"

Length of output: 1586


StandardPushCall.DepartmentCode is never set

In PushService.cs you pass call.DepartmentCode to SendUserDispatch, but all instantiations of StandardPushCall in CommunicationService.cs only assign DepartmentId. This means DepartmentCode remains null and downstream notifications won’t include the correct department code.

Please update each instantiation in
Core/Resgrid.Services/CommunicationService.cs
to also set DepartmentCode. For example:

     // existing assignment
     spc.DepartmentId = departmentId;
+    spc.DepartmentCode = departmentCode;   // ensure DepartmentCode is populated

Affected locations (3 occurrences of new StandardPushCall() → setting spc.DepartmentId):

  • Core/Resgrid.Services/CommunicationService.cs: around lines where spc.DepartmentId = … is called.
🤖 Prompt for AI Agents
In Core/Resgrid.Services/CommunicationService.cs around the three locations
where new StandardPushCall() is created and spc.DepartmentId is assigned, the
DepartmentCode property is never set causing null department codes downstream;
update each instantiation to also set spc.DepartmentCode to the correct
department code (e.g., the department object's Code/DepartmentCode or the source
call’s DepartmentCode value depending on available variables) so that
SendUserDispatch receives a valid DepartmentCode.

}
catch (Exception ex)
{
Framework.Logging.LogException(ex);
}
}

return true;
}
Expand All @@ -184,15 +219,6 @@ public async Task<bool> PushCallUnit(StandardPushCall call, int unitId, Departme
if (priority != null)
color = priority.Color;

try
{
await _unitNotificationProvider.SendAllNotifications(call.SubTitle, call.Title, unitId, string.Format("C{0}", call.CallId), ConvertCallPriorityToSound((int)call.Priority, priority), true, call.ActiveCallCount, color);
}
catch (Exception ex)
{
Framework.Logging.LogException(ex);
}

try
{
await _novuProvider.SendUnitDispatch(call.Title, call.SubTitle, unitId, call.DepartmentCode, string.Format("C{0}", call.CallId), ConvertCallPriorityToSound((int)call.Priority, priority), true, call.ActiveCallCount, color);
Expand Down
Loading
Loading