Update schema

This commit is contained in:
Ramon Wenger 2021-05-06 11:20:27 +02:00
parent da85d3dbc2
commit 046b741458
2 changed files with 10 additions and 33 deletions

View File

@ -20,7 +20,7 @@ module.exports = (on, config) => {
on('task', {
getSchema() {
return readFileSync(
resolve(__dirname, '../../../schema.graphql'),
resolve(__dirname, '../../../server/schema.graphql'),
'utf8'
);
}

View File

@ -218,38 +218,17 @@ type ChapterBookmarkNodeEdge {
cursor: String!
}
type ChapterInSnapshotNode implements ChapterInterface {
id: ID!
chapter: ChapterNode!
snapshot: SnapshotNode!
titleHidden: Boolean
descriptionHidden: Boolean
description: String
title: String
}
type ChapterInSnapshotNodeConnection {
pageInfo: PageInfo!
edges: [ChapterInSnapshotNodeEdge]!
}
type ChapterInSnapshotNodeEdge {
node: ChapterInSnapshotNode
cursor: String!
}
interface ChapterInterface {
id: ID!
description: String
title: String
}
type ChapterNode implements ChapterInterface {
type ChapterNode implements Node & ChapterInterface {
title: String
slug: String!
description: String
titleHiddenFor(offset: Int, before: String, after: String, first: Int, last: Int, name: String): SchoolClassNodeConnection!
descriptionHiddenFor(offset: Int, before: String, after: String, first: Int, last: Int, name: String): SchoolClassNodeConnection!
titleHiddenFor: [SchoolClassNode]
descriptionHiddenFor: [SchoolClassNode]
id: ID!
bookmark: ChapterBookmarkNode
contentBlocks: [ContentBlockNode]
@ -300,13 +279,12 @@ input ContentBlockInput {
}
interface ContentBlockInterface {
id: ID!
title: String
contents: GenericStreamFieldType
type: String
}
type ContentBlockNode implements ContentBlockInterface {
type ContentBlockNode implements Node & ContentBlockInterface {
title: String
slug: String!
hiddenFor: [SchoolClassNode]
@ -724,7 +702,7 @@ type ObjectiveGroupNode implements Node {
id: ID!
title: ObjectiveGroupTitle
module: ModuleNode!
hiddenFor(offset: Int, before: String, after: String, first: Int, last: Int, name: String): SchoolClassNodeConnection!
hiddenFor: [SchoolClassNode]
objectives(offset: Int, before: String, after: String, first: Int, last: Int, text: String): ObjectiveNodeConnection!
pk: Int
displayTitle: String
@ -751,8 +729,8 @@ type ObjectiveNode implements Node {
text: String!
group: ObjectiveGroupNode!
owner: UserNode
hiddenFor(offset: Int, before: String, after: String, first: Int, last: Int, name: String): SchoolClassNodeConnection!
visibleFor(offset: Int, before: String, after: String, first: Int, last: Int, name: String): SchoolClassNodeConnection!
hiddenFor: [SchoolClassNode]
visibleFor: [SchoolClassNode]
order: Int
pk: Int
userCreated: Boolean
@ -903,7 +881,7 @@ type SchoolClassNodeEdge {
cursor: String!
}
type SnapshotChapterNode implements ChapterInterface {
type SnapshotChapterNode implements Node & ChapterInterface {
id: ID!
description: String
title: String
@ -912,7 +890,7 @@ type SnapshotChapterNode implements ChapterInterface {
titleHidden: Boolean
}
type SnapshotContentBlockNode implements ContentBlockInterface {
type SnapshotContentBlockNode implements Node & ContentBlockInterface {
id: ID!
title: String
contents: GenericStreamFieldType
@ -927,7 +905,6 @@ type SnapshotNode implements Node {
hiddenContentBlocks(offset: Int, before: String, after: String, first: Int, last: Int, slug: String, title: String): ContentBlockNodeConnection!
created: DateTime!
creator: UserNode
chapterSnapshots(offset: Int, before: String, after: String, first: Int, last: Int, id: ID): ChapterInSnapshotNodeConnection!
title: String
metaTitle: String
heroImage: String