def upgrade():
### commands auto generated by Alembic - please adjust! ###
op.create_table('podcast_language',
sa.Column('id', sa.Integer(), nullable=False),
sa.Column('created_at', sa.DateTime(), nullable=True),
sa.Column('updated_at', sa.DateTime(), nullable=True),
sa.Column('name', sa.String(length=60), nullable=True),
sa.PrimaryKeyConstraint('id')
)
op.create_index(op.f('ix_podcast_language_id'), 'podcast_language', ['id'], unique=False)
op.add_column('podcast', sa.Column('language_id', sa.Integer(), nullable=True))
op.create_foreign_key(None, 'podcast', 'podcast_language', ['language_id'], ['id'])
op.drop_column('podcast', 'language')
### end Alembic commands ###
评论列表
文章目录