Skip to content

Commit

Permalink
Merge pull request #401 from bcgov/ofm-hotfix-supp-end-date-change
Browse files Browse the repository at this point in the history
fixed dates for timezone
  • Loading branch information
jenbeckett authored Oct 30, 2024
2 parents 8376fb9 + ff86393 commit 19b7127
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions frontend/src/views/supp-allowances/SupplementaryFormView.vue
Original file line number Diff line number Diff line change
Expand Up @@ -549,9 +549,9 @@ export default {
},
setSuppTermDates() {
const today = new Date()
const formattedEndDate = new Date(this.fundingAgreement.endDate)
const termTwoEndDate = moment(formattedEndDate).subtract(1, 'years').toDate()
const termOneEndDate = moment(formattedEndDate).subtract(2, 'years').toDate()
const formattedEndDate = moment(this.fundingAgreement?.endDate).endOf('day').toDate()
const termTwoEndDate = moment(formattedEndDate).subtract(1, 'years').endOf('day').toDate()
const termOneEndDate = moment(formattedEndDate).subtract(2, 'years').endOf('day').toDate()
switch (true) {
//not having a funding agreement or FA end date will only happen if a user navigates to SuppApp right after
Expand Down

0 comments on commit 19b7127

Please sign in to comment.