#11 Fix gql response types
This commit is contained in:
parent
101817276f
commit
a07eb576eb
|
@ -19,7 +19,7 @@ export interface EditCategoryResponse {
|
|||
export interface EditCategoryVariables {
|
||||
id: string,
|
||||
title?: string,
|
||||
description?: string,
|
||||
description?: string | null,
|
||||
}
|
||||
|
||||
export const ADD_CATEGORY = gql`
|
||||
|
@ -41,7 +41,7 @@ export interface AddCategoryResponse {
|
|||
|
||||
export interface AddCategoryVariables {
|
||||
title: string,
|
||||
description?: string,
|
||||
description?: string | null,
|
||||
}
|
||||
|
||||
export const DELETE_CATEGORY = gql`
|
||||
|
|
|
@ -19,7 +19,7 @@ export interface EditQuestionResponse {
|
|||
export interface EditQuestionVariables {
|
||||
id: string,
|
||||
title?: string,
|
||||
description?: string,
|
||||
description?: string | null,
|
||||
categoryRowId?: number | null,
|
||||
}
|
||||
|
||||
|
@ -42,7 +42,7 @@ export interface AddQuestionResponse {
|
|||
|
||||
export interface AddQuestionVariables {
|
||||
title: string,
|
||||
description?: string,
|
||||
description?: string | null,
|
||||
categoryRowId?: number | null
|
||||
}
|
||||
|
||||
|
|
|
@ -13,7 +13,7 @@ export interface BasicCategoryResponse {
|
|||
id: string,
|
||||
rowId: number,
|
||||
title: string,
|
||||
description?: string,
|
||||
description: string | null,
|
||||
}
|
||||
|
||||
export const GET_ALL_CATEGORIES = gql`
|
||||
|
|
|
@ -29,8 +29,8 @@ export const BasicQuestionFragment = gql`
|
|||
export interface BasicQuestionResponse {
|
||||
id: string,
|
||||
title: string,
|
||||
description?: string,
|
||||
categoryByCategoryRowId?: GetQuestionsCategoryResponse
|
||||
description: string | null,
|
||||
categoryByCategoryRowId: GetQuestionsCategoryResponse | null
|
||||
}
|
||||
|
||||
export const GET_ALL_QUESTIONS = gql`
|
||||
|
|
|
@ -31,16 +31,16 @@ const useStyles = makeStyles((theme: Theme) =>
|
|||
}),
|
||||
);
|
||||
|
||||
interface QuestionProps {
|
||||
interface AccordionWithEditProps {
|
||||
key: string,
|
||||
title: string,
|
||||
description?: string,
|
||||
subTitle?: string,
|
||||
description: string | null,
|
||||
subTitle?: string | null,
|
||||
onEditButtonClick?(): void,
|
||||
onDeleteButtonClick?(): void,
|
||||
}
|
||||
|
||||
export default function AccordionWithEdit(props: QuestionProps) {
|
||||
export default function AccordionWithEdit(props: AccordionWithEditProps) {
|
||||
const classes = useStyles();
|
||||
|
||||
return (
|
||||
|
|
|
@ -9,7 +9,7 @@ import {DialogTitleAndDetails} from "./DialogTitleAndDetails";
|
|||
export interface ChangeCategoryDialogContent {
|
||||
id: string
|
||||
title: string,
|
||||
details?: string,
|
||||
details: string | null,
|
||||
}
|
||||
|
||||
interface ChangeCategoryDialogProps {
|
||||
|
|
|
@ -11,7 +11,7 @@ import {DialogTitleAndDetails} from "./DialogTitleAndDetails";
|
|||
export interface ChangeQuestionDialogContent {
|
||||
id: string
|
||||
title: string,
|
||||
details?: string,
|
||||
details: string | null,
|
||||
categoryId: number | null,
|
||||
}
|
||||
|
||||
|
|
|
@ -10,7 +10,7 @@ const useStyles = makeStyles((theme) => ({
|
|||
|
||||
interface DialogTitleAndDetailsProps {
|
||||
title: string,
|
||||
details?: string,
|
||||
details?: string | null,
|
||||
|
||||
handleTitleChange(newTitle: string): void,
|
||||
|
||||
|
|
Loading…
Reference in New Issue