Route Update
This commit is contained in:
parent
71ef8913d7
commit
bdd9849422
|
|
@ -53,10 +53,30 @@ const ProcessStepOne = () => {
|
|||
}, [])
|
||||
|
||||
const handleNextClick = async (isSendNow: boolean) => {
|
||||
if (!selectedDocuments.length || !selectedRecipients.length) {
|
||||
let formError = {
|
||||
documents: false,
|
||||
recipients: false,
|
||||
subject: false
|
||||
}
|
||||
|
||||
if (!selectedDocuments.length) {
|
||||
formError.documents = true
|
||||
}
|
||||
if (!selectedRecipients.length) {
|
||||
formError.recipients = true
|
||||
}
|
||||
if (!emailDtls.subject.length) {
|
||||
formError.subject = true
|
||||
}
|
||||
|
||||
if (formError.documents || formError.recipients || formError.subject) {
|
||||
console.log(selectedDocuments, 'line 193')
|
||||
toast.dismiss();
|
||||
toast.error("Add Documents | Recipients First", {
|
||||
toast.error(`${formError.documents ? "Add Document" : ""}
|
||||
${(formError.documents && formError.recipients) ? " | " : ""}
|
||||
${formError.recipients ? "Add Recipient" : ""}
|
||||
${(formError.documents || formError.recipients) ? " | " : ""}
|
||||
${formError.subject ? "Add Subject" : ""}`, {
|
||||
position: "top-center",
|
||||
autoClose: 5000,
|
||||
hideProgressBar: false,
|
||||
|
|
@ -218,7 +238,8 @@ const ProcessStepOne = () => {
|
|||
<label className='text-sm font-medium text-[var(--greyTextCol)] mb-1'>Subject</label>
|
||||
<input
|
||||
type="text"
|
||||
value={emailDtls.subject || "Documents for Signature"}
|
||||
required
|
||||
value={emailDtls.subject}
|
||||
onChange={(e) => setEmailDtls({ ...emailDtls, subject: e.target.value })}
|
||||
placeholder="Email Subject"
|
||||
className="w-full px-3 py-2 rounded border border-gray-300 focus:outline-none focus:ring-2 focus:ring-[var(--primary)]"
|
||||
|
|
|
|||
Loading…
Reference in New Issue