forked from alemi/upub
fix!: eeehh need to rebuild db anyway coz sqlite
This commit is contained in:
parent
485724701a
commit
1213947495
2 changed files with 0 additions and 39 deletions
|
@ -7,7 +7,6 @@ mod m20240524_000004_create_addressing_deliveries;
|
|||
mod m20240524_000005_create_attachments_tags_mentions;
|
||||
mod m20240529_000001_add_relation_unique_index;
|
||||
mod m20240605_000001_add_jobs_table;
|
||||
mod m20240606_000001_no_unique_index_on_job_activity;
|
||||
|
||||
pub struct Migrator;
|
||||
|
||||
|
@ -22,7 +21,6 @@ impl MigratorTrait for Migrator {
|
|||
Box::new(m20240524_000005_create_attachments_tags_mentions::Migration),
|
||||
Box::new(m20240529_000001_add_relation_unique_index::Migration),
|
||||
Box::new(m20240605_000001_add_jobs_table::Migration),
|
||||
Box::new(m20240606_000001_no_unique_index_on_job_activity::Migration),
|
||||
]
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,37 +0,0 @@
|
|||
use sea_orm_migration::prelude::*;
|
||||
|
||||
use crate::m20240605_000001_add_jobs_table::Jobs;
|
||||
|
||||
#[derive(DeriveMigrationName)]
|
||||
pub struct Migration;
|
||||
|
||||
#[async_trait::async_trait]
|
||||
impl MigrationTrait for Migration {
|
||||
async fn up(&self, manager: &SchemaManager) -> Result<(), DbErr> {
|
||||
manager
|
||||
.drop_index(
|
||||
Index::drop()
|
||||
.name("index-jobs-activity")
|
||||
.table(Jobs::Table)
|
||||
.to_owned()
|
||||
)
|
||||
.await?;
|
||||
|
||||
Ok(())
|
||||
}
|
||||
|
||||
async fn down(&self, manager: &SchemaManager) -> Result<(), DbErr> {
|
||||
manager
|
||||
.create_index(
|
||||
Index::create()
|
||||
.unique()
|
||||
.name("index-jobs-activity")
|
||||
.table(Jobs::Table)
|
||||
.col(Jobs::Activity)
|
||||
.to_owned()
|
||||
)
|
||||
.await?;
|
||||
|
||||
Ok(())
|
||||
}
|
||||
}
|
Loading…
Reference in a new issue