Added report marker functions and stale time param to CoT type

This commit is contained in:
2026-05-11 16:25:52 -03:00
parent 6b3ce96c18
commit 882a35c2cd
9 changed files with 168 additions and 6 deletions
+4 -2
View File
@@ -18,6 +18,7 @@ pub struct CursorOverTime {
pub link_uid: Option<String>,
pub remarker: Option<String>,
pub video_url: Option<String>,
pub stale_seconds: Option<i64>,
}
impl CursorOverTime {
@@ -34,8 +35,9 @@ impl CursorOverTime {
let created_time = Utc::now().to_rfc3339_opts(SecondsFormat::Millis, true);
let stale_time =
(Utc::now() + Duration::seconds(360)).to_rfc3339_opts(SecondsFormat::Millis, true);
let stale_seconds = self.stale_seconds.unwrap_or(360).max(1);
let stale_time = (Utc::now() + Duration::seconds(stale_seconds))
.to_rfc3339_opts(SecondsFormat::Millis, true);
let mut xml = String::new();