Hello,
in my app I use sqlite to save items with a date and I need, everyday, to check if there are items from db with “date = today” and if there are, show a notification with a custom message, also if app is not running.
My idea at this time is to create a local notification at item date when it is created and, if a notification at that date already exists, the system will update it editing the badge and the text. The (boring) problem is that I want allow user to choose how many days before show the notification, so if he choose 3 days, I have to delete all notifications and recreate them changing the dates.
To avoid this, I thought to create an interval at every hour in background mode to check items, but I read that in latest versions of iOS apps in background are limited and I think the timer would take a bit of memory of the phone.
What do you think is the best approach?
Anyway, I would use local and not push notifications because the app has offline support and the “online” one is only to save data in the cloud.