Daily, weekly, monthly RECURRING tasks help

i have this use case which i need help in :
i have 3 types of RECURRING tasks:

1-daily task: i can finish a task as much times (x) as i entered daily

2- weekly task : i can finish a task as much times (x) i want for a duration of 7 days from the creation day.(1 time every day)

3- monthly task: i can finish a task as much times (x) i want for a duration of 30 days from the creation day.(1 time every day)

for the daily task i think the video from Robert Petitto solves my issue for just for 1 time task done daily.
link to the video for reference:

-and for the weekly and monthly tasks i tried to replicate the same but of course it all started to be hard.
how can i configure this in the database and show different messages based on number of completions and if a weekly task is done for (x) number of times 7 days from the creation time and …etc
my issue is with the logic inside the tables and sure some visibility conditions for some buttons will solve the display issue but how can i implement this in the database, i have no problems in making 3 tables for these 3 types of tasks if needed
thank you guys very much for the support

I’m not sure I understand your requirement. Do you mean you have a limit for daily, weekly and monthly task, and you want all your users to only be able to complete that many times, no more than that?

Hello, thanks for the reply sir
Actually no.
Let me explain with an example:
I want to go to the gym 3 times weekly.
So i go into the app i select weekly task and enter the name and the number of times.
After that i want the app to track how many times i actually went to the gym for that week. Is it one time, two times or more.
And similar is the monthly task as well
I want to wash my car 2 times monthly.
How can i implement such tracking logic?
What i found is changing the date to a numerical value so i can subtract the (now) value from the creation date and compare it with an if else if it’s bigger than 7 is less than 7 for weekly. But this is just from the top of my head.
What is your opinion?