changed model fields to pub
struct Invite now insertable
This commit is contained in:
parent
c5461f16ad
commit
1e1b9d4f72
@ -1,15 +1,16 @@
|
|||||||
#[derive(Serialize, Deserialize, Queryable)]
|
use crate::schema::invites;
|
||||||
pub struct InviteView {
|
#[derive(Insertable, Serialize, Deserialize, Queryable)]
|
||||||
|
pub struct Invite {
|
||||||
pub id: u64,
|
pub id: u64,
|
||||||
expire: u64,
|
pub expires: u64,
|
||||||
uses: Option<i32>,
|
pub uses: Option<i32>,
|
||||||
}
|
}
|
||||||
|
|
||||||
#[derive(Serialize, Deserialize, Queryable)]
|
#[derive(Serialize, Deserialize, Queryable)]
|
||||||
pub struct UserView {
|
pub struct UserView {
|
||||||
id: i64,
|
pub id: i64,
|
||||||
username: String,
|
pub username: String,
|
||||||
display: Option<String>,
|
pub display: Option<String>,
|
||||||
password: String,
|
pub password: String,
|
||||||
email: Option<String>,
|
pub email: Option<String>,
|
||||||
}
|
}
|
Loading…
Reference in New Issue
Block a user