fix: defaulter filter correct sql #2779
|
@ -85,6 +85,7 @@ module.exports = Self => {
|
||||||
LEFT JOIN (
|
LEFT JOIN (
|
||||||
SELECT MAX(started), clientFk, finished
|
SELECT MAX(started), clientFk, finished
|
||||||
FROM recovery
|
FROM recovery
|
||||||
|
GROUP BY clientFk
|
||||||
|
|||||||
) r ON r.clientFk = c.id
|
) r ON r.clientFk = c.id
|
||||||
LEFT JOIN workerDepartment wd ON wd.workerFk = u.id
|
LEFT JOIN workerDepartment wd ON wd.workerFk = u.id
|
||||||
JOIN department dp ON dp.id = wd.departmentFk
|
JOIN department dp ON dp.id = wd.departmentFk
|
||||||
|
|
Loading…
Reference in New Issue
@jgallego aixina valdria, pq per a cada client traguem la maxima
https://gitea.verdnatura.es/verdnatura/salix/pulls/2754/files#issuecomment-58376