Add generated database entity, just recipe and fix config table missing PK

This commit is contained in:
GW_MC
2025-11-13 20:13:05 +08:00
parent 7a1617e1ee
commit 25c0756e70
9 changed files with 96 additions and 1 deletions

View File

@@ -22,7 +22,12 @@ impl MigrationTrait for Migration {
Table::create()
.table(Config::Table)
.if_not_exists()
.col(ColumnDef::new(Config::Key).string().not_null().unique_key())
.col(
ColumnDef::new(Config::Key)
.string()
.not_null()
.primary_key(),
)
.col(ColumnDef::new(Config::Value).string().not_null())
.col(
ColumnDef::new(Config::CreatedAt)