phonegap / phonegap-plugin-local-notification

An implementation of the Web Notifications API for end-user notifications.
MIT License
38 stars 23 forks source link

IOS notifications not appearing in system tray #10

Closed kanak-infoObjects closed 7 years ago

kanak-infoObjects commented 7 years ago

Expected Behaviour

IOS notifications should appear in system tray similar to push notifications

Actual Behaviour

Notification arrives and the onclick event gets called automatically

Platform and Version (eg. Android 5.0 or iOS 9.2.1)

IOS 10.3

Cordova CLI version and cordova platform version

6.5.0

Plugin version

1.0.1

Sample Code that illustrates the problem

var notification = new Notification('My Title', { tag: 'MESSAGE', body: 'BODY' }) notification.onclick = ()=>{ alert("clicked"): }

Logs taken while reproducing problem

Notification received 2017-06-07 20:07:47.064279+0530 [352:36988] Push Plugin key: alert 2017-06-07 20:07:47.064626+0530 [352:36988] Push Plugin key: sound 2017-06-07 20:07:47.148404+0530 [352:36988] got local notification 2017-06-07 20:07:47.148519+0530 [352:36988] in plugin, local notification clicked

macdonst commented 7 years ago

@kanak-infoObjects is your app in the foreground when you call notification?

kanak-infoObjects commented 7 years ago

Yes

macdonst commented 7 years ago

@kanak-infoObjects right, then this is a duplicate of Issue #8. Go give that a 👍