"""创建第二阶段材料识别与服务申请表。"""

from alembic import op

from zbt.infrastructure.mysql.core_models import CoreBase

revision = "core_0006"
down_revision = "core_0005"
branch_labels = None
depends_on = None


def upgrade() -> None:
    bind = op.get_bind()
    CoreBase.metadata.tables["material_recognitions"].create(bind=bind)
    CoreBase.metadata.tables["service_requests"].create(bind=bind)


def downgrade() -> None:
    bind = op.get_bind()
    CoreBase.metadata.tables["service_requests"].drop(bind=bind)
    CoreBase.metadata.tables["material_recognitions"].drop(bind=bind)
