Answer the question
In order to leave comments, you need to log in
How to properly create a function to compare two dates?
Good evening. I need to use cron to check every day today's date and the date until which date the product can be put up for sale (this date is already set in the table). If the deadline has passed, then disable the button in the GridView. There is a normal checkbox. I've never dealt with cron and don't know how to solve it
Answer the question
In order to leave comments, you need to log in
Why would you want to do this with a cron? When building a gridView, it's much easier to hide the button. There is even a method out of the box for this:
https://www.yiiframework.com/doc/api/2.0/yii-grid-...
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question