mirror of
https://github.com/meilisearch/MeiliSearch
synced 2025-07-04 04:17:10 +02:00
add the searches route and fix a few broken things
This commit is contained in:
parent
78f6f22a80
commit
04e4586fb3
8 changed files with 196 additions and 43 deletions
|
@ -16,7 +16,6 @@ use std::ops::Deref;
|
|||
use std::str::FromStr;
|
||||
|
||||
use deserr::{DeserializeError, Deserr, MergeWithError, ValueKind};
|
||||
use utoipa::{PartialSchema, ToSchema};
|
||||
|
||||
use super::{DeserrParseBoolError, DeserrParseIntError};
|
||||
use crate::index_uid::IndexUid;
|
||||
|
@ -30,18 +29,6 @@ use crate::tasks::{Kind, Status};
|
|||
#[derive(Default, Debug, Clone, Copy)]
|
||||
pub struct Param<T>(pub T);
|
||||
|
||||
impl<T: ToSchema> ToSchema for Param<T> {
|
||||
fn name() -> std::borrow::Cow<'static, str> {
|
||||
T::name()
|
||||
}
|
||||
}
|
||||
|
||||
impl<T: PartialSchema> PartialSchema for Param<T> {
|
||||
fn schema() -> utoipa::openapi::RefOr<utoipa::openapi::schema::Schema> {
|
||||
T::schema()
|
||||
}
|
||||
}
|
||||
|
||||
impl<T> Deref for Param<T> {
|
||||
type Target = T;
|
||||
|
||||
|
|
|
@ -6,7 +6,7 @@ use std::str::FromStr;
|
|||
use deserr::{DeserializeError, Deserr, MergeWithError, ValueKind};
|
||||
use serde::de::Visitor;
|
||||
use serde::{Deserialize, Deserializer, Serialize, Serializer};
|
||||
use utoipa::{IntoParams, PartialSchema, ToSchema};
|
||||
use utoipa::PartialSchema;
|
||||
|
||||
use crate::deserr::query_params::FromQueryParameter;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue