Skip to content

Commit 6306057

Browse files
committed
RE1-T88 PR#264 fix
1 parent 2292217 commit 6306057

File tree

1 file changed

+29
-12
lines changed

1 file changed

+29
-12
lines changed

Providers/Resgrid.Providers.Messaging/NovuProvider.cs

Lines changed: 29 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
using Resgrid.Model;
88
using Resgrid.Model.Providers;
99
using Resgrid.Providers.Bus.Models;
10+
using SharpCompress.Common;
1011
using System.Text;
1112

1213

@@ -296,22 +297,38 @@ private async Task<bool> SendNotification(string title, string body, string reci
296297
type = type,
297298
category = channelName,
298299
eventCode = eventCode,
300+
payload = new
301+
{
302+
aps = new
303+
{
304+
badge = count,
305+
sound = new
306+
{
307+
name = sound,
308+
critical = channelName == "calls" ? 1 : 0,
309+
volume = 1.0f
310+
},
311+
category = channelName,
312+
eventCode = eventCode,
313+
customType = type
314+
},
315+
},
299316
},
300317
},
301-
apns = new Dictionary<string, object>
302-
{
303-
["badge"] = count,
304-
["sound"] = new
318+
apns = new Dictionary<string, object>
305319
{
306-
name = sound,
307-
critical = channelName == "calls" ? 1 : 0,
308-
volume = 1.0f
320+
["badge"] = count,
321+
["sound"] = new
322+
{
323+
name = sound,
324+
critical = channelName == "calls" ? 1 : 0,
325+
volume = 1.0f
326+
},
327+
["type"] = type,
328+
["category"] = channelName,
329+
["eventCode"] = eventCode,
330+
["gcm.message_id"] = "123"
309331
},
310-
["type"] = type,
311-
["category"] = channelName,
312-
["eventCode"] = eventCode,
313-
["gcm.message_id"] = "123"
314-
},
315332
},
316333
to = new[]{ new
317334
{

0 commit comments

Comments
 (0)