mirror of
https://github.com/meilisearch/MeiliSearch
synced 2024-11-11 15:38:55 +01:00
Add attributes_to_search_on
This commit is contained in:
parent
362e9ff845
commit
82e1f59f1e
@ -38,6 +38,8 @@ pub struct FacetSearchQuery {
|
|||||||
pub filter: Option<Value>,
|
pub filter: Option<Value>,
|
||||||
#[deserr(default, error = DeserrJsonError<InvalidSearchMatchingStrategy>, default)]
|
#[deserr(default, error = DeserrJsonError<InvalidSearchMatchingStrategy>, default)]
|
||||||
pub matching_strategy: MatchingStrategy,
|
pub matching_strategy: MatchingStrategy,
|
||||||
|
#[deserr(default, error = DeserrJsonError<InvalidAttributesToSearchOn>, default)]
|
||||||
|
pub attributes_to_search_on: Option<Vec<String>>,
|
||||||
}
|
}
|
||||||
|
|
||||||
pub async fn search(
|
pub async fn search(
|
||||||
@ -90,6 +92,7 @@ impl From<FacetSearchQuery> for SearchQuery {
|
|||||||
vector,
|
vector,
|
||||||
filter,
|
filter,
|
||||||
matching_strategy,
|
matching_strategy,
|
||||||
|
attributes_to_search_on,
|
||||||
} = value;
|
} = value;
|
||||||
|
|
||||||
SearchQuery {
|
SearchQuery {
|
||||||
@ -113,6 +116,7 @@ impl From<FacetSearchQuery> for SearchQuery {
|
|||||||
crop_marker: DEFAULT_CROP_MARKER(),
|
crop_marker: DEFAULT_CROP_MARKER(),
|
||||||
matching_strategy,
|
matching_strategy,
|
||||||
vector,
|
vector,
|
||||||
|
attributes_to_search_on,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user