add: community search
This commit is contained in:
parent
1b77fef470
commit
5109ac65f4
10 changed files with 167 additions and 12 deletions
|
@ -45,6 +45,7 @@ pub fn routes() -> Router {
|
|||
.route("/@{username}/followers", get(profile::followers_request))
|
||||
// communities
|
||||
.route("/communities", get(communities::list_request))
|
||||
.route("/communities/search", get(communities::search_request))
|
||||
.route("/community/{title}", get(communities::feed_request))
|
||||
.route(
|
||||
"/community/{title}/manage",
|
||||
|
@ -74,3 +75,11 @@ pub struct PaginatedQuery {
|
|||
#[serde(default)]
|
||||
pub page: usize,
|
||||
}
|
||||
|
||||
#[derive(Deserialize)]
|
||||
pub struct SearchedQuery {
|
||||
#[serde(default)]
|
||||
pub text: String,
|
||||
#[serde(default)]
|
||||
pub page: usize,
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue