Yes, the company needs to do a function, is to regularly remind users that coupons are about to expire, is now set in advance 3 days notice users, the table is very simple, on a table, there is coupon_id (coupon ID) user_id (user ID) end_time (coupon end time). Plan to run a script every day, but if you press End_time to filter, will result in a coupon will be reminded of the user a number of times, assuming a coupon 31st expires, the script today will run to this coupon, tomorrow or will run to this one. I don't know what we can do to solve this problem.
Reply content:
Yes, the company needs to do a function, is to regularly remind users that coupons are about to expire, is now set in advance 3 days notice users, the table is very simple, on a table, there is coupon_id (coupon ID) user_id (user ID) end_time (coupon end time). Plan to run a script every day, but if you press End_time to filter, will result in a coupon will be reminded of the user a number of times, assuming a coupon 31st expires, the script today will run to this coupon, tomorrow or will run to this one. I don't know what we can do to solve this problem.
Look at the requirements definition,
Only one reminder, date difference condition =3
Reminders multiple times until expiration date, <=3
The coupon end time is fixed, then the notice time is fixed, the notification is finished once the stop
Find a place to write down the ID, the next time directly ignored on the line Ah, how complex, or directly add a field, make the next tag, filter ignored on the line