Compare commits
4 Commits
3fae599c6f
...
f4f1e4b96f
| Author | SHA1 | Date | |
|---|---|---|---|
|
f4f1e4b96f
|
|||
|
1bf5c0f2da
|
|||
|
773d8dffd1
|
|||
|
fb3afaf31c
|
2
.gitignore
vendored
2
.gitignore
vendored
@@ -16,3 +16,5 @@ config.ron
|
|||||||
config.toml
|
config.toml
|
||||||
config.yaml
|
config.yaml
|
||||||
config.yml
|
config.yml
|
||||||
|
|
||||||
|
/migrations/.diesel_lock
|
||||||
|
|||||||
3
Cargo.lock
generated
3
Cargo.lock
generated
@@ -325,6 +325,7 @@ dependencies = [
|
|||||||
"iana-time-zone",
|
"iana-time-zone",
|
||||||
"js-sys",
|
"js-sys",
|
||||||
"num-traits",
|
"num-traits",
|
||||||
|
"serde",
|
||||||
"wasm-bindgen",
|
"wasm-bindgen",
|
||||||
"windows-link",
|
"windows-link",
|
||||||
]
|
]
|
||||||
@@ -738,6 +739,7 @@ checksum = "29fe29a87fb84c631ffb3ba21798c4b1f3a964701ba78f0dce4bf8668562ec88"
|
|||||||
dependencies = [
|
dependencies = [
|
||||||
"bitflags",
|
"bitflags",
|
||||||
"byteorder",
|
"byteorder",
|
||||||
|
"chrono",
|
||||||
"diesel_derives",
|
"diesel_derives",
|
||||||
"downcast-rs",
|
"downcast-rs",
|
||||||
"itoa",
|
"itoa",
|
||||||
@@ -2306,6 +2308,7 @@ dependencies = [
|
|||||||
name = "libretunes"
|
name = "libretunes"
|
||||||
version = "0.1.0"
|
version = "0.1.0"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
|
"chrono",
|
||||||
"config",
|
"config",
|
||||||
"diesel",
|
"diesel",
|
||||||
"diesel-async",
|
"diesel-async",
|
||||||
|
|||||||
@@ -9,8 +9,9 @@ edition = "2024"
|
|||||||
build = "src/build.rs"
|
build = "src/build.rs"
|
||||||
|
|
||||||
[dependencies]
|
[dependencies]
|
||||||
|
chrono = { version = "0.4.45", features = ["serde"] }
|
||||||
config = { version = "0.15.24", optional = true }
|
config = { version = "0.15.24", optional = true }
|
||||||
diesel = { version = "2.3.10", optional = true }
|
diesel = { version = "2.3.10", optional = true, features = ["chrono"] }
|
||||||
diesel-async = { version = "0.9.1", optional = true, features = ["postgres", "deadpool", "migrations"] }
|
diesel-async = { version = "0.9.1", optional = true, features = ["postgres", "deadpool", "migrations"] }
|
||||||
diesel_migrations = { version = "2.3.2", optional = true }
|
diesel_migrations = { version = "2.3.2", optional = true }
|
||||||
dioxus = { version = "0.7.9", features = ["router", "fullstack"] }
|
dioxus = { version = "0.7.9", features = ["router", "fullstack"] }
|
||||||
|
|||||||
@@ -0,0 +1,2 @@
|
|||||||
|
DROP INDEX users_username_idx;
|
||||||
|
DROP TABLE users;
|
||||||
@@ -0,0 +1,8 @@
|
|||||||
|
CREATE TABLE users (
|
||||||
|
id INTEGER PRIMARY KEY UNIQUE NOT NULL GENERATED ALWAYS AS IDENTITY,
|
||||||
|
username VARCHAR UNIQUE NOT NULL,
|
||||||
|
hashed_password VARCHAR NOT NULL,
|
||||||
|
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW()
|
||||||
|
);
|
||||||
|
|
||||||
|
CREATE UNIQUE INDEX users_username_idx ON users(username);
|
||||||
@@ -3,9 +3,11 @@ pub mod app;
|
|||||||
pub mod components;
|
pub mod components;
|
||||||
pub mod models;
|
pub mod models;
|
||||||
pub mod pages;
|
pub mod pages;
|
||||||
pub mod schema;
|
|
||||||
pub mod util;
|
pub mod util;
|
||||||
|
|
||||||
|
#[cfg(feature = "server")]
|
||||||
|
pub mod schema;
|
||||||
|
|
||||||
#[cfg(feature = "server")]
|
#[cfg(feature = "server")]
|
||||||
pub mod server;
|
pub mod server;
|
||||||
|
|
||||||
|
|||||||
@@ -1 +1,10 @@
|
|||||||
// @generated automatically by Diesel CLI.
|
// @generated automatically by Diesel CLI.
|
||||||
|
|
||||||
|
diesel::table! {
|
||||||
|
users (id) {
|
||||||
|
id -> Int4,
|
||||||
|
username -> Varchar,
|
||||||
|
hashed_password -> Varchar,
|
||||||
|
created_at -> Timestamptz,
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user