Add back document ids

This commit is contained in:
Andras Schmelczer 2024-12-15 11:45:53 +00:00
parent cd46acd130
commit c567cec656
No known key found for this signature in database
GPG key ID: FC8F2C3D3D1A718C
9 changed files with 293 additions and 116 deletions

View file

@ -4,10 +4,19 @@ use serde::{self, Deserialize};
use crate::database::models::VaultUpdateId;
#[derive(Debug, Deserialize, JsonSchema)]
#[serde(rename_all = "camelCase")]
pub struct CreateDocumentVersion {
pub relative_path: String,
pub created_date: DateTime<Utc>,
pub content_base64: String,
}
#[derive(Debug, Deserialize, JsonSchema)]
#[serde(rename_all = "camelCase")]
pub struct UpdateDocumentVersion {
pub parent_version_id: Option<VaultUpdateId>,
pub parent_version_id: VaultUpdateId,
pub relative_path: String,
pub created_date: DateTime<Utc>,
pub content_base64: String,
}
@ -15,5 +24,6 @@ pub struct UpdateDocumentVersion {
#[derive(Debug, Deserialize, JsonSchema)]
#[serde(rename_all = "camelCase")]
pub struct DeleteDocumentVersion {
pub relative_path: String,
pub created_date: DateTime<Utc>,
}