mirror of
https://github.com/GSA/notifications-api.git
synced 2026-02-03 01:41:05 -05:00
Update the valid_from date for the rate that is intended to start at the begining of the financial year.
It was the start of the financial year in BST, needed to convert it to UTC. Small change to the logic to find the rates.
This commit is contained in:
24
migrations/versions/0080_fix_rate_start_date.py
Normal file
24
migrations/versions/0080_fix_rate_start_date.py
Normal file
@@ -0,0 +1,24 @@
|
||||
"""empty message
|
||||
|
||||
Revision ID: 0080_fix_rate_start_date
|
||||
Revises: 0079_update_rates
|
||||
Create Date: 2017-05-03 16:50:11.334116
|
||||
|
||||
"""
|
||||
|
||||
# revision identifiers, used by Alembic.
|
||||
revision = '0080_fix_rate_start_date'
|
||||
down_revision = '0079_update_rates'
|
||||
|
||||
from alembic import op
|
||||
import sqlalchemy as sa
|
||||
|
||||
|
||||
def upgrade():
|
||||
op.get_bind()
|
||||
op.execute("UPDATE RATES SET valid_from = '2017-03-31 23:00:00' WHERE valid_from = '2017-04-01 00:00:00'")
|
||||
|
||||
|
||||
def downgrade():
|
||||
op.get_bind()
|
||||
op.execute("UPDATE RATES SET valid_from = '2017-03-31 23:00:00' WHERE valid_from = '2017-04-01 00:00:00'")
|
||||
Reference in New Issue
Block a user