fix: wolves ID is numeric
This commit is contained in:
parent
d634806808
commit
2b86fa58e4
2 changed files with 6 additions and 6 deletions
|
@ -17,7 +17,7 @@ use tide::prelude::*;
|
|||
|
||||
#[derive(Debug, Deserialize, Serialize, sqlx::FromRow)]
|
||||
pub struct AccountWolves {
|
||||
pub id_wolves: String,
|
||||
pub id_wolves: i64,
|
||||
pub id_student: Option<String>,
|
||||
pub email: String,
|
||||
pub expiry: String,
|
||||
|
@ -69,7 +69,7 @@ pub async fn db_init(config: &Config) -> Result<Pool<Sqlite>, Error> {
|
|||
|
||||
sqlx::query(
|
||||
"CREATE TABLE IF NOT EXISTS accounts_wolves (
|
||||
id_wolves text PRIMARY KEY,
|
||||
id_wolves integer PRIMARY KEY,
|
||||
id_student text,
|
||||
email text NOT NULL,
|
||||
expiry text NOT NULL,
|
||||
|
@ -87,7 +87,7 @@ pub async fn db_init(config: &Config) -> Result<Pool<Sqlite>, Error> {
|
|||
date_iso text NOT NULL,
|
||||
date_expiry text NOT NULL,
|
||||
name_first text NOT NULL,
|
||||
name_surname integer NOT NULL,
|
||||
name_surname text NOT NULL,
|
||||
id_student text NOT NULL
|
||||
)",
|
||||
)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue