diff --git a/fittrackee_client/src/components/User/ProfileEdition/UserPrivacyPolicyValidation.vue b/fittrackee_client/src/components/User/ProfileEdition/UserPrivacyPolicyValidation.vue index d725d638..84d1b77e 100644 --- a/fittrackee_client/src/components/User/ProfileEdition/UserPrivacyPolicyValidation.vue +++ b/fittrackee_client/src/components/User/ProfileEdition/UserPrivacyPolicyValidation.vue @@ -13,7 +13,7 @@ {{ $t('user.PROFILE.BACK_TO_PROFILE') }} -
+
@@ -23,6 +23,7 @@ id="accepted_policy" required v-model="acceptedPolicy" + @invalid="invalidateForm" /> @@ -66,6 +67,7 @@ () => store.getters[ROOT_STORE.GETTERS.ERROR_MESSAGES] ) const acceptedPolicy = ref(false) + const formErrors = ref(false) function onSubmit() { store.dispatch( @@ -73,6 +75,9 @@ acceptedPolicy.value ) } + function invalidateForm() { + formErrors.value = true + } onUnmounted(() => { store.commit(ROOT_STORE.MUTATIONS.EMPTY_ERROR_MESSAGES)