Skip to content
This repository was archived by the owner on Jan 14, 2025. It is now read-only.

Commit ee9b9b7

Browse files
committed
add docs
1 parent c4865aa commit ee9b9b7

File tree

3 files changed

+26
-3
lines changed

3 files changed

+26
-3
lines changed

README.md

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -524,6 +524,32 @@ Removes the specified notifications from Notification Center
524524
| ----------- | ----- | -------- | ---------------------------------- |
525525
| identifiers | array | Yes | Array of notification identifiers. |
526526

527+
### 6) getScheduledLocalNotifications
528+
529+
```javascript
530+
PushNotificationIOS.getScheduledLocalNotifications(callback);
531+
```
532+
533+
Provides you with a list of the app’s scheduled local notifications that are yet to be displayed
534+
535+
**Parameters:**
536+
537+
| Name | Type | Required | Description |
538+
| -------- | -------- | -------- | ----------------------------------------------------------- |
539+
| callback | function | Yes | Function which receive an array of delivered notifications. |
540+
541+
Returns an array of local scheduled notification objects containing:
542+
543+
| Name | Type | Description |
544+
| -------- | -------- | -------- | ----------------------------------------------------------- |
545+
| id | number | The identifier of this notification. |
546+
| date | Date | The fire date of this notification. |
547+
| title | string | The title of this notification. |
548+
| message | string | The message body of this notification. |
549+
| soundName | string | The sound name of this notification. |
550+
| repeatInterval | number | The repeat interval of this notification. |
551+
| number | number | App notification badge count number. |
552+
527553
## Abandon Permissions
528554

529555
`PushNotification.abandonPermissions()` Revokes the current token and unregister for all remote notifications received via APNS or FCM.

android/src/main/java/com/dieam/reactnativepushnotification/modules/RNPushNotificationHelper.java

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -741,7 +741,6 @@ public WritableArray getScheduledLocalNotifications() {
741741
notificationMap.putString("number", notification.getNumber());
742742
notificationMap.putDouble("date", notification.getFireDate());
743743
notificationMap.putString("id", notification.getId());
744-
notificationMap.putBoolean("remote", false);
745744
notificationMap.putString("repeatInterval", notification.getRepeatType());
746745
notificationMap.putString("soundName", notification.getSound());
747746

index.js

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -448,7 +448,6 @@ Notifications.getScheduledLocalNotifications = function(callback) {
448448
return ({
449449
soundName: notif.soundName,
450450
repeatInterval: notif.repeatInterval,
451-
remote: notif.remote,
452451
id: notif.userInfo?.id,
453452
date: new Date(notif.fireDate),
454453
number: notif?.applicationIconBadgeNumber,
@@ -461,7 +460,6 @@ Notifications.getScheduledLocalNotifications = function(callback) {
461460
return ({
462461
soundName: notif.soundName,
463462
repeatInterval: notif.repeatInterval,
464-
remote: notif.remote,
465463
id: notif.id,
466464
date: new Date(notif.date),
467465
number: notif.number,

0 commit comments

Comments
 (0)