T024: add function_type and group start/end dates to function groups UI
This commit is contained in:
@@ -0,0 +1,42 @@
|
||||
"""add_function_type_and_group_dates
|
||||
|
||||
Revision ID: cfe638817921
|
||||
Revises: f5772dd5cd55
|
||||
Create Date: 2026-05-31 21:17:13.064051
|
||||
|
||||
"""
|
||||
from typing import Sequence, Union
|
||||
|
||||
from alembic import op
|
||||
import sqlalchemy as sa
|
||||
|
||||
|
||||
# revision identifiers, used by Alembic.
|
||||
revision: str = 'cfe638817921'
|
||||
down_revision: Union[str, None] = 'f5772dd5cd55'
|
||||
branch_labels: Union[str, Sequence[str], None] = None
|
||||
depends_on: Union[str, Sequence[str], None] = None
|
||||
|
||||
|
||||
def upgrade() -> None:
|
||||
# ### commands auto generated by Alembic - please adjust! ###
|
||||
with op.batch_alter_table('project_function_groups', schema=None) as batch_op:
|
||||
batch_op.add_column(sa.Column('start_date', sa.DateTime(timezone=True), nullable=True))
|
||||
batch_op.add_column(sa.Column('end_date', sa.DateTime(timezone=True), nullable=True))
|
||||
|
||||
with op.batch_alter_table('project_functions', schema=None) as batch_op:
|
||||
batch_op.add_column(sa.Column('function_type', sa.String(length=50), nullable=False))
|
||||
|
||||
# ### end Alembic commands ###
|
||||
|
||||
|
||||
def downgrade() -> None:
|
||||
# ### commands auto generated by Alembic - please adjust! ###
|
||||
with op.batch_alter_table('project_functions', schema=None) as batch_op:
|
||||
batch_op.drop_column('function_type')
|
||||
|
||||
with op.batch_alter_table('project_function_groups', schema=None) as batch_op:
|
||||
batch_op.drop_column('end_date')
|
||||
batch_op.drop_column('start_date')
|
||||
|
||||
# ### end Alembic commands ###
|
||||
Reference in New Issue
Block a user