Should be able to schedule multiple local notifications at once where later notifications will replace earlier ones

Originator:jjc1138
Number:rdar://31646102 Date Originated:2017-04-15
Status:Open Resolved:
Product:iOS + SDK Product Version:10.x
Classification:Enhancement Reproducible:
 
Area:
UserNotifications Framework

Summary:
I want to be able to schedule multiple timed local notifications in advance, and each one should replace the previous one (to avoid clogging up the user's notifications with outdated information if they don't dismiss each one).

This isn't currently possible because the mechanism for replacing a previous notification is to use the same identifier, but if the previous notification with that identifier has only been scheduled and not delivered yet, then adding the second notification replaces the first one in the schedule and the first one is never delivered.

An example where this enhancement would be useful would be a workout app that runs a pre-determined interval workout plan and uses notifications to inform the user at the set times when they should adjust workout intensity.

A simple API for this would be to add a parameter to UNNotificationRequest called something like 'replacesNotificationWithIdentifier', or a slightly more elaborate API would be to give notification requests an optional second identifier called the 'replacementIdentifier', and have delivery of notifications with one of those replace all others with the same 'replaceIdentifier' that have been delivered.

Comments


Please note: Reports posted here will not necessarily be seen by Apple. All problems should be submitted at bugreport.apple.com before they are posted here. Please only post information for Radars that you have filed yourself, and please do not include Apple confidential information in your posts. Thank you!