freechat/server/src/schema.rs
shockrah 895d7246f0 auth::create_new_session_key => impl not tested
auth::login now generates a 500 on db insertion failure
auth::login returning single json value instead of full struct
2020-05-19 20:13:56 -07:00

43 lines
710 B
Rust

table! {
channels (id) {
id -> Integer,
name -> Varchar,
permissions -> Integer,
limit -> Integer,
#[sql_name = "type"]
type_ -> Integer,
}
}
table! {
invites (id) {
id -> Unsigned<Bigint>,
expires -> Unsigned<Bigint>,
uses -> Integer,
}
}
table! {
sessions (secret) {
secret -> Varchar,
expires -> Unsigned<Bigint>,
}
}
table! {
users (id) {
id -> Unsigned<Bigint>,
name -> Varchar,
secret -> Varchar,
date -> Unsigned<Bigint>,
status -> Integer,
}
}
allow_tables_to_appear_in_same_query!(
channels,
invites,
sessions,
users,
);