feat: refs #7882 Added volume and timeWindow
gitea/salix/pipeline/pr-master This commit looks good
Details
gitea/salix/pipeline/pr-master This commit looks good
Details
This commit is contained in:
parent
b40ecf9e19
commit
ef4ea588ca
|
@ -48,9 +48,11 @@ module.exports = Self => {
|
|||
t.shipped date,
|
||||
'PEDIDO' operation,
|
||||
t.totalWithVat totalAmount,
|
||||
t.totalWithoutVat totalAmountWithoutTaxes
|
||||
t.totalWithoutVat totalAmountWithoutTaxes,
|
||||
SUM(sv.volume) volume
|
||||
FROM ticket t
|
||||
JOIN address a ON a.id = t.addressFk
|
||||
JOIN saleVolume sv ON sv.ticketFk = t.id
|
||||
WHERE t.id IN (?)
|
||||
GROUP BY t.id
|
||||
`, [tickets]);
|
||||
|
@ -63,7 +65,15 @@ module.exports = Self => {
|
|||
code: order.code.toString(),
|
||||
date: moment(order.date).format('YYYY-MM-DD'),
|
||||
totalAmount: order.totalAmount || undefined,
|
||||
totalAmountWithoutTaxes: order.totalAmountWithoutTaxes || undefined
|
||||
totalAmountWithoutTaxes: order.totalAmountWithoutTaxes || undefined,
|
||||
timeWindow: [{
|
||||
from: '07:00',
|
||||
to: '20:00'
|
||||
}],
|
||||
orderMeasures: [{
|
||||
constraintId: 3, // Volumen
|
||||
value: order.volume
|
||||
}]
|
||||
};
|
||||
});
|
||||
|
||||
|
|
Loading…
Reference in New Issue