diff --git a/src/layouts/service-location/mobile-location-modal-questions/mobile-location-modal-questions.vue b/src/layouts/service-location/mobile-location-modal-questions/mobile-location-modal-questions.vue index 84f3d4e9c..4b0a4a1ac 100644 --- a/src/layouts/service-location/mobile-location-modal-questions/mobile-location-modal-questions.vue +++ b/src/layouts/service-location/mobile-location-modal-questions/mobile-location-modal-questions.vue @@ -73,21 +73,6 @@ import { // Validation import { useField } from "vee-validate"; -import { defineRule } from "vee-validate"; -import { errorMessages } from "@/constants/error-messages"; - -defineRule("mobile-location-required", (value) => { - if ( - value.addressQuestions.streetAddress == "" || - value.addressQuestions.city == "" || - value.addressQuestions.state == "" || - value.addressQuestions.zipCode == "" || - value.isVehicleProtected == null - ) { - return errorMessages.MOBILE_LOCATION_REQUIRED; - } - return true; -}); export default { name: "mobile-location-modal-questions", diff --git a/src/layouts/service-location/service-location.vue b/src/layouts/service-location/service-location.vue index 66f91dc7c..ebb0cf66a 100644 --- a/src/layouts/service-location/service-location.vue +++ b/src/layouts/service-location/service-location.vue @@ -100,6 +100,24 @@ import { } from "@/layouts/service-location/helpers/service-location-helper/service-location-helper"; import store from "@/store"; +// Validation +import { defineRule } from "vee-validate"; +import { errorMessages } from "@/constants/error-messages"; + +// DEFINE VALIDATION RULES +defineRule("mobile-location-required", (value) => { + if ( + value.addressQuestions.streetAddress == "" || + value.addressQuestions.city == "" || + value.addressQuestions.state == "" || + value.addressQuestions.zipCode == "" || + value.isVehicleProtected == null + ) { + return errorMessages.MOBILE_LOCATION_REQUIRED; + } + return true; +}); + export default { name: "service-location", data() {