From d9161985addb1bff6fe33193bc6a227f49577315 Mon Sep 17 00:00:00 2001 From: Ollie Halliday <22655069+Hallidayo@users.noreply.github.com> Date: Sun, 22 Oct 2023 17:06:53 +0100 Subject: [PATCH] check if date field is in use --- .../src/app/(signing)/sign/[token]/form.tsx | 44 ++++++++++--------- 1 file changed, 24 insertions(+), 20 deletions(-) diff --git a/apps/web/src/app/(signing)/sign/[token]/form.tsx b/apps/web/src/app/(signing)/sign/[token]/form.tsx index 9ba881cc0..5e161f96f 100644 --- a/apps/web/src/app/(signing)/sign/[token]/form.tsx +++ b/apps/web/src/app/(signing)/sign/[token]/form.tsx @@ -44,6 +44,8 @@ export const SigningForm = ({ document, recipient, fields }: SigningFormProps) = const [validateUninsertedFields, setValidateUninsertedFields] = useState(false); + const hasDateField = fields.find((field) => field.type === 'DATE'); + const { handleSubmit, formState: { isSubmitting }, @@ -113,27 +115,29 @@ export const SigningForm = ({ document, recipient, fields }: SigningFormProps) = /> -