diff --git a/ppr-ui/src/components/mhrTransfers/ConfirmCompletion.vue b/ppr-ui/src/components/mhrTransfers/ConfirmCompletion.vue index 3dd302bcb..fd7cb1128 100644 --- a/ppr-ui/src/components/mhrTransfers/ConfirmCompletion.vue +++ b/ppr-ui/src/components/mhrTransfers/ConfirmCompletion.vue @@ -30,11 +30,11 @@
  1. -

    Bill of sale meets the following requirements:

    +

    Bill of sale, if applicable, meets the following requirements:

    • It has been signed by either a) the registered owner(s) (individually or by a duly authorized @@ -152,7 +152,7 @@

      Transfer or Change Ownership form has been received and retained.

    • @@ -202,7 +202,7 @@

      Original signed Affidavit of Executor form has been received and retained.

    • @@ -222,9 +222,10 @@ society or cooperative association.

      - Note: For current registered owners, the incorporated organization must have been - active (good legal standing) on the Corporate Register at the time the bill of sale was signed. - Future registered owners must be active (good legal standing) at the time of this registration. + Note: For current registered owners, the incorporated organization must have + been active (good legal standing) on the Corporate Register at the time the bill of sale was + signed. Future registered owners must be active (good legal standing) at the time of this + registration.

    • Consideration @@ -46,7 +46,7 @@ @@ -56,7 +56,8 @@ id="transfer-date" ref="transferDateRef" title="Date" - :errorMsg="showFormError && !transferDate ? 'Enter bill of sale date of execution' : ''" + :errorMsg="showFormError && + (!isTransferNonGiftBillOfSale && !transferDate) ? 'Enter bill of sale date of execution' : ''" :initialValue="transferDate" data-test-id="transfer-date" @emitDate="transferDate = $event" @@ -83,7 +84,7 @@ >

      Is the manufactured home located on land that the - {{ isTransferDueToSaleOrGift ? 'new' : '' }} homeowners own or on land that + {{ isNewHomeOwner ? 'new' : '' }} homeowners own or on land that they have a registered lease of 3 years or more?

      @@ -193,7 +194,8 @@ export default defineComponent({ } = storeToRefs(useStore()) const { isTransferDueToDeath, - isTransferDueToSaleOrGift, + isTransferBillOfSale, + isTransferNonGiftBillOfSale, isTransferWithoutBillOfSale } = useTransferOwners() @@ -214,13 +216,18 @@ export default defineComponent({ transferDate: getMhrTransferDate.value, isOwnLand: getMhrTransferOwnLand.value, enableWarningMsg: false, + isNewHomeOwner: computed(() => + isTransferBillOfSale.value || isTransferWithoutBillOfSale.value + ), isValidTransferDetails: computed((): boolean => - (isTransferDueToDeath.value || isTransferWithoutBillOfSale.value) + (isTransferDueToDeath.value || isTransferWithoutBillOfSale.value || isTransferNonGiftBillOfSale.value) ? localState.isValidForm // validate the form without transfer date : (localState.isValidForm && !!localState.transferDate)), showFormError: computed((): boolean => props.validate && !localState.isValidTransferDetails), considerationRules: computed((): Array<()=>string|boolean> => { - return customRules(required('Enter consideration'), maxLength(80)) + return isTransferNonGiftBillOfSale.value + ? customRules(maxLength(80)) + : customRules(required('Enter consideration'), maxLength(80)) }) }) @@ -259,7 +266,7 @@ export default defineComponent({ isNotNull, considerationRef, isTransferDueToDeath, - isTransferDueToSaleOrGift, + isTransferNonGiftBillOfSale, isTransferWithoutBillOfSale, transferDetailsForm, updateConsideration, diff --git a/ppr-ui/src/components/mhrTransfers/TransferDetailsReview.vue b/ppr-ui/src/components/mhrTransfers/TransferDetailsReview.vue index 52ac8415f..a7b8a846a 100644 --- a/ppr-ui/src/components/mhrTransfers/TransferDetailsReview.vue +++ b/ppr-ui/src/components/mhrTransfers/TransferDetailsReview.vue @@ -20,7 +20,7 @@ cols="9" class="gray7" > - {{ formatCurrency(getMhrTransferConsideration) }} + {{ getMhrTransferConsideration ? formatCurrency(getMhrTransferConsideration) : '(Not Entered)' }} @@ -31,7 +31,7 @@ cols="9" class="gray7" > - {{ convertDate(getMhrTransferDate, false, false) }} + {{ getMhrTransferDate ? convertDate(getMhrTransferDate, false, false) : '(Not Entered)' }} @@ -73,15 +73,18 @@ export default defineComponent({ const { isTransferDueToDeath, - isTransferDueToSaleOrGift, + isTransferBillOfSale, isTransferWithoutBillOfSale } = useTransferOwners() const localState = reactive({ + isNewHomeOwner: computed(() => + isTransferBillOfSale.value || isTransferWithoutBillOfSale.value + ), landOrLeaseLabel: computed(() => { return `The manufactured home is ${!getMhrTransferOwnLand.value ? 'not' : ''} located on land that the - ${(isTransferDueToSaleOrGift.value || isTransferWithoutBillOfSale.value) ? 'new' : ''} homeowners - own or on land that they have a registered lease of 3 years or more.` + ${ localState.isNewHomeOwner ? 'new' : ''} homeowners own or on land that they have a registered lease + of 3 years or more.` }) }) diff --git a/ppr-ui/src/composables/mhrInformation/useTransferOwners.ts b/ppr-ui/src/composables/mhrInformation/useTransferOwners.ts index ad1a6c383..f635395b1 100644 --- a/ppr-ui/src/composables/mhrInformation/useTransferOwners.ts +++ b/ppr-ui/src/composables/mhrInformation/useTransferOwners.ts @@ -100,6 +100,31 @@ export const useTransferOwners = (enableAllActions: boolean = false) => { ].includes(getMhrTransferType.value?.transferType) }) + /** Returns true when the selected transfer is Bill Of Sale type **/ + const isTransferBillOfSale = computed((): boolean => { + return [ + ApiTransferTypes.SALE_OR_GIFT, + ApiTransferTypes.TRANS_FAMILY_ACT, + ApiTransferTypes.TRANS_INFORMAL_SALE, + ApiTransferTypes.TRANS_QUIT_CLAIM, + ApiTransferTypes.TRANS_RECEIVERSHIP, + ApiTransferTypes.TRANS_SEVER_GRANT, + ApiTransferTypes.TRANS_WRIT_POSSESSION + ].includes(getMhrTransferType.value?.transferType) + }) + + /** Returns true when the selected transfer is subset of Bill Of Sale (minus Gift/Sale transfer) **/ + const isTransferNonGiftBillOfSale = computed((): boolean => { + return [ + ApiTransferTypes.TRANS_FAMILY_ACT, + ApiTransferTypes.TRANS_INFORMAL_SALE, + ApiTransferTypes.TRANS_QUIT_CLAIM, + ApiTransferTypes.TRANS_RECEIVERSHIP, + ApiTransferTypes.TRANS_SEVER_GRANT, + ApiTransferTypes.TRANS_WRIT_POSSESSION + ].includes(getMhrTransferType.value?.transferType) + }) + /** Returns true when the selected transfer is not a type of Bill of Sale **/ const isTransferWithoutBillOfSale = computed((): boolean => { return [ @@ -191,6 +216,12 @@ export const useTransferOwners = (enableAllActions: boolean = false) => { switch (getMhrTransferType.value?.transferType) { case ApiTransferTypes.SALE_OR_GIFT: + case ApiTransferTypes.TRANS_FAMILY_ACT: + case ApiTransferTypes.TRANS_INFORMAL_SALE: + case ApiTransferTypes.TRANS_QUIT_CLAIM: + case ApiTransferTypes.TRANS_RECEIVERSHIP: + case ApiTransferTypes.TRANS_SEVER_GRANT: + case ApiTransferTypes.TRANS_WRIT_POSSESSION: case ApiTransferTypes.TO_EXECUTOR_PROBATE_WILL: case ApiTransferTypes.TO_EXECUTOR_UNDER_25K_WILL: case ApiTransferTypes.TO_ADMIN_NO_WILL: @@ -209,10 +240,20 @@ export const useTransferOwners = (enableAllActions: boolean = false) => { if (enableAllActions) return true switch (getMhrTransferType.value?.transferType) { + // Bill Of Sale Transfers case ApiTransferTypes.SALE_OR_GIFT: + case ApiTransferTypes.TRANS_FAMILY_ACT: + case ApiTransferTypes.TRANS_INFORMAL_SALE: + case ApiTransferTypes.TRANS_QUIT_CLAIM: + case ApiTransferTypes.TRANS_RECEIVERSHIP: + case ApiTransferTypes.TRANS_SEVER_GRANT: + case ApiTransferTypes.TRANS_WRIT_POSSESSION: + + // Transfers Due to Death case ApiTransferTypes.TO_EXECUTOR_PROBATE_WILL: case ApiTransferTypes.TO_EXECUTOR_UNDER_25K_WILL: case ApiTransferTypes.TO_ADMIN_NO_WILL: + case ApiTransferTypes.ABAN: case ApiTransferTypes.BANK: case ApiTransferTypes.COU: @@ -239,6 +280,12 @@ export const useTransferOwners = (enableAllActions: boolean = false) => { switch (getMhrTransferType.value?.transferType) { case ApiTransferTypes.SALE_OR_GIFT: + case ApiTransferTypes.TRANS_FAMILY_ACT: + case ApiTransferTypes.TRANS_INFORMAL_SALE: + case ApiTransferTypes.TRANS_QUIT_CLAIM: + case ApiTransferTypes.TRANS_RECEIVERSHIP: + case ApiTransferTypes.TRANS_SEVER_GRANT: + case ApiTransferTypes.TRANS_WRIT_POSSESSION: return getMhrInformation.value.statusType !== MhApiStatusTypes.FROZEN // Enable for all but FROZEN status case ApiTransferTypes.TO_EXECUTOR_PROBATE_WILL: case ApiTransferTypes.TO_EXECUTOR_UNDER_25K_WILL: @@ -260,6 +307,12 @@ export const useTransferOwners = (enableAllActions: boolean = false) => { case ApiTransferTypes.TO_ADMIN_NO_WILL: return !groupHasAllBusinesses(getCurrentGroupById(owner.groupId)) case ApiTransferTypes.SALE_OR_GIFT: + case ApiTransferTypes.TRANS_FAMILY_ACT: + case ApiTransferTypes.TRANS_INFORMAL_SALE: + case ApiTransferTypes.TRANS_QUIT_CLAIM: + case ApiTransferTypes.TRANS_RECEIVERSHIP: + case ApiTransferTypes.TRANS_SEVER_GRANT: + case ApiTransferTypes.TRANS_WRIT_POSSESSION: case ApiTransferTypes.ABAN: case ApiTransferTypes.BANK: case ApiTransferTypes.COU: @@ -292,6 +345,12 @@ export const useTransferOwners = (enableAllActions: boolean = false) => { switch (getMhrTransferType.value?.transferType) { case ApiTransferTypes.SALE_OR_GIFT: + case ApiTransferTypes.TRANS_FAMILY_ACT: + case ApiTransferTypes.TRANS_INFORMAL_SALE: + case ApiTransferTypes.TRANS_QUIT_CLAIM: + case ApiTransferTypes.TRANS_RECEIVERSHIP: + case ApiTransferTypes.TRANS_SEVER_GRANT: + case ApiTransferTypes.TRANS_WRIT_POSSESSION: return false // Disable for Sale or Gift case ApiTransferTypes.TO_EXECUTOR_PROBATE_WILL: case ApiTransferTypes.TO_EXECUTOR_UNDER_25K_WILL: @@ -315,6 +374,12 @@ export const useTransferOwners = (enableAllActions: boolean = false) => { case ApiTransferTypes.TO_ADMIN_NO_WILL: return false // Disable for above transfer types case ApiTransferTypes.SALE_OR_GIFT: + case ApiTransferTypes.TRANS_FAMILY_ACT: + case ApiTransferTypes.TRANS_INFORMAL_SALE: + case ApiTransferTypes.TRANS_QUIT_CLAIM: + case ApiTransferTypes.TRANS_RECEIVERSHIP: + case ApiTransferTypes.TRANS_SEVER_GRANT: + case ApiTransferTypes.TRANS_WRIT_POSSESSION: return getMhrInformation.value.statusType !== MhApiStatusTypes.FROZEN default: return true @@ -846,6 +911,8 @@ export const useTransferOwners = (enableAllActions: boolean = false) => { getMhrTransferType, isTransferDueToDeath, isTransferToExecOrAdmin, + isTransferBillOfSale, + isTransferNonGiftBillOfSale, isTransferWithoutBillOfSale, isTransferDueToSaleOrGift, isTransferToSurvivingJointTenant,