мелочь об днях

This commit is contained in:
Alexey Kasyanchuk 2017-11-10 14:29:23 +03:00
parent 0717e4d94a
commit 8b9c1e3da4

View File

@ -442,7 +442,7 @@ io.on('connection', function(socket)
} }
if(type == 'month') if(type == 'month')
{ {
where = ' and `added` > DATE_SUB(NOW(), INTERVAL 7 DAY) ' where = ' and `added` > DATE_SUB(NOW(), INTERVAL 30 DAY) '
} }
} }
mysqlPool.query(`SELECT * FROM torrents WHERE seeders > 0 and (contentCategory is null or contentCategory != 'xxx') ${where} ORDER BY seeders + leechers DESC LIMIT ${max}`, function (error, rows) { mysqlPool.query(`SELECT * FROM torrents WHERE seeders > 0 and (contentCategory is null or contentCategory != 'xxx') ${where} ORDER BY seeders + leechers DESC LIMIT ${max}`, function (error, rows) {