Advanced filter by ref
gitea/salix/2150-travel_filter_by_ref This commit looks good
Details
gitea/salix/2150-travel_filter_by_ref This commit looks good
Details
This commit is contained in:
parent
21ace6ef4e
commit
70210e87c9
|
@ -63,6 +63,10 @@ module.exports = Self => {
|
|||
type: 'Number',
|
||||
description: 'The totalEntries filter',
|
||||
http: {source: 'query'}
|
||||
}, {
|
||||
arg: 'ref',
|
||||
type: 'string',
|
||||
description: 'The reference'
|
||||
}
|
||||
],
|
||||
returns: {
|
||||
|
@ -82,7 +86,7 @@ module.exports = Self => {
|
|||
case 'search':
|
||||
return {'t.id': value};
|
||||
case 'ref':
|
||||
return {[param]: {regexp: value}};
|
||||
return {'t.ref': {like: `%${value}%`}};
|
||||
case 'shippedFrom':
|
||||
return {'t.shipped': {gte: value}};
|
||||
case 'shippedTo':
|
||||
|
|
Loading…
Reference in New Issue