mirror of
https://github.com/documenso/documenso.git
synced 2025-11-15 17:21:41 +10:00
feat: remove console logs and updated the disabled property on input elements
This commit is contained in:
@ -77,7 +77,6 @@ export const AddSignersFormPartial = ({
|
||||
const { mutateAsync: addSigners } = trpc.recipient.addSigners.useMutation({
|
||||
...DO_NOT_INVALIDATE_QUERY_ON_MUTATION,
|
||||
onSuccess: (newRecipients) => {
|
||||
console.log('add signer mutation', newRecipients);
|
||||
utils.document.getDocumentWithDetailsById.setData(
|
||||
{
|
||||
id: document.id,
|
||||
@ -91,7 +90,6 @@ export const AddSignersFormPartial = ({
|
||||
const { mutateAsync: deleteSigner } = trpc.recipient.removeSigner.useMutation({
|
||||
...DO_NOT_INVALIDATE_QUERY_ON_MUTATION,
|
||||
onSuccess: (deletedRecipient) => {
|
||||
console.log('delete signer mutation', deletedRecipient);
|
||||
utils.document.getDocumentWithDetailsById.setData(
|
||||
{
|
||||
id: document.id,
|
||||
|
||||
@ -209,6 +209,8 @@ export const AddTemplatePlaceholderRecipientsFormPartial = ({
|
||||
try {
|
||||
const currentSigner = form.getValues(`signers.${index}`);
|
||||
|
||||
console.log('currentSigner', currentSigner);
|
||||
|
||||
if (!currentSigner.email) {
|
||||
return;
|
||||
}
|
||||
@ -296,12 +298,7 @@ export const AddTemplatePlaceholderRecipientsFormPartial = ({
|
||||
type="email"
|
||||
placeholder="Email"
|
||||
{...field}
|
||||
disabled={
|
||||
field.disabled ||
|
||||
isSubmitting ||
|
||||
signers[index].email === user?.email ||
|
||||
isSignerDirectRecipient(signer)
|
||||
}
|
||||
disabled={field.disabled || isSubmitting}
|
||||
onBlur={() => void handleOnBlur(index)}
|
||||
/>
|
||||
</FormControl>
|
||||
@ -327,12 +324,7 @@ export const AddTemplatePlaceholderRecipientsFormPartial = ({
|
||||
<Input
|
||||
placeholder="Name"
|
||||
{...field}
|
||||
disabled={
|
||||
field.disabled ||
|
||||
isSubmitting ||
|
||||
signers[index].email === user?.email ||
|
||||
isSignerDirectRecipient(signer)
|
||||
}
|
||||
disabled={field.disabled || isSubmitting}
|
||||
onBlur={() => void handleOnBlur(index)}
|
||||
/>
|
||||
</FormControl>
|
||||
|
||||
Reference in New Issue
Block a user