From 2a6de77e17b4cc89a5e5f54a1582e4d855f19f9e Mon Sep 17 00:00:00 2001 From: Joan Sanchez Date: Fri, 12 Jul 2019 08:49:44 +0200 Subject: [PATCH] ticket.index show zone hour & minute. Show only tickets from today --- modules/ticket/back/methods/ticket/filter.js | 6 +++++- modules/ticket/front/index/index.html | 7 ++++++- modules/ticket/front/index/index.js | 11 +++++++++++ modules/ticket/front/index/locale/es.yml | 4 +++- 4 files changed, 25 insertions(+), 3 deletions(-) diff --git a/modules/ticket/back/methods/ticket/filter.js b/modules/ticket/back/methods/ticket/filter.js index 7bf4cf4de..a3c17ecc4 100644 --- a/modules/ticket/back/methods/ticket/filter.js +++ b/modules/ticket/back/methods/ticket/filter.js @@ -196,8 +196,12 @@ module.exports = Self => { ts.alertLevel as alertLevel, ts.code as alertLevelCode, u.nickname userNickname, - c.salesPersonFk + c.salesPersonFk, + z.hour zoneLanding, + HOUR(z.hour) zoneHour, + MINUTE(z.hour) zoneMinute FROM ticket t + LEFT JOIN zone z ON z.id = t.zoneFk LEFT JOIN address a ON a.id = t.addressFk LEFT JOIN province p ON p.id = a.provinceFk LEFT JOIN warehouse w ON w.id = t.warehouseFk diff --git a/modules/ticket/front/index/index.html b/modules/ticket/front/index/index.html index a438d9359..fae2cf923 100644 --- a/modules/ticket/front/index/index.html +++ b/modules/ticket/front/index/index.html @@ -2,8 +2,9 @@ vn-id="model" url="/ticket/api/Tickets/filter" limit="20" + params="::$ctrl.params" data="tickets" - order="shipped DESC, clientFk" + order="shipped DESC, zoneHour ASC, zoneMinute ASC, clientFk" auto-load="false">
@@ -50,6 +51,8 @@ Agency Warehouse Invoice + Zone Hour + Zone Minute Total @@ -120,6 +123,8 @@ {{::ticket.agencyMode}} {{::ticket.warehouse}} {{::ticket.refFk | dashIfEmpty}} + {{::ticket.zoneLanding | dateTime: 'HH'}} + {{::ticket.zoneLanding | dateTime: 'mm'}} {{::ticket.total | currency: 'EUR': 2}}