mirror of
https://gitlab.com/comunic/comunicapiv3
synced 2025-06-21 00:45:18 +00:00
Create the conversation
This commit is contained in:
@ -4,7 +4,7 @@
|
||||
|
||||
use crate::data::http_request_handler::HttpRequestHandler;
|
||||
use crate::controllers::routes::RequestResult;
|
||||
use crate::helpers::user_helper;
|
||||
use crate::helpers::{user_helper, conversations_helper};
|
||||
use crate::data::new_conversation::NewConversation;
|
||||
|
||||
/// Create a new conversation
|
||||
@ -39,7 +39,10 @@ pub fn create(r: &mut HttpRequestHandler) -> RequestResult {
|
||||
can_everyone_add_members: r.post_bool_opt("canEveryoneAddMembers", true)
|
||||
};
|
||||
|
||||
println!("Conversation to create: {:#?}", conv);
|
||||
|
||||
// TODO : adapt for API
|
||||
println!("Conversation to create: {:#?}", conv);
|
||||
let conv_id = conversations_helper::create(&conv)?;
|
||||
println!("conv: {}", conv_id);
|
||||
r.success("create")
|
||||
}
|
Reference in New Issue
Block a user