termreportlib/dto/
report_response.rs

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
use serde::{Deserialize, Serialize};
use uuid::Uuid;
use crate::enums::report_status::ReportStatus;
use crate::enums::term_type::TermType;
use crate::jsonb::rubric_response::RubricResponse;

#[derive(Serialize, Deserialize, Debug, Clone)]
#[serde(rename_all = "camelCase")]
pub struct ReportResponse {
    pub id: Uuid,
    pub org_id: Uuid,
    pub template_id: Uuid,
    pub student_id: Uuid,
    pub reporter: Uuid,
    pub rubrics: Vec<RubricResponse>,
    pub status: ReportStatus,
    pub term_id: Uuid,
    pub term_type: TermType,
    #[serde(skip_serializing_if = "Option::is_none")]
    pub path: Option<String>,
}