Clearing out duplicate orders.
This commit is contained in:
parent
2b4f76db7f
commit
f807ba20ca
2 changed files with 9 additions and 0 deletions
|
|
@ -310,6 +310,12 @@ export default {
|
|||
this.mainStore.updatePolicyData(this.welcomePageModel);
|
||||
const promises = [];
|
||||
promises.push(this.configureZip().then(async () => await this.mainStore.getBillToInfo()));
|
||||
|
||||
// Clear duplicate orders if navigating away from the welcome page after visiting duplicate check page.
|
||||
if (this.mainStore.order.visitedDuplicateCheckPage) {
|
||||
this.mainStore.clearDuplicateOrders();
|
||||
}
|
||||
|
||||
// Skip duplicate check if loaded from cookie or already visited duplicate check page.
|
||||
if (!this.mainStore.order.loadedFromCookie && !this.mainStore.order.visitedDuplicateCheckPage) {
|
||||
promises.push(this.mainStore.getDuplicateReferrals());
|
||||
|
|
|
|||
|
|
@ -596,6 +596,9 @@ export const useMainStore = defineStore({
|
|||
return Promise.reject(e);
|
||||
}
|
||||
},
|
||||
clearDuplicateOrders() {
|
||||
this.applicationUser.duplicateOrders = [];
|
||||
},
|
||||
updateDuplicateCheckVisited(visited) {
|
||||
this.order.visitedDuplicateCheckPage = visited;
|
||||
},
|
||||
|
|
|
|||
Loading…
Reference in a new issue