#![doc = include_str!("../docs/lib.md")]
#[macro_use]
extern crate diesel;
pub mod datetime;
mod error;
mod filter;
mod sort;
pub mod helper;
pub mod access_control;
use ::rocket::serde::json::Json;
pub use access_control::*;
pub use error::*;
pub use filter::*;
pub use sort::*;
pub use rp1_macros::crud;
pub trait CrudStruct {
type TableType;
}
pub trait CrudInsertable {
type InsertType;
}
pub trait CrudUpdatable {
type PatchType;
type PutType;
}
pub trait CrudFilterSpec {
type FilterSpecType;
}
pub type CrudResult<T, E = crate::CrudError> = Result<T, E>;
pub type CrudJsonResult<T, E = crate::CrudError> = Result<Json<T>, E>;