From 8d704fdc97b00b81adf4c7264725fc6e0dfaee67 Mon Sep 17 00:00:00 2001 From: CarlNation Date: Sat, 10 Jan 2026 15:25:14 -0500 Subject: [PATCH 1/4] CASH-1952 CASH-1952 endpoint for tax changed to POST from GET --- src/constants/endpoints.js | 2 +- src/store/index.js | 45 ++++++++++++++------------------------ 2 files changed, 18 insertions(+), 29 deletions(-) diff --git a/src/constants/endpoints.js b/src/constants/endpoints.js index 055b56b4..c7dbc97f 100644 --- a/src/constants/endpoints.js +++ b/src/constants/endpoints.js @@ -139,7 +139,7 @@ const endpoints = Object.freeze({ }, TaxOrderItems: { url: `${PRICE_BASE_URL}/taxed-order-items`, - method: 'GET' + method: 'POST' }, LogExperimentExposureIfAssigned: { url: `${EXPERIMENTS_BASE_URL}/log-exposure`, diff --git a/src/store/index.js b/src/store/index.js index e3555edb..53ec7479 100644 --- a/src/store/index.js +++ b/src/store/index.js @@ -2365,38 +2365,27 @@ export const useMainStore = defineStore({ const serviceLocationCity = serviceLocation.city; const serviceLocationState = serviceLocation.state; const serviceLocationZipCode = serviceLocation.zipCode; - - const lineItemsQueryString = getTaxLineItemQueryString(pricedLineItems, 'lineItems'); - - let queryString = ''; - if (appointmentType === AppointmentTypeStrings.MOBILE - || appointmentType === AppointmentTypeStrings.MOBILE_NOT_ITAC_AND_NOT_NOCOMP) { - queryString = - `ParentAccountNumber=${this.order.parentAccountNumber}` - + `&BillToAccountNumber=${this.billToAccountNumber}` - + `&ProviderNumber=${this.providerNumber}` - + `&AppointmentType=${appointmentType}` - + `&ServiceLocation.City=${serviceLocationCity}` - + `&ServiceLocation.State=${serviceLocationState}` - + `&ServiceLocation.ZipCode=${serviceLocationZipCode}` - + `${lineItemsQueryString}`; - } else { - queryString = - `ParentAccountNumber=${this.order.parentAccountNumber}` - + `&BillToAccountNumber=${this.billToAccountNumber}` - + `&ProviderNumber=${this.providerNumber}` - + `&AppointmentType=${appointmentType}` - + `${lineItemsQueryString}`; - } - const lineItemServerData = this.order.lineItems.serverData; - if (lineItemServerData) { - queryString += `&ServerData=${encodeURIComponent(lineItemServerData)}`; - } + const isMobileApt = appointmentType === AppointmentTypeStrings.MOBILE + || appointmentType === AppointmentTypeStrings.MOBILE_NOT_ITAC_AND_NOT_NOCOMP; + const retPricedLineItems = await globalMethods.callHttpClient({ method: endpoints.TaxOrderItems.method, - endpoint: `${endpoints.TaxOrderItems.url}?${queryString}` + endpoint: endpoints.TaxOrderItems.url, + payload: { + parentAccountNumber: this.order.parentAccountNumber, + billToAccountNumber: this.billToAccountNumber, + providerNumber: this.providerNumber, + appointmentType: appointmentType, + pricedLineItems: pricedLineItems, + serviceLocation: { + city: isMobileApt ? serviceLocationCity : null, + state: isMobileApt ? serviceLocationState : null, + zipCode: isMobileApt ? serviceLocationZipCode : null, + }, + serverData: lineItemServerData ? encodeURIComponent(lineItemServerData) : "", + }, }).then((response) => { this.order.lineItems.serverData = response.data.serverData; return addTaxesToPricedLineItems(pricedLineItems, response.data.taxedLineItems); From 8e61e33f73bdab194b57793e360d042174a021aa Mon Sep 17 00:00:00 2001 From: CarlNation Date: Sat, 10 Jan 2026 15:35:28 -0500 Subject: [PATCH 2/4] CASH-1952 CASH-1952 no need to encode data on post with axios. flatten line items --- src/store/index.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/store/index.js b/src/store/index.js index 53ec7479..9b983519 100644 --- a/src/store/index.js +++ b/src/store/index.js @@ -2378,13 +2378,13 @@ export const useMainStore = defineStore({ billToAccountNumber: this.billToAccountNumber, providerNumber: this.providerNumber, appointmentType: appointmentType, - pricedLineItems: pricedLineItems, + pricedLineItems: getLineItemsFlattened(pricedLineItems), serviceLocation: { city: isMobileApt ? serviceLocationCity : null, state: isMobileApt ? serviceLocationState : null, zipCode: isMobileApt ? serviceLocationZipCode : null, }, - serverData: lineItemServerData ? encodeURIComponent(lineItemServerData) : "", + serverData: lineItemServerData ? lineItemServerData : "", }, }).then((response) => { this.order.lineItems.serverData = response.data.serverData; From c35f21452e65f79a8b4d044889c065cf58fda880 Mon Sep 17 00:00:00 2001 From: CarlNation Date: Sat, 10 Jan 2026 15:53:29 -0500 Subject: [PATCH 3/4] CASH-1952 CASH-1952 use PascalCase instead of camel --- src/store/index.js | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/src/store/index.js b/src/store/index.js index 9b983519..3407cecf 100644 --- a/src/store/index.js +++ b/src/store/index.js @@ -2374,17 +2374,17 @@ export const useMainStore = defineStore({ method: endpoints.TaxOrderItems.method, endpoint: endpoints.TaxOrderItems.url, payload: { - parentAccountNumber: this.order.parentAccountNumber, - billToAccountNumber: this.billToAccountNumber, - providerNumber: this.providerNumber, - appointmentType: appointmentType, - pricedLineItems: getLineItemsFlattened(pricedLineItems), - serviceLocation: { + ParentAccountNumber: this.order.parentAccountNumber, + BillToAccountNumber: this.billToAccountNumber, + ProviderNumber: this.providerNumber, + AppointmentType: appointmentType, + PricedLineItems: getLineItemsFlattened(pricedLineItems), + ServiceLocation: { city: isMobileApt ? serviceLocationCity : null, state: isMobileApt ? serviceLocationState : null, zipCode: isMobileApt ? serviceLocationZipCode : null, }, - serverData: lineItemServerData ? lineItemServerData : "", + ServerData: lineItemServerData ? lineItemServerData : "", }, }).then((response) => { this.order.lineItems.serverData = response.data.serverData; From 3ff57ad9f988f9fbaca2903b72c471db1429cdae Mon Sep 17 00:00:00 2001 From: CarlNation Date: Sat, 10 Jan 2026 16:08:08 -0500 Subject: [PATCH 4/4] CASH-1925 CASH-192getITACPriceOrderItemsascalCasing --- src/store/index.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/store/index.js b/src/store/index.js index 3407cecf..d60533e4 100644 --- a/src/store/index.js +++ b/src/store/index.js @@ -2380,9 +2380,9 @@ export const useMainStore = defineStore({ AppointmentType: appointmentType, PricedLineItems: getLineItemsFlattened(pricedLineItems), ServiceLocation: { - city: isMobileApt ? serviceLocationCity : null, - state: isMobileApt ? serviceLocationState : null, - zipCode: isMobileApt ? serviceLocationZipCode : null, + City: isMobileApt ? serviceLocationCity : null, + State: isMobileApt ? serviceLocationState : null, + ZipCode: isMobileApt ? serviceLocationZipCode : null, }, ServerData: lineItemServerData ? lineItemServerData : "", },