diff --git a/modules/route/back/methods/route/getTickets.js b/modules/route/back/methods/route/getTickets.js index 50227b810..5705d8905 100644 --- a/modules/route/back/methods/route/getTickets.js +++ b/modules/route/back/methods/route/getTickets.js @@ -50,7 +50,7 @@ module.exports = Self => { u.nickname AS userNickname, vn.ticketTotalVolume(t.id) AS volume FROM route r - LEFT JOIN ticket t ON t.routeFk = r.id + JOIN ticket t ON t.routeFk = r.id LEFT JOIN ticketState ts ON ts.ticketFk = t.id LEFT JOIN state st ON st.id = ts.stateFk LEFT JOIN warehouse wh ON wh.id = t.warehouseFk @@ -72,8 +72,6 @@ module.exports = Self => { const tickets = await conn.executeStmt(stmt, myOptions); - if (tickets.length === 1 && !tickets[0].id) return []; - return tickets; }; };