2020-09-29 21:27:11 +00:00
|
|
|
use chrono::{DateTime, Utc};
|
2020-09-29 00:33:43 +00:00
|
|
|
use serde::{Deserialize, Serialize};
|
|
|
|
use sqlx::{self, FromRow};
|
|
|
|
|
|
|
|
#[derive(Clone, Serialize, Deserialize, Debug, FromRow)]
|
|
|
|
pub struct RawPage {
|
|
|
|
id: i64,
|
|
|
|
slug: String,
|
|
|
|
title: String,
|
|
|
|
note_id: i64,
|
2020-09-29 21:27:11 +00:00
|
|
|
creation_date: DateTime<Utc>,
|
|
|
|
updated_date: DateTime<Utc>,
|
|
|
|
lastview_date: DateTime<Utc>,
|
|
|
|
deleted_date: DateTime<Utc>,
|
2020-09-29 00:33:43 +00:00
|
|
|
}
|
2020-09-29 14:44:43 +00:00
|
|
|
|
|
|
|
#[derive(Clone, Serialize, Deserialize, Debug, FromRow)]
|
|
|
|
pub struct RawNote {
|
|
|
|
id: i64,
|
|
|
|
uuid: String,
|
|
|
|
content: String,
|
|
|
|
notetype: String,
|
2020-09-29 21:27:11 +00:00
|
|
|
creation_date: DateTime<Utc>,
|
|
|
|
updated_date: DateTime<Utc>,
|
|
|
|
lastview_date: DateTime<Utc>,
|
|
|
|
deleted_date: DateTime<Utc>,
|
2020-09-29 14:44:43 +00:00
|
|
|
}
|