• Оповещение о просроченных задачах в Redmine

    @texnoid
    Дату можно вытаскивать из самого mysql.
    Я подправил чуток под себя запрос:

    SELECT
    concat (id," ",author_id) as issueid_userid,
    CONCAT(DAYOFMONTH(created_on)," ",MONTHNAME(created_on)," ",YEAR(created_on)) as data_sozdaniya,
    CONCAT(DAYOFMONTH(CURDATE())," ",MONTHNAME(CURDATE())," ",YEAR(CURDATE())) as tekushaya_data,
    CONCAT("не обновлялся ",TO_DAYS(updated_on)-TO_DAYS(CURDATE())," дня") as dateout
    from issues
    WHERE updated_on<=CURDATE() and updated_on<=DATE_SUB(CURDATE(),Interval 30 DAY) and status_id in ("1","6","11","13","15","16")

    Может кому пригодится.