Hello all I'm building an user subscription app in laravel
In my app I have a table to store user's newly created app details. I have two columns in my apps table to store the expire date and status of the app.
status-0-inactive
status-1-active
Users can buy one year membership plan or one month membership plan at the registration.
THE PROBLEM
Assume user has purchased an one month subscription plan today (2020-04-15) and create a new app. Then an expire date will be automatically stored as (2020-05-15) in the apps table for that app.
In each an every app there is an option (a button 'Edit your app') for users to edit their application.
But if the app is expired I want to change the status of the app to '0' and disable that button automatically until the user make the payment again.
I know I can disable or enable the button by checking the app status but, how can I update the app status column automatically when the expire date is reached??
I'm using Laravel 6
via Chebli Mohamed
Aucun commentaire:
Enregistrer un commentaire