CSR-2237 when coverage is verified, only show deductible for amount due in the cart
This commit is contained in:
CarlNation 2024-09-27 15:11:20 -04:00
parent 3477b05816
commit 62d550750f
2 changed files with 5 additions and 5 deletions

View file

@ -173,7 +173,7 @@ export default {
!order.policy.isNoComp &&
!order.policy.isItac
) {
amountDue += order.policy.currentDeductible;
amountDue = order.policy.currentDeductible;
}
return ((amountDue * 100) / 100).toFixed(2);

View file

@ -175,7 +175,7 @@ describe("baseMixin.js", () => {
promos: [],
};
const payment = { insuranceCoverage: { isVerified: true } };
const payment = { insuranceCoverage: { isVerified: false } };
const policy = { isNoComp: false, isItac: false, currentDeductible: 250 };
store.getters = {
@ -190,7 +190,7 @@ describe("baseMixin.js", () => {
var amtDue = mixIn.methods.getAmountDue(lineItems);
expect(amtDue).toEqual("303.00");
expect(amtDue).toEqual("53.00");
});
test("getAmountDue should function with a submitted order", () => {
@ -223,7 +223,7 @@ describe("baseMixin.js", () => {
promos: [],
};
const payment = { insuranceCoverage: { isVerified: true } };
const payment = { insuranceCoverage: { isVerified: false } };
const policy = { isNoComp: false, isItac: false, currentDeductible: 250 };
mixIn.methods.hasSubmittedOrder = jest.fn().mockReturnValue(true);
@ -240,7 +240,7 @@ describe("baseMixin.js", () => {
var amtDue = mixIn.methods.getAmountDue(lineItems);
expect(amtDue).toEqual("303.00");
expect(amtDue).toEqual("53.00");
});
test("getAmountDue for cash should sum lineitems", () => {