mirror of
				https://gitlab.com/comunic/comunicapiv3
				synced 2025-10-29 22:54:43 +00:00 
			
		
		
		
	Ready to implement new route
This commit is contained in:
		| @@ -48,8 +48,12 @@ pub fn create(r: &mut HttpRequestHandler) -> RequestResult { | ||||
|  | ||||
| /// Get the list of conversations of a user | ||||
| pub fn get_list(r: &mut HttpRequestHandler) -> RequestResult { | ||||
|  | ||||
|     let list = conversations_helper::get_list_user(r.user_id()?)?; | ||||
|  | ||||
|     r.set_response(list.iter().map(|c| ConversationAPI::new(c)).collect::<Vec<ConversationAPI>>()) | ||||
| } | ||||
|  | ||||
| /// Get information about a single conversation | ||||
| pub fn get_single(r: &mut HttpRequestHandler) -> RequestResult { | ||||
|     r.success("Implement id") | ||||
| } | ||||
| @@ -93,6 +93,9 @@ pub fn get_routes() -> Vec<Route> { | ||||
|  | ||||
|         Route::post("/conversations/getList", Box::new(conversations_controller::get_list)), | ||||
|  | ||||
|         Route::post("/conversations/getInfoOne", Box::new(conversations_controller::get_single)), | ||||
|         Route::post("/conversations/getInfosOne", Box::new(conversations_controller::get_single)), | ||||
|  | ||||
|  | ||||
|         // Virtual directory controller | ||||
|         Route::post("/user/findbyfolder", Box::new(virtual_directory_controller::find_user)), | ||||
|   | ||||
		Reference in New Issue
	
	Block a user