mirror of
https://github.com/documenso/documenso.git
synced 2025-11-15 17:21:41 +10:00
check if date field is in use
This commit is contained in:
@ -44,6 +44,8 @@ export const SigningForm = ({ document, recipient, fields }: SigningFormProps) =
|
|||||||
|
|
||||||
const [validateUninsertedFields, setValidateUninsertedFields] = useState(false);
|
const [validateUninsertedFields, setValidateUninsertedFields] = useState(false);
|
||||||
|
|
||||||
|
const hasDateField = fields.find((field) => field.type === 'DATE');
|
||||||
|
|
||||||
const {
|
const {
|
||||||
handleSubmit,
|
handleSubmit,
|
||||||
formState: { isSubmitting },
|
formState: { isSubmitting },
|
||||||
@ -113,6 +115,7 @@ export const SigningForm = ({ document, recipient, fields }: SigningFormProps) =
|
|||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
{hasDateField && (
|
||||||
<div>
|
<div>
|
||||||
<Label htmlFor="date-format">Date Format</Label>
|
<Label htmlFor="date-format">Date Format</Label>
|
||||||
|
|
||||||
@ -134,6 +137,7 @@ export const SigningForm = ({ document, recipient, fields }: SigningFormProps) =
|
|||||||
</SelectContent>
|
</SelectContent>
|
||||||
</Select>
|
</Select>
|
||||||
</div>
|
</div>
|
||||||
|
)}
|
||||||
|
|
||||||
<div>
|
<div>
|
||||||
<Label htmlFor="Signature">Signature</Label>
|
<Label htmlFor="Signature">Signature</Label>
|
||||||
|
|||||||
Reference in New Issue
Block a user