mirror of
https://github.com/bigcapitalhq/bigcapital.git
synced 2026-02-11 02:10:30 +00:00
Merge branch 'develop' of https://github.com/bigcapitalhq/client into develop
This commit is contained in:
@@ -27,6 +27,8 @@ function NotifyEstimateViaSMSForm({
|
||||
createNotifyEstimateBySMSMutate,
|
||||
} = useEstimateViaSMSContext();
|
||||
|
||||
const [calloutCode, setCalloutCode] = React.useState([]);
|
||||
|
||||
// Handles the form submit.
|
||||
const handleFormSubmit = (values, { setSubmitting, setErrors }) => {
|
||||
setSubmitting(true);
|
||||
@@ -47,7 +49,7 @@ function NotifyEstimateViaSMSForm({
|
||||
},
|
||||
}) => {
|
||||
if (errors) {
|
||||
transformErrors(errors, { setErrors });
|
||||
transformErrors(errors, { setErrors, setCalloutCode });
|
||||
}
|
||||
setSubmitting(false);
|
||||
};
|
||||
@@ -70,6 +72,7 @@ function NotifyEstimateViaSMSForm({
|
||||
notificationTypes={notificationType}
|
||||
onCancel={handleFormCancel}
|
||||
onSubmit={handleFormSubmit}
|
||||
calloutCodes={calloutCode}
|
||||
/>
|
||||
);
|
||||
}
|
||||
|
||||
@@ -30,6 +30,8 @@ function NotifyPaymentReceiveViaSMSForm({
|
||||
createNotifyPaymentReceivetBySMSMutate,
|
||||
} = useNotifyPaymentReceiveViaSMSContext();
|
||||
|
||||
const [calloutCode, setCalloutCode] = React.useState([]);
|
||||
|
||||
// Handles the form submit.
|
||||
const handleFormSubmit = (values, { setSubmitting, setErrors }) => {
|
||||
// Handle request response success.
|
||||
@@ -50,7 +52,7 @@ function NotifyPaymentReceiveViaSMSForm({
|
||||
},
|
||||
}) => {
|
||||
if (errors) {
|
||||
transformErrors(errors, { setErrors });
|
||||
transformErrors(errors, { setErrors, setCalloutCode });
|
||||
}
|
||||
setSubmitting(false);
|
||||
};
|
||||
@@ -75,6 +77,7 @@ function NotifyPaymentReceiveViaSMSForm({
|
||||
notificationTypes={notificationType}
|
||||
onSubmit={handleFormSubmit}
|
||||
onCancel={handleFormCancel}
|
||||
calloutCodes={calloutCode}
|
||||
/>
|
||||
);
|
||||
}
|
||||
|
||||
@@ -30,6 +30,8 @@ function NotifyReceiptViaSMSForm({
|
||||
createNotifyReceiptBySMSMutate,
|
||||
} = useNotifyReceiptViaSMSContext();
|
||||
|
||||
const [calloutCode, setCalloutCode] = React.useState([]);
|
||||
|
||||
// Handles the form submit.
|
||||
const handleFormSubmit = (values, { setSubmitting, setErrors }) => {
|
||||
// Handle request response success.
|
||||
@@ -48,7 +50,7 @@ function NotifyReceiptViaSMSForm({
|
||||
},
|
||||
}) => {
|
||||
if (errors) {
|
||||
transformErrors(errors, { setErrors });
|
||||
transformErrors(errors, { setErrors, setCalloutCode });
|
||||
}
|
||||
setSubmitting(false);
|
||||
};
|
||||
@@ -74,6 +76,7 @@ function NotifyReceiptViaSMSForm({
|
||||
notificationTypes={notificationType}
|
||||
onSubmit={handleFormSubmit}
|
||||
onCancel={handleFormCancel}
|
||||
calloutCodes={calloutCode}
|
||||
/>
|
||||
);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user