2

I am making a medicine app in flutter in which users can set(input) the time at which they have to take medicines and the app will remind them by sending a notification at the scheduled time.

However, I cann't figure out how to send notification to the user at time set by the user themselves.

In the app, the user have to input the data about the medicines they take, which will include the time(the exact time of the day when the medicine have to be taken) and frequency(how many times the medicine have to be taken ex. daily twice, daily once, alternate days, or once in a week etc.) to take the medicines. And I have to send the notification at that time set by user and as many times as the frequency. The notification also have to be periodic as per the input given by the user. For example, if the user has input the frequency as twice daily at 10:00am and 7:00pm, then they should get the notification at that time every day.

I am using SQLite as my databse and for that I've included the SQflite package.

All the tutorials and articles that I found were about how to manually schedule notifications. I didn't find any resource for which shows how to schedule the notification at a time input by the user.

Please help!

1 Answers1

2

It depends on the way you want to push and what technology you are using to push the notification

  1. Firebase serverLess => cloud function to schedule a job
  2. Server database => use the cron job to schedule the notification
  3. Local notification => https://pub.dev/packages/flutter_local_notifications#scheduling-a-notification
kietdt
  • 21
  • 2