From bde1a081133ee131d013e2e2b8c3e02ba06fe548 Mon Sep 17 00:00:00 2001 From: CameronEYDS <53542131+cameron-eyds@users.noreply.github.com> Date: Tue, 10 Sep 2024 09:57:26 -0700 Subject: [PATCH] QS Transfer Date Limitations (#2020) * QS Transfer Date Restrictions * lint fixes --- ppr-ui/package-lock.json | 4 ++-- ppr-ui/package.json | 2 +- ppr-ui/src/components/mhrTransfers/TransferDetails.vue | 7 ++++++- ppr-ui/src/components/search/SearchBarList.vue | 2 +- ppr-ui/src/components/tables/SearchHistory.vue | 2 +- 5 files changed, 11 insertions(+), 6 deletions(-) diff --git a/ppr-ui/package-lock.json b/ppr-ui/package-lock.json index 61b968d72..a8a6756e6 100644 --- a/ppr-ui/package-lock.json +++ b/ppr-ui/package-lock.json @@ -1,12 +1,12 @@ { "name": "ppr-ui", - "version": "3.2.53", + "version": "3.2.54", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "ppr-ui", - "version": "3.2.53", + "version": "3.2.54", "dependencies": { "@bcrs-shared-components/input-field-date-picker": "^1.0.0", "@lemoncode/fonk": "^1.5.1", diff --git a/ppr-ui/package.json b/ppr-ui/package.json index c13d4988b..6a095ac90 100644 --- a/ppr-ui/package.json +++ b/ppr-ui/package.json @@ -1,6 +1,6 @@ { "name": "ppr-ui", - "version": "3.2.53", + "version": "3.2.54", "private": true, "appName": "Assets UI", "sbcName": "SBC Common Components", diff --git a/ppr-ui/src/components/mhrTransfers/TransferDetails.vue b/ppr-ui/src/components/mhrTransfers/TransferDetails.vue index 0654b0e19..a807c4d86 100644 --- a/ppr-ui/src/components/mhrTransfers/TransferDetails.vue +++ b/ppr-ui/src/components/mhrTransfers/TransferDetails.vue @@ -59,6 +59,7 @@ :errorMsg="showFormError && (!isTransferNonGiftBillOfSale && !transferDate) ? 'Enter bill of sale date of execution' : ''" :initialValue="transferDate" + :maxDate="isRoleQualifiedSupplier ? localTodayDate(new Date(), true) : null" data-test-id="transfer-date" @emitDate="transferDate = $event" @emitCancel="transferDate = null" @@ -160,6 +161,7 @@ import { useInputRules, useTransferOwners } from '@/composables' import { InputFieldDatePicker } from '@/components/common' import { FormIF } from '@/interfaces' import { storeToRefs } from 'pinia' +import { localTodayDate } from '@/utils' export default defineComponent({ name: 'TransferDetails', @@ -189,7 +191,8 @@ export default defineComponent({ getMhrTransferDeclaredValue, getMhrTransferConsideration, getMhrTransferDate, - getMhrTransferOwnLand + getMhrTransferOwnLand, + isRoleQualifiedSupplier } = storeToRefs(useStore()) const { isTransferDueToDeath, @@ -262,6 +265,8 @@ export default defineComponent({ }) return { + localTodayDate, + isRoleQualifiedSupplier, isNotNull, considerationRef, isTransferDueToDeath, diff --git a/ppr-ui/src/components/search/SearchBarList.vue b/ppr-ui/src/components/search/SearchBarList.vue index 92dfe1477..c7ac4a6b9 100644 --- a/ppr-ui/src/components/search/SearchBarList.vue +++ b/ppr-ui/src/components/search/SearchBarList.vue @@ -22,9 +22,9 @@