refs #6184 saveCmr #1788

Merged
guillermo merged 58 commits from 6184-saveCmr into dev 2024-02-13 06:47:06 +00:00
1 changed files with 4 additions and 3 deletions
Showing only changes of commit c7be1b57b1 - Show all commits

View File

@ -43,13 +43,14 @@ module.exports = Self => {
const stmt = new ParameterizedSQL(` const stmt = new ParameterizedSQL(`
SELECT * SELECT *
FROM( FROM(
SELECT DISTINCT w.id, w.code, u.name, u.nickname, u.active, b.departmentFk SELECT w.id, w.code, u.name, u.nickname, u.active, wd.departmentFk
FROM worker w FROM worker w
JOIN account.user u ON u.id = w.id JOIN account.user u ON u.id = w.id
LEFT JOIN business b ON b.workerFk = w.id LEFT JOIN workerDepartment wd ON wd.workerFk = w.id
) w`); ) w`);
stmt.merge(conn.makeSuffix(filter)); stmt.merge(conn.makeSuffix(filter));
return conn.executeStmt(stmt); return conn.executeStmt(stmt);
}; };