diff --git a/.github/workflows/dev-release.yaml b/.github/workflows/dev-release.yaml index deb5dd57f..2f8581401 100644 --- a/.github/workflows/dev-release.yaml +++ b/.github/workflows/dev-release.yaml @@ -1,11 +1,11 @@ ## For each release, the value of name, branches, RELEASE_NAME and PR_NUMBER need to be adjusted accordingly ## For each release, update lib/config.js: version and releaseBranch -name: TFRS Dev release-2.11.0 +name: TFRS Dev release-2.12.0 on: push: - branches: [ release-2.11.0 ] + branches: [ release-2.12.0 ] paths: - frontend/** - backend/** @@ -15,8 +15,8 @@ on: env: ## The pull request number of the Tracking pull request to merge the release branch to main ## Also remember to update the version in .pipeline/lib/config.js - PR_NUMBER: 2634 - RELEASE_NAME: release-2.11.0 + PR_NUMBER: 2701 + RELEASE_NAME: release-2.12.0 concurrency: group: ${{ github.workflow }}-${{ github.ref }} diff --git a/.github/workflows/tfrs-release.yaml b/.github/workflows/tfrs-release.yaml index 432203eb8..d5d910994 100644 --- a/.github/workflows/tfrs-release.yaml +++ b/.github/workflows/tfrs-release.yaml @@ -1,7 +1,7 @@ ## For each release, the value of name, branches, RELEASE_NAME and PR_NUMBER need to be adjusted accordingly ## For each release, update lib/config.js: version and releaseBranch -name: TFRS release-2.11.0 +name: TFRS release-2.12.0 on: workflow_dispatch: @@ -10,8 +10,8 @@ on: env: ## The pull request number of the Tracking pull request to merge the release branch to main ## Also remember to update the version in .pipeline/lib/config.js - PR_NUMBER: 2634 - RELEASE_NAME: release-2.11.0 + PR_NUMBER: 2701 + RELEASE_NAME: release-2.12.0 concurrency: group: ${{ github.workflow }}-${{ github.ref }} diff --git a/.pipeline/lib/config.js b/.pipeline/lib/config.js index 31977f9b3..21c4b42aa 100644 --- a/.pipeline/lib/config.js +++ b/.pipeline/lib/config.js @@ -1,7 +1,7 @@ 'use strict'; const options= require('@bcgov/pipeline-cli').Util.parseArguments() const changeId = options.pr //aka pull-request -const version = '2.11.0' +const version = '2.12.0' const name = 'tfrs' const ocpName = 'apps.silver.devops' @@ -13,7 +13,7 @@ options.git.repository='tfrs' const phases = { build: { namespace:'0ab226-tools' , name: `${name}`, phase: 'build' , changeId:changeId, suffix: `-build-${changeId}` , instance: `${name}-build-${changeId}` , version:`${version}-${changeId}`, tag:`build-${version}-${changeId}`, - releaseBranch: 'release-2.11.0' + releaseBranch: 'release-2.12.0' }, dev: {namespace:'0ab226-dev' , name: `${name}`, phase: 'dev' , changeId:changeId, suffix: `-dev` , instance: `${name}-dev` , version:`${version}`, tag:`dev-${version}`, dbServiceName: 'tfrs-spilo', diff --git a/backend/Dockerfile-django b/backend/Dockerfile-django index c81a89ba5..c63ab6c94 100644 --- a/backend/Dockerfile-django +++ b/backend/Dockerfile-django @@ -1,8 +1,12 @@ -FROM --platform=linux/amd64 python:3.7-stretch +FROM --platform=linux/amd64 python:3.7-buster ENV PYTHONUNBUFFERED 1 + RUN mkdir /app WORKDIR /app + RUN apt-get update RUN apt-get install -y git supervisor + +# Add necessary files and clone repositories ADD https://github.com/vishnubob/wait-for-it/compare/master...HEAD /dev/null -RUN git clone https://github.com/vishnubob/wait-for-it.git /wfi +RUN git clone https://github.com/vishnubob/wait-for-it.git /wfi \ No newline at end of file diff --git a/backend/api/serializers/CreditTrade.py b/backend/api/serializers/CreditTrade.py index 3df686a55..79a8bb581 100644 --- a/backend/api/serializers/CreditTrade.py +++ b/backend/api/serializers/CreditTrade.py @@ -281,6 +281,11 @@ class Meta: "the transaction." } }, + 'date_of_written_agreement': { + 'error_messages': { + 'invalid': "Please enter a valid date in the Agreement Date field: YYYY-MM-DD." + } + }, 'trade_effective_date': { 'required': False } diff --git a/backend/api/services/SpreadSheetBuilder.py b/backend/api/services/SpreadSheetBuilder.py index c0a74c349..885771b2f 100644 --- a/backend/api/services/SpreadSheetBuilder.py +++ b/backend/api/services/SpreadSheetBuilder.py @@ -178,8 +178,8 @@ def add_credit_transfers(self, credit_trades, user): worksheet.col(4).width = 7500 worksheet.col(5).width = 4500 worksheet.col(6).width = 4500 - worksheet.col(8).width = 3500 - worksheet.col(9).width = 10000 + worksheet.col(9).width = 3500 + worksheet.col(10).width = 10000 def add_fuel_suppliers(self, fuel_suppliers): """ diff --git a/backend/requirements.txt b/backend/requirements.txt index 1a85683b7..2f0abd81a 100644 --- a/backend/requirements.txt +++ b/backend/requirements.txt @@ -10,7 +10,7 @@ coreapi==2.3.3 coreschema==0.0.4 coverage==6.5.0 cryptography==39.0.1 -Django==3.2.20 +Django==3.2.23 django-celery-beat==1.4.0 django-cors-headers==3.10.1 django-debug-toolbar==3.2.4 @@ -47,7 +47,7 @@ sqlparse==0.4.4 typing_extensions==4.4.0 tzdata==2022.6 uritemplate==4.1.1 -urllib3==1.26.12 +urllib3==1.26.18 vine==1.3.0 whitenoise==5.3.0 xlwt==1.3.0 diff --git a/frontend/package.json b/frontend/package.json index 6f7650f4f..025d172f0 100644 --- a/frontend/package.json +++ b/frontend/package.json @@ -1,6 +1,6 @@ { "name": "tfrs", - "version": "2.11.0", + "version": "2.12.0", "dependencies": { "@babel/eslint-parser": "^7.19.1", "@babel/plugin-proposal-object-rest-spread": "^7.20.7", diff --git a/frontend/src/compliance_reporting/components/ComplianceReportingPage.js b/frontend/src/compliance_reporting/components/ComplianceReportingPage.js index 7c0891c1c..4a3e34b2e 100644 --- a/frontend/src/compliance_reporting/components/ComplianceReportingPage.js +++ b/frontend/src/compliance_reporting/components/ComplianceReportingPage.js @@ -220,9 +220,10 @@ const ComplianceReportingPage = (props) => { Toggle Dropdown @@ -334,6 +335,7 @@ const ComplianceReportingPage = (props) => { { Array.from({ length: new Date().getFullYear() - 2017 }, (_, index) => { const year = new Date().getFullYear() - index + 1 + if (year >= 2023) return null return (