diff --git a/src/layouts/vehicle-parts/vehicle-parts.vue b/src/layouts/vehicle-parts/vehicle-parts.vue index 729faa973..b30a8c292 100644 --- a/src/layouts/vehicle-parts/vehicle-parts.vue +++ b/src/layouts/vehicle-parts/vehicle-parts.vue @@ -105,6 +105,9 @@ components: { }, computed: { isForwardActionDisabled() { + return Object.keys(this.matchedParts).length !== this.PartsFromApi.partsOrQuestions.length; + }, + matchedParts() { const matchedParts = []; // Match them to the parts from the API. @@ -114,9 +117,9 @@ computed: { if (selectedPartData) matchedParts.push(selectedPartData); - }) - - return Object.keys(matchedParts).length !== this.PartsFromApi.partsOrQuestions.length; + }) + + return matchedParts; }, PartsOrQuestions() { const partsData = this.PartsFromApi; @@ -177,7 +180,7 @@ methods: { } // Save parts to the store. - store.commit(storeMutations.UPDATE_GLASS_PARTS, matchedParts); + store.commit(storeMutations.UPDATE_GLASS_PARTS, this.matchedParts); // Navigate to the next page. // this.$router.navigateAfterSave(