From 1224b890db1a2e60dfdc7d42629f823745c8f306 Mon Sep 17 00:00:00 2001 From: Chirag Chhatrala <60499540+chiragchhatrala@users.noreply.github.com> Date: Mon, 25 Nov 2024 21:56:43 +0530 Subject: [PATCH 1/2] Fix phoneinput inputval watcher (#631) --- client/components/forms/PhoneInput.vue | 2 ++ 1 file changed, 2 insertions(+) diff --git a/client/components/forms/PhoneInput.vue b/client/components/forms/PhoneInput.vue index fd24784e..0673435d 100644 --- a/client/components/forms/PhoneInput.vue +++ b/client/components/forms/PhoneInput.vue @@ -124,6 +124,8 @@ export default { watch: { inputVal: { handler(val) { + if (!this.selectedCountryCode) return + if (val && val.startsWith("0")) { val = val.substring(1) } From 3d09f32078c6eaa648971987294f56e7257d119d Mon Sep 17 00:00:00 2001 From: Chirag Chhatrala <60499540+chiragchhatrala@users.noreply.github.com> Date: Tue, 26 Nov 2024 16:43:39 +0530 Subject: [PATCH 2/2] fix error display modal (#632) --- .../open/forms/components/FormEditor.vue | 4 ++-- .../form-components/FormErrorModal.vue | 20 +++++++------------ 2 files changed, 9 insertions(+), 15 deletions(-) diff --git a/client/components/open/forms/components/FormEditor.vue b/client/components/open/forms/components/FormEditor.vue index aeef0082..c608fdcb 100644 --- a/client/components/open/forms/components/FormEditor.vue +++ b/client/components/open/forms/components/FormEditor.vue @@ -259,7 +259,7 @@ export default { }) .catch((error) => { if (error?.response?.status === 422) { - this.validationErrorResponse = error.response.data + this.validationErrorResponse = error.data this.showValidationErrors() } else { useAlert().error( @@ -306,7 +306,7 @@ export default { }) .catch((error) => { if (error?.response?.status === 422) { - this.validationErrorResponse = error.response + this.validationErrorResponse = error.data this.showValidationErrors() } else { useAlert().error( diff --git a/client/components/open/forms/components/form-components/FormErrorModal.vue b/client/components/open/forms/components/form-components/FormErrorModal.vue index 98a10e1a..bbcca1c7 100644 --- a/client/components/open/forms/components/form-components/FormErrorModal.vue +++ b/client/components/open/forms/components/form-components/FormErrorModal.vue @@ -4,21 +4,21 @@ @close="$emit('close')" >
-

+

Error saving your form