diff --git a/public/css/README.md b/public/css/README.md
index f08e6c6d7..74cd82e39 100644
--- a/public/css/README.md
+++ b/public/css/README.md
@@ -3,11 +3,11 @@
This public/css folder uses a standalone .scss > .css setup.
## Usage
-From a Terminal window, run the Sass Watch command on this folder only:
+From a Terminal window, run the Sass Watch command from the public folder only:
```bash
-sass --no-source-map --watch public/css/hop-styling.scss:public/css/hop-styling.css
+sass --no-source-map --watch scss:css
```
-This will output a CSS file that can be consumed by the Payment page.
+This will compile and output .css files (into the public/css folder) that can be consumed by the Payment page.
-# Do not use the .css file on its own. You must use the .scss file and have Sass compile it to the .css file.
+# Do not use the .css files on their own. You must use the .scss files and have Sass compile them to .css files.
diff --git a/public/css/hop-styling.css b/public/css/hop-styling.css
index ded3578c8..1f0b0ddc2 100644
--- a/public/css/hop-styling.css
+++ b/public/css/hop-styling.css
@@ -15,6 +15,7 @@ body .validation-info {
}
body .italicSmall {
font-style: normal;
+ font-size: 14px;
}
body span {
line-height: 24px;
@@ -27,7 +28,7 @@ body .form-group {
display: flex;
flex-direction: column;
}
-body h2 {
+body .headerlinecontainer .headerline1 {
font-size: 20px;
line-height: 32px;
font-weight: 400;
@@ -76,12 +77,12 @@ body .creditCardSpecific div {
body .creditCardSpecific div .headerlinecontainer {
padding: 0;
}
-body .creditCardSpecific div .headerlinecontainer .headerline5v2 {
- display: none;
-}
body .creditCardSpecific div label {
font-weight: 500;
}
+body .creditCardSpecific div:first-child {
+ display: none;
+}
body .creditCardSpecific #infoRow2 {
margin-bottom: 0;
}
@@ -91,7 +92,7 @@ body #cardExpirationContainer {
justify-content: space-between;
padding: 0;
}
-@media (min-width: 368px) {
+@media (min-width: 400px) {
body #cardExpirationContainer {
flex-direction: row;
}
@@ -116,7 +117,6 @@ body .optional-label:after {
}
body .buttonContainer {
height: 48px;
- margin-top: 36px;
}
body .buttonContainer button {
position: relative;
diff --git a/public/css/site-2020Styling.css b/public/css/site-2020Styling.css
new file mode 100644
index 000000000..4aacb297d
--- /dev/null
+++ b/public/css/site-2020Styling.css
@@ -0,0 +1,90 @@
+/* IMPORTANT: READ README.md in this folder! Do not edit .css file directly! */
+/* IMPORTANT: READ README.md in this folder! Do not edit .css file directly! */
+/* IMPORTANT: READ README.md in this folder! Do not edit .css file directly! */
+/* IMPORTANT: READ README.md in this folder! Do not edit .css file directly! */
+/* Style the modal when PayPal button is selected */
+#pageLoadingModal {
+ position: fixed;
+ top: 0;
+ right: 0;
+ bottom: 0;
+ left: 0;
+ z-index: 1040;
+ width: 100%;
+ height: 100%;
+ background-color: rgba(0, 0, 0, 0.35);
+ display: flex;
+}
+#pageLoadingModal .modal-content {
+ margin: auto auto;
+}
+#pageLoadingModal p {
+ margin: 0;
+ text-transform: uppercase;
+ font-size: 14px;
+}
+#pageLoadingModal .modal {
+ display: none;
+ overflow: hidden;
+ position: fixed;
+ top: 0;
+ right: 0;
+ bottom: 0;
+ left: 0;
+ z-index: 1040;
+ -webkit-overflow-scrolling: touch;
+ outline: 0;
+}
+#pageLoadingModal .modal-content {
+ position: relative;
+ background-color: #fff;
+ border-radius: 8px;
+ background-clip: padding-box;
+ outline: 0;
+ width: 168px;
+ height: 168px;
+ display: flex;
+ justify-content: center;
+ align-items: center;
+}
+#pageLoadingModal .modal-content:before, #pageLoadingModal .modal-content:after {
+ content: "";
+ border-radius: 50%;
+ position: absolute;
+ inset: 0;
+ box-shadow: 0 0 3px 2px rgba(0, 0, 0, 0.25) inset;
+ top: 24px;
+ bottom: 24px;
+ right: 24px;
+ left: 24px;
+}
+#pageLoadingModal .modal-content:after {
+ box-shadow: 0 3px 0 #da291c inset;
+ animation: rotate 1s linear infinite;
+}
+#pageLoadingModal .modal-backdrop {
+ position: absolute;
+ top: 0;
+ right: 0;
+ left: 0;
+ background-color: #000000;
+}
+#pageLoadingModal .modal-backdrop.fade {
+ opacity: 0;
+ filter: alpha(opacity=0);
+}
+#pageLoadingModal.hide {
+ display: none;
+}
+
+@keyframes rotate {
+ 0% {
+ transform: rotate(0);
+ }
+ 100% {
+ transform: rotate(360deg);
+ }
+}
+.creditCardSpecific {
+ display: none;
+}
diff --git a/public/css/hop-styling.scss b/public/scss/hop-styling.scss
similarity index 95%
rename from public/css/hop-styling.scss
rename to public/scss/hop-styling.scss
index 81b798b78..0e646a591 100644
--- a/public/css/hop-styling.scss
+++ b/public/scss/hop-styling.scss
@@ -16,6 +16,7 @@ body {
.italicSmall {
font-style: normal;
+ font-size: 14px;
}
span {
@@ -32,11 +33,13 @@ body {
flex-direction: column;
}
- h2 {
- font-size: 20px;
- line-height: 32px;
- font-weight: 400;
- margin: 24px 0;
+ .headerlinecontainer {
+ .headerline1 {
+ font-size: 20px;
+ line-height: 32px;
+ font-weight: 400;
+ margin: 24px 0;
+ }
}
input,
@@ -86,13 +89,13 @@ body {
padding: 8px 0;
.headerlinecontainer {
padding: 0;
- .headerline5v2 {
- display: none;
- }
}
label {
font-weight: 500;
}
+ &:first-child {
+ display: none;
+ }
}
#infoRow2 {
margin-bottom: 0;
@@ -104,7 +107,7 @@ body {
flex-direction: column;
justify-content: space-between;
padding: 0;
- @media (min-width: 368px) {
+ @media (min-width: 400px) {
flex-direction: row;
.card_expirationYear,
.card_expirationMonth {
@@ -132,7 +135,6 @@ body {
.buttonContainer {
height: 48px;
- margin-top: 36px;
button {
position: relative;
background: linear-gradient(270deg, #1574a1 0%, #003d58 100%);
diff --git a/public/scss/site-2020Styling.scss b/public/scss/site-2020Styling.scss
new file mode 100644
index 000000000..4630bfdfc
--- /dev/null
+++ b/public/scss/site-2020Styling.scss
@@ -0,0 +1,95 @@
+/* IMPORTANT: READ README.md in this folder! Do not edit .css file directly! */
+/* IMPORTANT: READ README.md in this folder! Do not edit .css file directly! */
+/* IMPORTANT: READ README.md in this folder! Do not edit .css file directly! */
+/* IMPORTANT: READ README.md in this folder! Do not edit .css file directly! */
+
+/* Style the modal when PayPal button is selected */
+#pageLoadingModal {
+ position: fixed;
+ top: 0;
+ right: 0;
+ bottom: 0;
+ left: 0;
+ z-index: 1040;
+ width: 100%;
+ height: 100%;
+ background-color: rgba(0,0,0,.35);
+ display: flex;
+
+ .modal-content {
+ margin: auto auto;
+ }
+
+ p {
+ margin: 0;
+ text-transform: uppercase;
+ font-size: 14px;
+ }
+
+ .modal {
+ display: none;
+ overflow: hidden;
+ position: fixed;
+ top: 0;
+ right: 0;
+ bottom: 0;
+ left: 0;
+ z-index: 1040;
+ -webkit-overflow-scrolling: touch;
+ outline: 0;
+ }
+
+ .modal-content {
+ position: relative;
+ background-color: #fff;
+ border-radius: 8px;
+ background-clip: padding-box;
+ outline: 0;
+ width: 168px;
+ height: 168px;
+ display: flex;
+ justify-content: center;
+ align-items: center;
+ &:before,
+ &:after {
+ content: '';
+ border-radius: 50%;
+ position: absolute;
+ inset: 0;
+ box-shadow: 0 0 3px 2px rgba(0, 0, 0, 0.25) inset;
+ top: 24px;
+ bottom: 24px;
+ right: 24px;
+ left: 24px;
+ }
+ &:after {
+ box-shadow: 0 3px 0 #da291c inset;
+ animation: rotate 1s linear infinite;
+ }
+ }
+
+ .modal-backdrop {
+ position: absolute;
+ top: 0;
+ right: 0;
+ left: 0;
+ background-color: #000000;
+ &.fade {
+ opacity: 0;
+ filter: alpha(opacity=0);
+ }
+ }
+
+ &.hide {
+ display: none;
+ }
+}
+
+@keyframes rotate {
+ 0% { transform: rotate(0)}
+ 100% { transform: rotate(360deg)}
+}
+
+.creditCardSpecific {
+ display: none;
+}
diff --git a/src/constants/store-actions.js b/src/constants/store-actions.js
index 64e6df3aa..bb2ef16a0 100644
--- a/src/constants/store-actions.js
+++ b/src/constants/store-actions.js
@@ -89,9 +89,6 @@ const storeActions = {
SAVE_PROMOS: "savePromos",
SAVE_CUSTOMER_DETAILS: "saveCustomerDetails",
SAVE_SERVICE_LOCATION_TECH_NOTES: "saveServiceLocationTechNotes",
- SAVE_WORK_ORDER_FLAG: "saveWorkOrderFlag",
- SAVE_PIA_ERROR_CODE: "savePiaErrorCode",
- SAVE_PIA_WORK_ORDER: "savePiaWorkOrder",
SAVE_CCTOKEN: "saveCCToken",
SAVE_PAYPAL_TOKEN: "savePaypalToken",
};
diff --git a/src/constants/store-mutations.js b/src/constants/store-mutations.js
index 9e2e30a14..b7ac47d38 100644
--- a/src/constants/store-mutations.js
+++ b/src/constants/store-mutations.js
@@ -1,8 +1,5 @@
const storeMutations = {
// PAYMENT MUTATIONS
- UPDATE_WORK_ORDER_FLAG: "updateWorkOrderFlag",
- UPDATE_PIA_ERROR_CODE: "updatePiaErrorCode",
- UPDATE_PIA_WORK_ORDER: "updatePiaWorkOrder",
UPDATE_CCTOKEN: "updateCCToken",
UPDATE_PAYPAL_TOKEN: "updatePaypalToken",
diff --git a/src/helpers/heritage-integration/order-helper.js b/src/helpers/heritage-integration/order-helper.js
index 91f4768f3..01a5a780f 100644
--- a/src/helpers/heritage-integration/order-helper.js
+++ b/src/helpers/heritage-integration/order-helper.js
@@ -53,17 +53,30 @@ export async function loadSessionIfPresent(isConceptInsurance, pageNameToLog) {
This will also set Referral information in the store after saving, and then
update the cookie. To force synchronous behavior pass in 'true' for shouldAwaitSaveSessionQueue
*/
-export async function saveSession({ pageNameToLog, shouldAwaitSaveSessionQueue = false }) {
+export async function saveSession({
+ pageNameToLog,
+ shouldAwaitSaveSessionQueue = false,
+ submitAfterSave = false,
+ createDeleteStatusWorkOrderForPia = false,
+}) {
var saveSessionPromise;
if (store.getters.applicationUser.saveSessionPromise) {
// queue newest request after current saveSessionPromise resolves
saveSessionPromise = store.getters.applicationUser.saveSessionPromise.then(() => {
// get a new saveSessionPromise
- return saveSessionHelper(pageNameToLog);
+ return saveSessionHelper(
+ pageNameToLog,
+ submitAfterSave,
+ createDeleteStatusWorkOrderForPia
+ );
});
} else {
// create an initial saveSessionPromise
- saveSessionPromise = saveSessionHelper(pageNameToLog);
+ saveSessionPromise = saveSessionHelper(
+ pageNameToLog,
+ submitAfterSave,
+ createDeleteStatusWorkOrderForPia
+ );
}
store.commit(storeMutations.UPDATE_SAVE_SESSION_PROMISE, saveSessionPromise);
// await here to allow for a caller to await and make the function synchronous
@@ -72,10 +85,16 @@ export async function saveSession({ pageNameToLog, shouldAwaitSaveSessionQueue =
}
}
-export async function submitWorkOrder({ pageNameToLog }) {
+export async function submitWorkOrder({
+ pageNameToLog,
+ submitAfterSave = false,
+ createDeleteStatusWorkOrderForPia = false,
+}) {
await saveSession({
pageNameToLog: pageNameToLog,
shouldAwaitSaveSessionQueue: true,
+ submitAfterSave: submitAfterSave,
+ createDeleteStatusWorkOrderForPia: createDeleteStatusWorkOrderForPia,
});
}
@@ -117,10 +136,17 @@ async function loadSession(
/*
Encapsulates asynchronous Save Session logic inside a promise to allow for Save Session queuing
*/
-async function saveSessionHelper(pageNameToLog) {
+async function saveSessionHelper(
+ pageNameToLog,
+ submitAfterSave = false,
+ createDeleteStatusWorkOrderForPia = false
+) {
const savedSessionInfo = await baseMixin.methods.dispatchStoreActionWithLogging(
storeActions.SAVE_SESSION,
- null,
+ {
+ submitAfterSave: submitAfterSave,
+ createDeleteStatusWorkOrderForPia: createDeleteStatusWorkOrderForPia,
+ },
pageNameToLog
);
// Update the store with information received from the saveSession response
diff --git a/src/helpers/heritage-integration/order-helper.spec.js b/src/helpers/heritage-integration/order-helper.spec.js
index 322d9237d..daf9af6bb 100644
--- a/src/helpers/heritage-integration/order-helper.spec.js
+++ b/src/helpers/heritage-integration/order-helper.spec.js
@@ -179,7 +179,7 @@ describe("saveSession", () => {
// Assert
expect(mocks.baseMixin.methods.dispatchStoreActionWithLogging).toHaveBeenCalledWith(
storeActions.SAVE_SESSION,
- null,
+ { createDeleteStatusWorkOrderForPia: false, submitAfterSave: false },
"test"
);
expect(mocks.baseMixin.methods.dispatchStoreAction).toHaveBeenCalledWith(
@@ -282,12 +282,12 @@ describe("submitWorkOrder", () => {
const mocks = setupMocksForJsFiles(mockData);
// Act
- await submitWorkOrder({ pageNameToLog: "test" });
+ await submitWorkOrder({ pageNameToLog: "test", submitAfterSave: true });
// Assert
expect(mocks.baseMixin.methods.dispatchStoreActionWithLogging).toHaveBeenCalledWith(
storeActions.SAVE_SESSION,
- null,
+ { createDeleteStatusWorkOrderForPia: false, submitAfterSave: true },
"test"
);
expect(mocks.baseMixin.methods.dispatchStoreAction).toHaveBeenCalledWith(
@@ -345,7 +345,7 @@ describe("submitWorkOrder", () => {
setupCookies({ funnelCookieValue: JSON.stringify(testCookieValue) });
// Act
- await submitWorkOrder({ pageNameToLog: "test" });
+ await submitWorkOrder({ pageNameToLog: "test", submitAfterSave: true });
// Assert
expect(cookieHelper.getFunnelCookie().DidHeritageFunnelUpdateLast).toEqual(false);
diff --git a/src/layouts/confirmation/confirmation.vue b/src/layouts/confirmation/confirmation.vue
index 5adcc5613..b958d5b9f 100644
--- a/src/layouts/confirmation/confirmation.vue
+++ b/src/layouts/confirmation/confirmation.vue
@@ -244,7 +244,7 @@ export default {
diff --git a/src/layouts/payment-method/payment-method.spec.js b/src/layouts/payment-method/payment-method.spec.js
index 803f10829..8cba373de 100644
--- a/src/layouts/payment-method/payment-method.spec.js
+++ b/src/layouts/payment-method/payment-method.spec.js
@@ -50,12 +50,13 @@ function setupMocks() {
lineItems: [],
order: {
payment: {
- piaErrorCode: "",
+ isPia: false,
},
},
};
const mountOptions = getMountOptions({
+ route: { query: {}, params: {} },
router: {
navigate: jest.fn(),
navigateWithSaving: jest.fn(),
diff --git a/src/layouts/payment-method/payment-method.vue b/src/layouts/payment-method/payment-method.vue
index 65e9c9f32..58dfdaead 100644
--- a/src/layouts/payment-method/payment-method.vue
+++ b/src/layouts/payment-method/payment-method.vue
@@ -35,7 +35,7 @@