Skip to content

Commit

Permalink
Fixed import and types
Browse files Browse the repository at this point in the history
  • Loading branch information
onehanddev committed Nov 14, 2024
1 parent b11f230 commit d4b6e17
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 14 deletions.
6 changes: 3 additions & 3 deletions client/src/app/my-projects/page.tsx
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import MyProjectsView from "../../containers/my-projects";
import { CustomProject } from "../../containers/my-projects/types";
import MyProjectsView from "@/containers/my-projects";
import { CustomProject } from "@/containers/my-projects/types";

const MOCK_DATA: CustomProject[] = Array.from({ length: 15 }, (_, i) => ({
id: i + 1,
id: String(i + 1),
projectName: "My custom project",
location: "Location",
totalNPVCost: Math.floor(1000000 + Math.random() * 9000000),
Expand Down
15 changes: 4 additions & 11 deletions client/src/containers/my-projects/types.ts
Original file line number Diff line number Diff line change
@@ -1,16 +1,9 @@
import { ProjectType } from "@shared/contracts/projects.contract";
import { ColumnDef } from "@tanstack/react-table";

type ProjectType = "Conservation" | "Restoration"; //todo: make this dynamic

export interface CustomProject {
id: number;
projectName: string;
location: string;
totalNPVCost: number;
abatementPotential: number;
type: ProjectType;
className?: string;
}
export type CustomProject = Partial<ProjectType> & {
type: string;
};

export type CustomColumn = ColumnDef<CustomProject, keyof CustomProject> & {
className?: string;
Expand Down

0 comments on commit d4b6e17

Please sign in to comment.