added type of employees, for calling api

This commit is contained in:
Pramod Mahajan 2025-06-27 15:53:20 +05:30
parent 3802be1673
commit 7afea8e52a

View File

@ -20,7 +20,7 @@ import {useMutation} from "@tanstack/react-query";
const mobileNumberRegex = /^[0-9]\d{9}$/;
const ManageEmployee = ({ employeeId, onClosed }) => {
const ManageEmployee = ({ employeeId, onClosed,IsAllEmployee }) => {
const dispatch = useDispatch();
const { mutate: updateEmployee, isLoading } = useUpdateEmployee();
@ -203,7 +203,7 @@ const { mutate: updateEmployee, isLoading } = useUpdateEmployee();
data.email = null;
}
updateEmployee(data, {
updateEmployee({...data,IsAllEmployee},{
onSuccess: () => {
reset();
onClosed();