feat: refs #6275 getTickets con los campos de silex
gitea/salix/pipeline/head This commit looks good
Details
gitea/salix/pipeline/head This commit looks good
Details
This commit is contained in:
parent
aa0794e136
commit
4071c06b5f
|
@ -3,7 +3,7 @@ const ParameterizedSQL = require('loopback-connector').ParameterizedSQL;
|
|||
|
||||
module.exports = Self => {
|
||||
Self.remoteMethod('getTickets', {
|
||||
description: 'Return the tickets information displayed on the route module',
|
||||
description: 'Find all instances of the model matched by filter from the data source.',
|
||||
accessType: 'READ',
|
||||
accepts: [
|
||||
{
|
||||
|
@ -55,7 +55,12 @@ module.exports = Self => {
|
|||
c.phone ClientPhone,
|
||||
c.mobile ClientMobile,
|
||||
a.phone AddressPhone,
|
||||
a.mobile AddressMobile
|
||||
a.mobile AddressMobile,
|
||||
a.longitude,
|
||||
a.latitude,
|
||||
wm.mediaValue SalePersonPhone,
|
||||
t.cmrFk,
|
||||
t.isSigned Signed
|
||||
FROM vn.route r
|
||||
JOIN ticket t ON t.routeFk = r.id
|
||||
JOIN client c ON t.clientFk = c.id
|
||||
|
@ -70,7 +75,8 @@ module.exports = Self => {
|
|||
LEFT JOIN address a ON a.id = t.addressFk
|
||||
LEFT JOIN agencyMode am ON am.id = t.agencyModeFk
|
||||
LEFT JOIN account.user u ON u.id = r.workerFk
|
||||
LEFT JOIN vehicle v ON v.id = r.vehicleFk`
|
||||
LEFT JOIN vehicle v ON v.id = r.vehicleFk
|
||||
LEFT JOIN workerMedia wm ON wm.workerFk = c.salesPersonFk`
|
||||
);
|
||||
|
||||
if (!filter.where) filter.where = {};
|
||||
|
|
Loading…
Reference in New Issue