projects api refactor
This commit is contained in:
@@ -6,7 +6,7 @@ import { getUserData } from "../../functions/getUserData";
|
||||
import { useLoadingProgress, useProjectName, useSocketStore } from "../../store/builder/store";
|
||||
import OuterClick from "../../utils/outerClick";
|
||||
import { KebabIcon } from "../icons/ExportCommonIcons";
|
||||
import { getAllProjects } from "../../services/dashboard/getAllProjects";
|
||||
import { getAllProjectsApi } from "../../services/dashboard/getAllProjectsApi";
|
||||
// import { viewProject } from "../../services/dashboard/viewProject";
|
||||
// import { updateProject } from "../../services/dashboard/updateProject";
|
||||
|
||||
@@ -97,7 +97,7 @@ const DashboardCard: React.FC<DashBoardCardProps> = ({
|
||||
if (!projectId) return;
|
||||
|
||||
try {
|
||||
const projects = await getAllProjects(userId, organization);
|
||||
const projects = await getAllProjectsApi();
|
||||
const projectUuid = projects?.Projects?.find((val: any) => val.projectUuid === projectId || val._id === projectId);
|
||||
if (!projectUuid) return;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user