From b4977cd63c2fa799d4790e194f8a93b74bcdeea2 Mon Sep 17 00:00:00 2001 From: Alex Humphries Date: Wed, 18 Feb 2026 09:27:40 -0500 Subject: [PATCH] INSR-7759: More cart updates, preliminary SMS opt-in work --- src/constants/error-messages.js | 4 +- src/helpers/cart-helper.js | 18 ++- .../cart-dropdown/cart-dropdown.vue | 153 +++++------------- src/layouts/payment-method/payment-method.vue | 126 ++++++++++++--- 4 files changed, 160 insertions(+), 141 deletions(-) diff --git a/src/constants/error-messages.js b/src/constants/error-messages.js index 62e79340..66aa697a 100644 --- a/src/constants/error-messages.js +++ b/src/constants/error-messages.js @@ -70,7 +70,9 @@ const errorMessages = Object.freeze({ TPA_SEARCH_SHOP_FORMAT: 'Please enter a valid shop name.', TPA_SEARCH_REQUIRED: 'Please enter a shop name or ZIP code.', SERVICE_ADDRESS_REQUIRED: 'Service street address is required.', - SERVICE_CITY_REQUIRED: 'Service city is required.' + SERVICE_CITY_REQUIRED: 'Service city is required.', + + PAYMENT_METHOD_PAGE_OPTION_REQUIRED: 'Please select an Option', }); export default errorMessages; diff --git a/src/helpers/cart-helper.js b/src/helpers/cart-helper.js index c0864433..61ed75ad 100644 --- a/src/helpers/cart-helper.js +++ b/src/helpers/cart-helper.js @@ -19,11 +19,12 @@ export function getLineItems(order) { * @returns {[]} array of service line items */ export function getServiceLineItems(order) { - const { supportingItems, glassParts, otherParts } = getLineItems(order); + const { supportingItems, glassParts, otherParts, feeItems } = getLineItems(order); return [ ...(supportingItems ?? []), ...(glassParts ?? []), - ...(otherParts ?? []) + ...(otherParts ?? []), + ...(feeItems ?? []) ]; } @@ -33,10 +34,9 @@ export function getServiceLineItems(order) { * @returns {[]} array of non-service line items */ export function getNonServiceLineItems(order) { - const { vaps, feeItems } = getLineItems(order); + const { vaps } = getLineItems(order); return [ - ...(vaps ?? []), - ...(feeItems ?? []) + ...(vaps ?? []) ]; } @@ -157,3 +157,11 @@ export function getRecalibrationTotal(order) { return getPriceOfLineItems(recalibrationLineItems); } + +/** + * Returns whether the order only contains a deductible line item and no other line items + * @param {object} order order object + * @returns {boolean} whether the order is deductible only + */ +export function isDeductibleOnly(order) { +} \ No newline at end of file diff --git a/src/iss-components/cart-dropdown/cart-dropdown.vue b/src/iss-components/cart-dropdown/cart-dropdown.vue index 371415aa..77f41771 100644 --- a/src/iss-components/cart-dropdown/cart-dropdown.vue +++ b/src/iss-components/cart-dropdown/cart-dropdown.vue @@ -24,15 +24,14 @@ class="cart-item">
{{ recalibrationLabel }} - {{ getDisplayed(recalibrationPrice) }} + {{ formatAmountInDollars(recalibrationPrice) }}
-
+ class="cart-item packaged">
{{ item?.name ?? '' }} {{ formatAmountInDollars(item?.subTotal ?? 0) }} @@ -49,32 +48,12 @@
- - -
-
- {{ item?.name ?? '' }} - {{ formatAmountInDollars(item?.subTotal ?? 0) }} -
- - - -