CSR-794 Fix variable name

This commit is contained in:
Katie 2022-08-18 15:33:54 -04:00
parent 097d56cb12
commit 46c4b355f7

View file

@ -1,7 +1,7 @@
<template>
<div class="windshield-options">
<windshieldDamageTypeQuestion cmsWidgetName="WindshieldDamageTypeQuestion"
:isAvailable=isWindshieldDamageLocation
:isAvailable="isWindshieldDamageLocation"
:suppressError="hasRepairReplaceConflict || showNoReplacementAvailableError"
groupName="WindshieldDamageTypeQuestion"
v-model="selectedWindshieldDamageTypeValue"
@ -13,7 +13,7 @@
cmsWidgetName="NoReplacementAvailableError"
alertClass="alert-danger"
:isDismissible="false"
/>
/>
<windshieldChipCountQuestion cmsWidgetName="WindshieldChipCountQuestion"
:isAvailable="isRepairOptionSelected && !hasRepairReplaceConflict"
groupName="WindshieldChipCountQuestion"
@ -137,20 +137,17 @@ export default ({
}
},
isWindshieldDamageLocation() {
return this.selectedDamageLocations.some(selectedDamages =>
{
return Boolean(selectedDamages.toUpperCase() === "WINDSHIELD");
});
return this.selectedDamageLocations.some(selectedDamageLocation => selectedDamageLocation === damageLocationsSelected.WINDSHIELD);
},
isRepairOptionSelected(){
if (!this.selectedWindshieldDamageTypeValues) return false;
if (!this.selectedWindshieldDamageTypeValue) return false;
return this.selectedWindshieldDamageTypeValues.some(val => val === damageLocationsSelected.REPAIR) && this.isWindshieldDamageLocation;
return this.selectedWindshieldDamageTypeValue === damageLocationsSelected.REPAIR && this.isWindshieldDamageLocation;
},
isReplaceOptionSelected(){
if (!this.selectedWindshieldDamageTypeValues) return false;
if (!this.selectedWindshieldDamageTypeValue) return false;
return this.selectedWindshieldDamageTypeValues.some(val => val === damageLocationsSelected.REPLACE) && this.isWindshieldDamageLocation;
return this.selectedWindshieldDamageTypeValue === damageLocationsSelected.REPLACE && this.isWindshieldDamageLocation;
},
isWindshieldReplaceAvailable() {
return !(Array.isArray(this.windshieldAvailableReplacementOptions) && this.windshieldAvailableReplacementOptions.length < 1);