fix: fixed typing in ProjectModal, removed unused DealStatus enum
This commit is contained in:
@@ -1,8 +1,7 @@
|
||||
import { useDealSummariesFull } from "./useDealSummaries.tsx";
|
||||
import { useForm } from "@mantine/form";
|
||||
import { useEffect, useState } from "react";
|
||||
import { BaseMarketplaceSchema, BoardSchema, ClientSchema, ProjectSchema } from "../../../client";
|
||||
import { DealStatusType } from "../../../shared/enums/DealStatus.ts";
|
||||
import { BaseMarketplaceSchema, BoardSchema, ClientSchema, ProjectSchema, StatusSchema } from "../../../client";
|
||||
|
||||
|
||||
type Props = {
|
||||
@@ -17,7 +16,7 @@ export type DealsPageState = {
|
||||
|
||||
projectForTable: ProjectSchema | null;
|
||||
board: BoardSchema | null;
|
||||
dealStatus: DealStatusType | null;
|
||||
dealStatus: StatusSchema | null;
|
||||
};
|
||||
|
||||
const useDealsPageState = ({ projects }: Props) => {
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
import { useEffect, useState } from "react";
|
||||
import { ProjectSchema, ProjectService } from "../../../client";
|
||||
import { type ProjectSchemaWithCount, ProjectService } from "../../../client";
|
||||
|
||||
|
||||
const useProjects = () => {
|
||||
const [projects, setProjects] = useState<ProjectSchema[]>([]);
|
||||
const [projects, setProjects] = useState<ProjectSchemaWithCount[]>([]);
|
||||
|
||||
const refetchProjects = () => {
|
||||
ProjectService.getProjects()
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { ProjectSchema } from "../../../../client";
|
||||
import { type ProjectSchemaWithCount } from "../../../../client";
|
||||
import { ContextModalProps } from "@mantine/modals";
|
||||
import { ActionIcon, Flex, rem, Stack, TextInput, Tooltip } from "@mantine/core";
|
||||
import { BaseTable } from "../../../../components/BaseTable/BaseTable.tsx";
|
||||
@@ -75,7 +75,7 @@ const ProjectsModal = ({ innerProps }: ContextModalProps<Props>) => {
|
||||
</Tooltip>
|
||||
</Flex>
|
||||
),
|
||||
} as MRT_TableOptions<ProjectSchema>
|
||||
} as MRT_TableOptions<ProjectSchemaWithCount>
|
||||
}
|
||||
/>
|
||||
</Stack>
|
||||
|
||||
@@ -1,10 +0,0 @@
|
||||
import { BaseMarketplaceSchema, ClientSchema, UserSchema } from "../../../client";
|
||||
import { DealStatusType } from "../../../shared/enums/DealStatus.ts";
|
||||
|
||||
export interface ChartFormFilters {
|
||||
dateRange: [Date | null, Date | null];
|
||||
client: ClientSchema | null;
|
||||
marketplace: BaseMarketplaceSchema | null;
|
||||
dealStatus: DealStatusType | null;
|
||||
manager: UserSchema | null;
|
||||
}
|
||||
Reference in New Issue
Block a user