1

I've been developing a Flutter mobile App, and I'm using the Firebase Cloud Firestore to deliver "cards" on the app. But I need to create a "rule" to change for another card each 24 hours, or if possible, to change every midnight in the user's time.

I don't know how I can do this... if I create a code for this in the app, will not this restart the timer always the user restart the app?

Please, if the solution is in Flutter/Firebase docs, invite me the link, I didn't find nothing about this.

Thank you.

  • 1
    It sounds like you want to make periodic changes to the database from a trusted system. Cloud Functions are a great choice for this, especially when using something like cron-job.org to trigger them. See https://stackoverflow.com/questions/42790735/cloud-functions-for-firebase-trigger-on-time – Frank van Puffelen Jul 16 '18 at 18:31
  • I read about Firebase Cloud Functions... this will probably work well in my project. Thank you so much, @FrankvanPuffelen – Fernando Henrique Köetz Jul 17 '18 at 11:08

0 Answers0