hide dependent fields until parent selection; handle undefined project ID in useProjectDetails
This commit is contained in:
parent
498665c811
commit
8de7b4b5c3
@ -21,7 +21,7 @@ const ProjectInfra = ({
|
||||
eachSiteEngineer,
|
||||
}) => {
|
||||
const [expandedBuildings, setExpandedBuildings] = useState([]);
|
||||
const { projects_Details,refetch, loading } = useProjectDetails(data.id);
|
||||
const { projects_Details,refetch, loading } = useProjectDetails(data?.id);
|
||||
const [project, setProject] = useState(projects_Details);
|
||||
const [modalConfig, setModalConfig] = useState({ type: null, data: null });
|
||||
const [isModalOpen, setIsModalOpen] = useState(false);
|
||||
|
Loading…
x
Reference in New Issue
Block a user