mirror of
https://github.com/TheAnachronism/docspell.git
synced 2025-04-05 10:59:33 +00:00
Allow to query custom field values with wildcards
This commit is contained in:
parent
473985c80e
commit
9bea0298ad
@ -1299,6 +1299,10 @@ paths:
|
|||||||
|
|
||||||
The `fulltext` field can be used to restrict the results by
|
The `fulltext` field can be used to restrict the results by
|
||||||
using full-text search in the documents contents.
|
using full-text search in the documents contents.
|
||||||
|
|
||||||
|
The customfields used in the search query are allowed to be
|
||||||
|
specified by either field id or field name. The values may
|
||||||
|
contain the wildcard `*` at beginning or end.
|
||||||
security:
|
security:
|
||||||
- authTokenHeader: []
|
- authTokenHeader: []
|
||||||
requestBody:
|
requestBody:
|
||||||
@ -1920,7 +1924,8 @@ paths:
|
|||||||
summary: Set the value of a custom field.
|
summary: Set the value of a custom field.
|
||||||
description: |
|
description: |
|
||||||
Sets the value for a custom field to this item. If a value
|
Sets the value for a custom field to this item. If a value
|
||||||
already exists, it is overwritten.
|
already exists, it is overwritten. A value must comply to the
|
||||||
|
type of the associated field. It must not be the empty string.
|
||||||
security:
|
security:
|
||||||
- authTokenHeader: []
|
- authTokenHeader: []
|
||||||
parameters:
|
parameters:
|
||||||
@ -2389,7 +2394,9 @@ paths:
|
|||||||
summary: Set the value of a custom field for multiple items
|
summary: Set the value of a custom field for multiple items
|
||||||
description: |
|
description: |
|
||||||
Sets the value for a custom field to multiple given items. If
|
Sets the value for a custom field to multiple given items. If
|
||||||
a value already exists, it is overwritten.
|
a value already exists, it is overwritten. The value must
|
||||||
|
comply to the associated field type. It must not be the empty
|
||||||
|
string.
|
||||||
security:
|
security:
|
||||||
- authTokenHeader: []
|
- authTokenHeader: []
|
||||||
requestBody:
|
requestBody:
|
||||||
|
@ -289,7 +289,7 @@ object QItem {
|
|||||||
and(
|
and(
|
||||||
cfColl.is(coll),
|
cfColl.is(coll),
|
||||||
or(cfName.is(v.field), cfId.is(v.field)),
|
or(cfName.is(v.field), cfId.is(v.field)),
|
||||||
cvValue.is(v.value)
|
cvValue.lowerLike(QueryWildcard(v.value.toLowerCase))
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
if (cv.isEmpty) Seq.empty
|
if (cv.isEmpty) Seq.empty
|
||||||
|
Loading…
x
Reference in New Issue
Block a user