mirror of
https://github.com/lennart-k/rustical.git
synced 2025-12-14 10:32:19 +00:00
Move ical-related stuff to rustical_ical crate
This commit is contained in:
20
crates/store/src/addressbook.rs
Normal file
20
crates/store/src/addressbook.rs
Normal file
@@ -0,0 +1,20 @@
|
||||
use crate::synctoken::format_synctoken;
|
||||
use chrono::NaiveDateTime;
|
||||
use serde::Serialize;
|
||||
|
||||
#[derive(Debug, Clone, Serialize)]
|
||||
pub struct Addressbook {
|
||||
pub id: String,
|
||||
pub principal: String,
|
||||
pub displayname: Option<String>,
|
||||
pub description: Option<String>,
|
||||
pub deleted_at: Option<NaiveDateTime>,
|
||||
pub synctoken: i64,
|
||||
pub push_topic: String,
|
||||
}
|
||||
|
||||
impl Addressbook {
|
||||
pub fn format_synctoken(&self) -> String {
|
||||
format_synctoken(self.synctoken)
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user