Pramod_Bug#80 #38
@ -41,7 +41,7 @@ const ManageEmployee = () => {
|
|||||||
MiddleName: z.string().optional(),
|
MiddleName: z.string().optional(),
|
||||||
LastName: z.string().min(1, { message: "Last Name is required" }),
|
LastName: z.string().min(1, { message: "Last Name is required" }),
|
||||||
Email: z
|
Email: z
|
||||||
.string().max(225,"Email cannot exceed 255 characters")
|
.string().max(80,"Email cannot exceed 80 characters")
|
||||||
.optional()
|
.optional()
|
||||||
.refine((val) => !val || /^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(val), {
|
.refine((val) => !val || /^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(val), {
|
||||||
message: "Invalid email format",
|
message: "Invalid email format",
|
||||||
@ -257,7 +257,7 @@ const ManageEmployee = () => {
|
|||||||
</span>
|
</span>
|
||||||
</div>
|
</div>
|
||||||
<div className="card-body">
|
<div className="card-body">
|
||||||
{!currentEmployee && empLoading && (
|
{(!currentEmployee && empLoading) && (
|
||||||
<p>Loading Employee Data...</p>
|
<p>Loading Employee Data...</p>
|
||||||
)}
|
)}
|
||||||
|
|
||||||
@ -330,7 +330,7 @@ const ManageEmployee = () => {
|
|||||||
{...register("Email")}
|
{...register("Email")}
|
||||||
className="form-control form-control-sm"
|
className="form-control form-control-sm"
|
||||||
placeholder="example@domain.com"
|
placeholder="example@domain.com"
|
||||||
maxLength={255}
|
maxLength={80}
|
||||||
aria-describedby="Email"
|
aria-describedby="Email"
|
||||||
disabled={!!currentEmployee?.email}
|
disabled={!!currentEmployee?.email}
|
||||||
/>
|
/>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user