ref #5417 date filters added #1773

Merged
jorgep merged 16 commits from 5417-fixCustomerPayments into dev 2023-10-19 06:23:21 +00:00
1 changed files with 1 additions and 2 deletions
Showing only changes of commit a7128b8187 - Show all commits

View File

@ -59,7 +59,7 @@ module.exports = Self => {
if (ctx.args && args.to) { if (ctx.args && args.to) {
const dateTo = args.to; const dateTo = args.to;
dateTo.setHours(23, 59, 0, 0); dateTo.setHours(23, 59, 59, 999);
} }
const where = buildFilter(args, (param, value) => { const where = buildFilter(args, (param, value) => {
@ -72,7 +72,6 @@ module.exports = Self => {
return {'t.amount': (value * 100)}; return {'t.amount': (value * 100)};
case 'from': case 'from':
return {'t.created': {gte: value}}; return {'t.created': {gte: value}};
case 'to': case 'to':
return {'t.created': {lte: value}}; return {'t.created': {lte: value}};
} }