-
Notifications
You must be signed in to change notification settings - Fork 0
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
Remove two-part tariff supplementary billing flag from the Licences
view
#1242
Merged
Conversation
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
… view https://eaflood.atlassian.net/browse/WATER-4587 The PR #1236 has changed the way the SROC two-part tariff supplementary billing flag is set. Previously there was a boolean flag in the `licences` table/view to indicate if the licence should be included in the next TPT supplementary bill run. This is no longer sufficient for our needs as we are now required to record the specific year that the TPT supplementary bill run is for. So a new table `licence_supplementary_years` has been built that is now used to record if the licence should go into a supplementary bill run & for which year. As a result the original flag in the `licences` table is no longer required. In this PR the `include_in_sroc_tpt_billing` column is going to be removed from the view. The next PR will be in the `water-abstraction-service` to remove the actual column from the table.
It seemed to default to CRLF when `migrate:make` was run
Jozzey
requested review from
Cruikshanks,
robertparkinson,
sujithvg,
jonathangoulding,
Beckyrose200 and
rvsiyad
August 7, 2024 16:30
Cruikshanks
approved these changes
Aug 7, 2024
Jozzey
added a commit
that referenced
this pull request
Aug 8, 2024
Following on from this PR #1242 where the `include_in_sroc_tpt_billing` column was removed from the view. The intention was to then create migration scripts to remove the column from the table. However, we have realised that if we do this, given the way the migration scripts run. When all the migrations relating to the removal of this column are pushed up to our servers and they run together. An error will be generated as the migrations will try to remove the column from the table before it is removed from the view. We have therefore opted for what we do when removing legacy columns from our views. We just comment out the column in the view migration and leave the column in the table. This PR will update the migration that was created previously.
Jozzey
added a commit
that referenced
this pull request
Aug 8, 2024
Following on from this PR #1242 where the `include_in_sroc_tpt_billing` column was removed from the view. The intention was to then create migration scripts to remove the column from the table. However, we have realised that if we do this, given the way the migration scripts run. When all the migrations relating to the removal of this column are pushed up to our servers and they run together. An error will be generated as the migrations will try to remove the column from the table before it is removed from the view. We have therefore opted for what we do when removing legacy columns from our views. We just comment out the column in the view migration and leave the column in the table. This PR will update the migration that was created previously.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
https://eaflood.atlassian.net/browse/WATER-4587
The PR #1236 has changed how the SROC two-part tariff supplementary billing flag is set. Previously there was a boolean flag in the
licences
table/view to indicate if the licence should be included in the next TPT supplementary bill run. This is no longer sufficient for our needs as we are now required to record the specific year the TPT supplementary bill run is for.So a new table
licence_supplementary_years
has been built that is now used to record if the licence should go into a supplementary bill run & for which year. As a result, the original flag in thelicences
table is no longer required.In this PR the
include_in_sroc_tpt_billing
column will be removed from the view. The next PR will be in thewater-abstraction-service
to remove the actual column from the table.The migrations get upset if I try to remove the column from the legacy migrations at the same time as the view so I'll do another PR.