Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

LCFS-1553: BUG - Other diesel #1604

Merged
merged 3 commits into from
Jan 6, 2025
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
"""Update fuel type name

Revision ID: bfa7bbb1eea3
Revises: 9329e38396e1
Create Date: 2025-01-03 13:24:19.525006

"""

import sqlalchemy as sa
from alembic import op

# revision identifiers, used by Alembic.
revision = "bfa7bbb1eea3"
down_revision = "9329e38396e1"
branch_labels = None
depends_on = None


def upgrade() -> None:
# Update fuel type name
op.execute("""
UPDATE fuel_type
SET fuel_type = 'Other diesel fuel',
provision_1_id = 3 -- Change from prescribed (1) to default (3)
WHERE fuel_type = 'Other diesel';
""")


def downgrade() -> None:
# Revert fuel type name update
op.execute("""
UPDATE fuel_type
SET fuel_type = 'Other diesel',
provision_1_id = 1 -- Change from default (3) to prescribed (1)
WHERE fuel_type = 'Other diesel fuel';
""")

2 changes: 1 addition & 1 deletion frontend/src/assets/locales/en/allocationAgreement.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"allocationAgreementSubtitle": "Enter allocation agreement details below",
"fuelCodeFieldRequiredError": "Error updating row: Fuel code field required",
"allocationAgreementColLabels": {
"transaction": "Responsibility",
"allocationTransactionType": "Responsibility",
"transactionPartner": "Legal name of transaction partner",
"postalAddress": "Address for service",
"transactionPartnerEmail": "Email",
Expand Down
2 changes: 1 addition & 1 deletion frontend/src/views/AllocationAgreements/_schema.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ export const allocationAgreementColDefs = (optionsData, errors, currentUser) =>
field: 'allocationTransactionType',
headerComponent: RequiredHeader,
headerName: i18n.t(
'allocationAgreement:allocationAgreementColLabels.transaction'
'allocationAgreement:allocationAgreementColLabels.allocationTransactionType'
),
cellEditor: AutocompleteCellEditor,
cellEditorParams: {
Expand Down
Loading