Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix bump supp. end year if no annual bill run
https://eaflood.atlassian.net/browse/WATER-4403 In [Bump supplementary end year if no annual bill run](#875) we added logic that would mean when creating a new supplementary bill run the engine could tell if an annual bill run existed for the same year and region. If one doesn't it will make a mess of the billing for customers if the supplementary happened before the annual. But we don't want to block users from working. So, instead we bump the financial end year to use back to the same as the last 'sent' annual bill run for that region. We even [Refactor DetermineBillingPeriods to use type](#864) so it would know to use the calculated year when determining the billing periods for the supplementary bill run. What we forgot to do was remove a [temporary fix](#859) we'd added until this work can be completed. This means the year we've calculated is being dropped and not passed to `DetermineBillingPeriods`. This change fixes that!
- Loading branch information