User profile and admin privileges

This commit is contained in:
Alphonse Paix
2025-10-01 01:17:59 +02:00
parent 3e81c27ab3
commit 402c560354
22 changed files with 467 additions and 43 deletions

View File

@@ -3,14 +3,13 @@ use uuid::Uuid;
pub struct PostEntry {
pub post_id: Uuid,
pub author: Option<String>,
pub author: String,
pub title: String,
pub content: String,
pub published_at: DateTime<Utc>,
}
impl PostEntry {
#[allow(dead_code)]
pub fn formatted_date(&self) -> String {
self.published_at.format("%B %d, %Y").to_string()
}