-
Notifications
You must be signed in to change notification settings - Fork 40
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
21539 - Short name refund history support (#1757)
- Loading branch information
Showing
12 changed files
with
247 additions
and
35 deletions.
There are no files selected for viewing
34 changes: 34 additions & 0 deletions
34
pay-api/migrations/versions/2024_09_18_67407611eec8_21539_shortname_refund_history.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
"""EFT Short name history short name refund. | ||
Revision ID: 67407611eec8 | ||
Revises: 423a9f909079 | ||
Create Date: 2024-09-18 10:20:15.689980 | ||
""" | ||
from alembic import op | ||
import sqlalchemy as sa | ||
|
||
|
||
# revision identifiers, used by Alembic. | ||
# Note you may see foreign keys with distribution_codes_history | ||
# For disbursement_distribution_code_id, service_fee_distribution_code_id | ||
# Please ignore those lines and don't include in migration. | ||
|
||
revision = '67407611eec8' | ||
down_revision = '423a9f909079' | ||
branch_labels = None | ||
depends_on = None | ||
|
||
|
||
def upgrade(): | ||
with op.batch_alter_table('eft_short_names_historical', schema=None) as batch_op: | ||
batch_op.add_column(sa.Column('eft_refund_id', sa.Integer(), nullable=True)) | ||
batch_op.create_index(batch_op.f('ix_eft_short_names_historical_eft_refund_id'), ['eft_refund_id'], unique=False) | ||
batch_op.create_foreign_key('eft_short_names_historical_eft_refund_id_fkey', 'eft_refunds', ['eft_refund_id'], ['id']) | ||
|
||
|
||
def downgrade(): | ||
with op.batch_alter_table('eft_short_names_historical', schema=None) as batch_op: | ||
batch_op.drop_constraint('eft_short_names_historical_eft_refund_id_fkey', type_='foreignkey') | ||
batch_op.drop_index(batch_op.f('ix_eft_short_names_historical_eft_refund_id')) | ||
batch_op.drop_column('eft_refund_id') |
30 changes: 30 additions & 0 deletions
30
pay-api/migrations/versions/2024_09_19_29f59e6f147b_EFT_Refunds.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
"""EFT Refunds additional columns | ||
Revision ID: 29f59e6f147b | ||
Revises: 67407611eec8 | ||
Create Date: 2024-09-19 16:09:53.120704 | ||
""" | ||
from alembic import op | ||
import sqlalchemy as sa | ||
|
||
|
||
# revision identifiers, used by Alembic. | ||
|
||
revision = '29f59e6f147b' | ||
down_revision = '67407611eec8' | ||
branch_labels = None | ||
depends_on = None | ||
|
||
|
||
def upgrade(): | ||
|
||
with op.batch_alter_table('eft_refunds', schema=None) as batch_op: | ||
batch_op.add_column(sa.Column('decline_reason', sa.String(), nullable=True)) | ||
batch_op.add_column(sa.Column('created_by', sa.String(length=100), nullable=True)) | ||
|
||
|
||
def downgrade(): | ||
with op.batch_alter_table('eft_refunds', schema=None) as batch_op: | ||
batch_op.drop_column('created_by') | ||
batch_op.drop_column('decline_reason') |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.