From 3bfc08b117014f76e5e2d2341e6698a3ac10fa22 Mon Sep 17 00:00:00 2001 From: carlosjr Date: Thu, 24 Jun 2021 10:06:31 +0200 Subject: [PATCH] route.summary order by priority --- modules/route/back/methods/route/summary.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/modules/route/back/methods/route/summary.js b/modules/route/back/methods/route/summary.js index ad65edb4a..10cfe38ee 100644 --- a/modules/route/back/methods/route/summary.js +++ b/modules/route/back/methods/route/summary.js @@ -48,12 +48,12 @@ module.exports = Self => { scope: { fields: ['id', 'm3', 'numberPlate'] } - } - ], + }, + ] }; summary.route = await Self.app.models.Route.findOne(filter); - summary.tickets = await Self.app.models.Route.getTickets({id: id}); + summary.tickets = await Self.app.models.Route.getTickets({id: id, order: 'priority ASC'}); return summary; };