diff options
Diffstat (limited to 'src/database/user.rs')
-rw-r--r-- | src/database/user.rs | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/database/user.rs b/src/database/user.rs index ff7b1ab..d3202ce 100644 --- a/src/database/user.rs +++ b/src/database/user.rs @@ -1,6 +1,7 @@ use crate::database::DatabaseWrapper; use serde::{Deserialize, Serialize}; use sqlx::mysql::MySqlQueryResult; +use utoipa::ToSchema; #[derive(Deserialize, Serialize)] pub struct User { @@ -9,9 +10,11 @@ pub struct User { password: Option<String>, } -#[derive(Deserialize, Serialize)] +#[derive(Deserialize, Serialize, ToSchema)] pub struct UserForm { + #[schema(example = "username")] name: Option<String>, + #[schema(example = "password")] password: Option<String>, } |