Updated user scheme
Forgot password and username
This commit is contained in:
@@ -33,6 +33,7 @@ pub struct User {
|
||||
pub first_name: String,
|
||||
pub last_name: String,
|
||||
pub is_admin: bool,
|
||||
pub pwd: String,
|
||||
}
|
||||
|
||||
#[derive(Deserialize, Serialize, Debug)]
|
||||
@@ -47,3 +48,25 @@ pub struct TicketCreateScheme {
|
||||
pub struct TicketUpdateScheme {
|
||||
pub status: String,
|
||||
}
|
||||
|
||||
#[derive(Deserialize, Serialize, Debug)]
|
||||
pub struct UserCreateScheme {
|
||||
pub first_name: String,
|
||||
pub last_name: String,
|
||||
pub username: String,
|
||||
pub is_admin: bool,
|
||||
pub pwd: String,
|
||||
}
|
||||
|
||||
#[derive(Deserialize, Serialize, Debug)]
|
||||
pub struct LoginScheme {
|
||||
pub username: String,
|
||||
pub pwd: String,
|
||||
}
|
||||
|
||||
#[derive(Debug, Serialize, Deserialize, Clone)]
|
||||
pub struct Claims {
|
||||
pub subject: String,
|
||||
pub issued: usize,
|
||||
pub expires: usize,
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user