-
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
Fix dates in view licence set up tab #1175
Merged
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
https://eaflood.atlassian.net/browse/WATER-4556 > Part of the work to replace the legacy view licence page In testing of the new view licence page, specifically the licence set up tab it was spotted that when a charge version has a status of `REVIEW` that the date the record was created rather than the start date is displayed in the charge information table. This is because the record is not a charge version; it is a workflow record which when approved will become a charge version record. The current presenter logic is not distinguishing between the different types of workflow record hence the wrong date being displayed. But hold on. A quick review of the legacy version of the tab shows that when a workflow record does not have a status of `REVIEW` we don't show any dates at all! Then we spotted that there is inconsistency about whether we use a dash in the end date column. The charge information table does, but the return requirements and agreements tables don't. So, this change is a general fix up of dates in the tab. - for workflow records in `REVIEW` show the start date from the stored charge version details - for all tables, where end date is not set display a `-` - do not display any dates for workflow records that have a status other than `REVIEW`
We do a little housekeeping to bring the presenter's tests a little closer to our conventions and deal with some linting issues. We also make the starting data more realistic by aligning the dates and not populating te end dates. Beyond that we change the assertions in the tests to match how we expect the data to be displayed in the page.
Cruikshanks
force-pushed
the
fix-start-date-in-charge-versions-view
branch
from
July 9, 2024 12:21
fd6f388
to
9eb615a
Compare
Cruikshanks
requested review from
robertparkinson,
Jozzey,
jonathangoulding,
Beckyrose200 and
rvsiyad
July 9, 2024 12:52
Jozzey
approved these changes
Jul 9, 2024
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Cruikshanks
added a commit
that referenced
this pull request
Jul 9, 2024
https://eaflood.atlassian.net/browse/WATER-4556 In testing of the new view licence page, specifically the licence set up tab, it was spotted that when a charge version has a status of `REVIEW` that the date the record was created rather than the start date is displayed in the charge information table. We fixed that in [Fix dates in view licence set up tab](#1175). But hot on its heels someone has pointed out the same applies for a workflow record with a status of `changes_requested`. So, this change fixes it so we display the charge version start date for a workflow record with a status of `changes_requested` in the charge information table of the Licence setup tab in our new view licence page.
Cruikshanks
added a commit
that referenced
this pull request
Jul 9, 2024
https://eaflood.atlassian.net/browse/WATER-4556 In testing of the new view licence page, specifically the licence set up tab, it was spotted that when a charge version has a status of `REVIEW` that the date the record was created rather than the start date is displayed in the charge information table. We fixed that in [Fix dates in view licence set up tab](#1175). But hot on its heels, someone has pointed out that the same applies for a workflow record with a status of `changes_requested`. So, this change fixes it, so we display the charge version start date for a workflow record with a status of `changes_requested` in the charge information table of the Licence setup tab in our new view licence page. --- Because this meant looking at another workflow status, we needed to check that everything was linked up for `changes_requested`. This led us to take another look at how the status for each record type in the tab was being determined. We decided to split the types to give us more flexibility and use the same convention we've used in other tags, i.e. pass the record status through and let the macro handle the display. So, a change to our tag macros was also made in this change.
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-4556
In testing of the new view licence page, specifically the licence set up tab, it was spotted that when a charge version has a status of
REVIEW
that the date the record was created rather than the start date is displayed in the charge information table.This is because the record is not a charge version; it is a workflow record, which, when approved, will become a charge version record. The current presenter logic is not distinguishing between the different types of workflow records, hence the wrong date being displayed.
But hold on. A quick review of the legacy version of the tab shows that when a workflow record does not have a status of
REVIEW
we don't show any dates at all!Then we spotted that there is inconsistency about whether we use a dash in the end date column. The charge information table does, but the return requirements and agreements tables don't.
So, this change is a general fix-up of dates in the tab.
REVIEW
show the start date from the stored charge version details-
REVIEW