"""add certificate course period

Revision ID: 20260813_0006
Revises: 20260623_0005
Create Date: 2026-08-13
"""

from typing import Sequence, Union

from alembic import op
import sqlalchemy as sa

revision: str = "20260813_0006"
down_revision: Union[str, None] = "20260623_0005"
branch_labels: Union[str, Sequence[str], None] = None
depends_on: Union[str, Sequence[str], None] = None


def upgrade() -> None:
    op.add_column("certificates", sa.Column("course_start_date", sa.Date(), nullable=True))
    op.add_column("certificates", sa.Column("course_end_date", sa.Date(), nullable=True))


def downgrade() -> None:
    op.drop_column("certificates", "course_end_date")
    op.drop_column("certificates", "course_start_date")
