use chrono::{DateTime, Utc};
use serde_derive::Deserialize;
use serde_json::Value;
#[derive(Debug, Clone)]
pub enum EventKind {
#[cfg(feature = "github")]
PR,
#[cfg(feature = "github")]
PrComment,
#[cfg(feature = "github")]
PrEvent,
}
#[derive(Debug, Clone)]
pub struct Event {
pub kind: EventKind,
pub id: String,
pub parent_event_id: Option<String>,
pub name: String,
pub link: Option<String>,
pub date: Option<DateTime<Utc>>,
pub priority: usize,
pub row_data: Value, }
#[derive(Debug, Deserialize, Clone)]
pub enum Operation {
#[serde(rename = "=")]
Equal,
#[serde(rename = "~")]
Contains,
}
#[derive(Debug, Deserialize, Clone)]
pub struct Filter {
pub query: String,
pub values: Vec<String>,
pub operation: Operation,
}