logic changes for zero deductible

This commit is contained in:
Katie Kroell 2024-10-30 09:47:35 -04:00
parent 4ad6b3e1b6
commit cb2d0f993c

View file

@ -464,18 +464,18 @@ export default {
return isRepair; return isRepair;
case 'deductibleOverZero': case 'deductibleOverZero':
return ( return (
this.isDeductibleVisible && this.deductibleValue !== 0 this.isDeductibleVisible && this.deductibleValue > 0
); // TODO what if deductible is negative? );
case 'isDeductibleZero': case 'isDeductibleZero':
return ( return (
this.isDeductibleVisible && this.deductibleValue === 0 this.isDeductibleVisible && this.deductibleValue <= 0
); );
case 'verifiedRepair': case 'verifiedRepair':
return isRepair && this.isDeductibleVisible; return isRepair && this.isDeductibleVisible;
case 'verifiedReplaceZeroDeductible': case 'verifiedReplaceZeroDeductible':
return !isRepair && this.isDeductibleVisible && this.deductibleValue === 0; return !isRepair && this.isDeductibleVisible && this.deductibleValue <= 0;
case 'verifiedReplaceDeductibleOverZero': case 'verifiedReplaceDeductibleOverZero':
return !isRepair && this.isDeductibleVisible && this.deductibleValue !== 0; return !isRepair && this.isDeductibleVisible && this.deductibleValue > 0;
default: default:
return null; return null;
} }