1
0
mirror of https://gitlab.com/comunic/comunicapiv3 synced 2025-06-21 00:45:18 +00:00

Can create a comment

This commit is contained in:
2020-07-10 08:21:40 +02:00
parent 0aa6c0193f
commit c90f74e782
7 changed files with 102 additions and 4 deletions

View File

@ -36,4 +36,5 @@ pub mod survey_choice_api;
pub mod survey_api;
pub mod comment_api;
pub mod res_create_post;
pub mod posts_targets_api;
pub mod posts_targets_api;
pub mod res_create_comment;

View File

@ -0,0 +1,20 @@
//! # Comment creation result
//!
//! @author Pierre Hubert
use serde::Serialize;
#[derive(Serialize)]
#[allow(non_snake_case)]
pub struct ResCreateComment {
success: bool,
commentID: u64,
}
impl ResCreateComment {
pub fn new(comment_id: u64) -> ResCreateComment {
ResCreateComment {
success: true,
commentID: comment_id,
}
}
}