mirror of
https://gitlab.com/comunic/comunicapiv3
synced 2025-01-14 14:37:44 +00:00
Ready to implement new method
This commit is contained in:
parent
3ee2e1843a
commit
59961129c5
@ -15,3 +15,4 @@ pub mod surveys_controller;
|
||||
pub mod notifications_controller;
|
||||
pub mod movies_controller;
|
||||
pub mod virtual_directory_controller;
|
||||
pub mod web_app_controller;
|
@ -1,6 +1,6 @@
|
||||
use std::error::Error;
|
||||
|
||||
use crate::controllers::{account_controller, comments_controller, conversations_controller, friends_controller, groups_controller, likes_controller, movies_controller, notifications_controller, posts_controller, search_controller, server_controller, surveys_controller, user_controller, virtual_directory_controller};
|
||||
use crate::controllers::{account_controller, comments_controller, conversations_controller, friends_controller, groups_controller, likes_controller, movies_controller, notifications_controller, posts_controller, search_controller, server_controller, surveys_controller, user_controller, virtual_directory_controller, web_app_controller};
|
||||
use crate::controllers::routes::Method::{GET, POST};
|
||||
use crate::data::http_request_handler::HttpRequestHandler;
|
||||
|
||||
@ -266,5 +266,9 @@ pub fn get_routes() -> Vec<Route> {
|
||||
Route::post("/user/findbyfolder", Box::new(virtual_directory_controller::find_user)),
|
||||
|
||||
Route::post("/virtualDirectory/find", Box::new(virtual_directory_controller::find)),
|
||||
|
||||
|
||||
// Web application controller
|
||||
Route::post("/webApp/getMemberships", Box::new(web_app_controller::get_memberships)),
|
||||
]
|
||||
}
|
11
src/controllers/web_app_controller.rs
Normal file
11
src/controllers/web_app_controller.rs
Normal file
@ -0,0 +1,11 @@
|
||||
//! # Web application controller
|
||||
//!
|
||||
//! @author Pierre Hubert
|
||||
|
||||
use crate::controllers::routes::RequestResult;
|
||||
use crate::data::http_request_handler::HttpRequestHandler;
|
||||
|
||||
/// Get the list of memberships of a given user
|
||||
pub fn get_memberships(r: &mut HttpRequestHandler) -> RequestResult {
|
||||
r.success("Implement me")
|
||||
}
|
Loading…
Reference in New Issue
Block a user