From 37546e7a26496c2803370cdc1dac67f61148e825 Mon Sep 17 00:00:00 2001 From: Gerard Date: Fri, 22 Mar 2019 12:34:42 +0100 Subject: [PATCH] #1236 revision con pepe --- modules/route/back/methods/route/summary.js | 11 +++++-- modules/route/front/index/index.html | 4 +-- modules/route/front/index/style.scss | 5 ++++ modules/route/front/summary/index.html | 32 ++++++++++++++------- modules/route/front/summary/locale/es.yml | 7 +++-- modules/route/front/summary/style.scss | 7 ++++- modules/ticket/back/models/ticket.json | 3 ++ 7 files changed, 50 insertions(+), 19 deletions(-) create mode 100644 modules/route/front/index/style.scss diff --git a/modules/route/back/methods/route/summary.js b/modules/route/back/methods/route/summary.js index 0aad8f6bb..ee36d4647 100644 --- a/modules/route/back/methods/route/summary.js +++ b/modules/route/back/methods/route/summary.js @@ -29,11 +29,12 @@ module.exports = Self => { {relation: 'ticket', scope: { fields: ['id', 'packages', 'warehouseFk', 'nickname', 'clientFk', 'priority'], + order: 'priority', include: [ { relation: 'client', scope: { - fields: ['id', 'street'], + fields: ['id', 'street', 'postcode'], } }, { @@ -48,6 +49,12 @@ module.exports = Self => { scope: { fields: ['id', 'name'] } + }, + { + relation: 'notes', + scope: { + where: {observationTypeFk: 3} + } } ] @@ -73,7 +80,7 @@ module.exports = Self => { }, { relation: 'vehicle', scope: { - fields: ['id', 'm3'] + fields: ['id', 'm3', 'numberPlate'] } } ], diff --git a/modules/route/front/index/index.html b/modules/route/front/index/index.html index 5d46af81d..cada445ca 100644 --- a/modules/route/front/index/index.html +++ b/modules/route/front/index/index.html @@ -18,7 +18,7 @@ - + @@ -66,7 +66,7 @@ vn-id="summary" class="dialog-summary"> - + + value="{{$ctrl.summary.route.vehicle.numberPlate}}"> @@ -26,7 +26,7 @@ value="{{$ctrl.summary.route.time | dateTime: 'HH:MM'}}"> + value="{{$ctrl.summary.route.finished | dateTime: 'HH:MM'}}"> @@ -54,17 +54,20 @@ + Order Ticket id Alias - Packages - Volume - Warehouse - Street - State + Packages + + Warehouse + PC + Street + + {{ticket.priority}} - {{ticket.packages}} - {{ticket.volume}} - {{ticket.warehouse.name}} + {{ticket.packages}} + {{ticket.volume}} + {{ticket.warehouse.name}} + {{ticket.client.postcode}} {{ticket.client.street}} - {{ticket.state.state.name}} + + + + diff --git a/modules/route/front/summary/locale/es.yml b/modules/route/front/summary/locale/es.yml index 0853f047c..2ea8ec25a 100644 --- a/modules/route/front/summary/locale/es.yml +++ b/modules/route/front/summary/locale/es.yml @@ -1,7 +1,8 @@ Driver: Conductor Vehicle: Vehículo Packages: Bultos -Time: F. Inicio -Finished: F. Fin +Time: H. Inicio +Finished: H. Fin Km Start: Km de inicio -Km End: Km de fin \ No newline at end of file +Km End: Km de fin +PC: CP \ No newline at end of file diff --git a/modules/route/front/summary/style.scss b/modules/route/front/summary/style.scss index 7ff8b3056..aef44fbf9 100644 --- a/modules/route/front/summary/style.scss +++ b/modules/route/front/summary/style.scss @@ -1,5 +1,10 @@ -@import "./variables"; +@import "variables"; + vn-route-summary .summary { max-width: $width-large; + + vn-icon[icon=insert_drive_file]{ + color: $color-font-secondary; + } } \ No newline at end of file diff --git a/modules/ticket/back/models/ticket.json b/modules/ticket/back/models/ticket.json index beb9cdbd0..c60b98364 100644 --- a/modules/ticket/back/models/ticket.json +++ b/modules/ticket/back/models/ticket.json @@ -36,6 +36,9 @@ }, "isDeleted": { "type": "boolean" + }, + "priority": { + "type": "Number" } }, "relations": {