Display snapshot module detail
This commit is contained in:
parent
ca549e93e5
commit
70e7dc39a9
|
|
@ -55,154 +55,160 @@
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import ContentBlock from '@/components/ContentBlock';
|
import ContentBlock from '@/components/ContentBlock';
|
||||||
import AddContentButton from '@/components/AddContentButton';
|
import AddContentButton from '@/components/AddContentButton';
|
||||||
import BookmarkActions from '@/components/notes/BookmarkActions';
|
import BookmarkActions from '@/components/notes/BookmarkActions';
|
||||||
import VisibilityAction from '@/components/visibility/VisibilityAction';
|
import VisibilityAction from '@/components/visibility/VisibilityAction';
|
||||||
|
|
||||||
import {mapState} from 'vuex';
|
import {mapState} from 'vuex';
|
||||||
import {hidden} from '@/helpers/visibility';
|
import {hidden} from '@/helpers/visibility';
|
||||||
import {CONTENT_TYPE, CHAPTER_DESCRIPTION_TYPE, CHAPTER_TITLE_TYPE} from '@/consts/types';
|
import {CHAPTER_DESCRIPTION_TYPE, CHAPTER_TITLE_TYPE, CONTENT_TYPE} from '@/consts/types';
|
||||||
|
|
||||||
import UPDATE_CHAPTER_BOOKMARK_MUTATION from '@/graphql/gql/mutations/updateChapterBookmark.gql';
|
import UPDATE_CHAPTER_BOOKMARK_MUTATION from '@/graphql/gql/mutations/updateChapterBookmark.gql';
|
||||||
import CHAPTER_QUERY from '@/graphql/gql/queries/chapterQuery.gql';
|
import CHAPTER_QUERY from '@/graphql/gql/queries/chapterQuery.gql';
|
||||||
|
|
||||||
import me from '@/mixins/me';
|
import me from '@/mixins/me';
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
props: ['chapter', 'index'],
|
props: ['chapter', 'index'],
|
||||||
|
|
||||||
mixins: [me],
|
mixins: [me],
|
||||||
|
|
||||||
components: {
|
components: {
|
||||||
BookmarkActions,
|
BookmarkActions,
|
||||||
VisibilityAction,
|
VisibilityAction,
|
||||||
ContentBlock,
|
ContentBlock,
|
||||||
AddContentButton
|
AddContentButton,
|
||||||
},
|
|
||||||
|
|
||||||
computed: {
|
|
||||||
...mapState(['editModule']),
|
|
||||||
filteredContentBlocks() {
|
|
||||||
if (!(this.chapter && this.chapter.contentBlocks)) {
|
|
||||||
return [];
|
|
||||||
}
|
|
||||||
if (this.editModule) {
|
|
||||||
return this.chapter.contentBlocks;
|
|
||||||
}
|
|
||||||
return this.chapter.contentBlocks.filter(contentBlock => !hidden({
|
|
||||||
block: contentBlock,
|
|
||||||
schoolClass: this.schoolClass,
|
|
||||||
type: CONTENT_TYPE
|
|
||||||
}));
|
|
||||||
},
|
},
|
||||||
note() {
|
|
||||||
if (this.chapter && this.chapter.bookmark) {
|
|
||||||
return this.chapter.bookmark.note;
|
|
||||||
}
|
|
||||||
},
|
|
||||||
titleGreyedOut() {
|
|
||||||
return this.textHidden(CHAPTER_TITLE_TYPE) && this.editModule;
|
|
||||||
},
|
|
||||||
// never hidden when editing the module
|
|
||||||
titleHidden() {
|
|
||||||
return this.textHidden(CHAPTER_TITLE_TYPE) && !this.editModule;
|
|
||||||
},
|
|
||||||
descriptionGreyedOut() {
|
|
||||||
return this.textHidden(CHAPTER_DESCRIPTION_TYPE) && this.editModule;
|
|
||||||
},
|
|
||||||
// never hidden when editing the module
|
|
||||||
descriptionHidden() {
|
|
||||||
return this.textHidden(CHAPTER_DESCRIPTION_TYPE) && !this.editModule;
|
|
||||||
}
|
|
||||||
},
|
|
||||||
|
|
||||||
methods: {
|
computed: {
|
||||||
bookmark(bookmarked) {
|
...mapState(['editModule']),
|
||||||
const id = this.chapter.id;
|
filteredContentBlocks() {
|
||||||
this.$apollo.mutate({
|
if (!(this.chapter && this.chapter.contentBlocks)) {
|
||||||
mutation: UPDATE_CHAPTER_BOOKMARK_MUTATION,
|
return [];
|
||||||
variables: {
|
|
||||||
input: {
|
|
||||||
chapter: id,
|
|
||||||
bookmarked
|
|
||||||
}
|
|
||||||
},
|
|
||||||
update: (store, response) => {
|
|
||||||
const query = CHAPTER_QUERY;
|
|
||||||
const variables = {id};
|
|
||||||
const data = store.readQuery({
|
|
||||||
query,
|
|
||||||
variables
|
|
||||||
});
|
|
||||||
|
|
||||||
const chapter = data.chapter;
|
|
||||||
|
|
||||||
if (bookmarked) {
|
|
||||||
chapter.bookmark = {
|
|
||||||
__typename: 'ChapterBookmarkNode',
|
|
||||||
note: null
|
|
||||||
};
|
|
||||||
} else {
|
|
||||||
chapter.bookmark = null;
|
|
||||||
}
|
|
||||||
|
|
||||||
data.chapter = chapter;
|
|
||||||
|
|
||||||
store.writeQuery({
|
|
||||||
data,
|
|
||||||
query,
|
|
||||||
variables
|
|
||||||
});
|
|
||||||
},
|
|
||||||
optimisticResponse: {
|
|
||||||
__typename: 'Mutation',
|
|
||||||
updateChapterBookmark: {
|
|
||||||
__typename: 'UpdateChapterBookmarkPayload',
|
|
||||||
success: true
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
});
|
if (this.editModule) {
|
||||||
|
return this.chapter.contentBlocks;
|
||||||
|
}
|
||||||
|
return this.chapter.contentBlocks.filter(contentBlock => !hidden({
|
||||||
|
block: contentBlock,
|
||||||
|
schoolClass: this.schoolClass,
|
||||||
|
type: CONTENT_TYPE,
|
||||||
|
}));
|
||||||
|
},
|
||||||
|
note() {
|
||||||
|
if (this.chapter && this.chapter.bookmark) {
|
||||||
|
return this.chapter.bookmark.note;
|
||||||
|
}
|
||||||
|
},
|
||||||
|
titleGreyedOut() {
|
||||||
|
return this.textHidden(CHAPTER_TITLE_TYPE) && this.editModule;
|
||||||
|
},
|
||||||
|
// never hidden when editing the module
|
||||||
|
titleHidden() {
|
||||||
|
if (this.chapter.titleHidden === true) {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
return this.textHidden(CHAPTER_TITLE_TYPE) && !this.editModule;
|
||||||
|
},
|
||||||
|
descriptionGreyedOut() {
|
||||||
|
return this.textHidden(CHAPTER_DESCRIPTION_TYPE) && this.editModule;
|
||||||
|
},
|
||||||
|
// never hidden when editing the module
|
||||||
|
descriptionHidden() {
|
||||||
|
if (this.chapter.descriptionHidden === true) {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
return this.textHidden(CHAPTER_DESCRIPTION_TYPE) && !this.editModule;
|
||||||
|
},
|
||||||
},
|
},
|
||||||
addNote(id) {
|
|
||||||
this.$store.dispatch('addNote', {
|
|
||||||
content: id,
|
|
||||||
parent: this.chapter.id
|
|
||||||
});
|
|
||||||
},
|
|
||||||
editNote() {
|
|
||||||
this.$store.dispatch('editNote', this.chapter.bookmark.note);
|
|
||||||
},
|
|
||||||
textHidden(type) {
|
|
||||||
return hidden({
|
|
||||||
block: this.chapter,
|
|
||||||
schoolClass: this.schoolClass,
|
|
||||||
type
|
|
||||||
});
|
|
||||||
}
|
|
||||||
},
|
|
||||||
|
|
||||||
};
|
methods: {
|
||||||
|
bookmark(bookmarked) {
|
||||||
|
const id = this.chapter.id;
|
||||||
|
this.$apollo.mutate({
|
||||||
|
mutation: UPDATE_CHAPTER_BOOKMARK_MUTATION,
|
||||||
|
variables: {
|
||||||
|
input: {
|
||||||
|
chapter: id,
|
||||||
|
bookmarked,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
update: (store, response) => {
|
||||||
|
const query = CHAPTER_QUERY;
|
||||||
|
const variables = {id};
|
||||||
|
const data = store.readQuery({
|
||||||
|
query,
|
||||||
|
variables,
|
||||||
|
});
|
||||||
|
|
||||||
|
const chapter = data.chapter;
|
||||||
|
|
||||||
|
if (bookmarked) {
|
||||||
|
chapter.bookmark = {
|
||||||
|
__typename: 'ChapterBookmarkNode',
|
||||||
|
note: null,
|
||||||
|
};
|
||||||
|
} else {
|
||||||
|
chapter.bookmark = null;
|
||||||
|
}
|
||||||
|
|
||||||
|
data.chapter = chapter;
|
||||||
|
|
||||||
|
store.writeQuery({
|
||||||
|
data,
|
||||||
|
query,
|
||||||
|
variables,
|
||||||
|
});
|
||||||
|
},
|
||||||
|
optimisticResponse: {
|
||||||
|
__typename: 'Mutation',
|
||||||
|
updateChapterBookmark: {
|
||||||
|
__typename: 'UpdateChapterBookmarkPayload',
|
||||||
|
success: true,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
});
|
||||||
|
},
|
||||||
|
addNote(id) {
|
||||||
|
this.$store.dispatch('addNote', {
|
||||||
|
content: id,
|
||||||
|
parent: this.chapter.id,
|
||||||
|
});
|
||||||
|
},
|
||||||
|
editNote() {
|
||||||
|
this.$store.dispatch('editNote', this.chapter.bookmark.note);
|
||||||
|
},
|
||||||
|
textHidden(type) {
|
||||||
|
return hidden({
|
||||||
|
block: this.chapter,
|
||||||
|
schoolClass: this.schoolClass,
|
||||||
|
type,
|
||||||
|
});
|
||||||
|
},
|
||||||
|
},
|
||||||
|
|
||||||
|
};
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style scoped lang="scss">
|
<style scoped lang="scss">
|
||||||
@import "@/styles/_mixins.scss";
|
@import "@/styles/_mixins.scss";
|
||||||
|
|
||||||
.chapter {
|
.chapter {
|
||||||
position: relative;
|
|
||||||
|
|
||||||
&__bookmark-actions {
|
|
||||||
margin-top: 3px;
|
|
||||||
}
|
|
||||||
|
|
||||||
&__intro {
|
|
||||||
position: relative;
|
position: relative;
|
||||||
}
|
|
||||||
|
|
||||||
&__description {
|
&__bookmark-actions {
|
||||||
@include lead-paragraph;
|
margin-top: 3px;
|
||||||
|
}
|
||||||
|
|
||||||
margin-bottom: $large-spacing;
|
&__intro {
|
||||||
|
position: relative;
|
||||||
|
}
|
||||||
|
|
||||||
|
&__description {
|
||||||
|
@include lead-paragraph;
|
||||||
|
|
||||||
|
margin-bottom: $large-spacing;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
</style>
|
</style>
|
||||||
|
|
|
||||||
|
|
@ -70,10 +70,14 @@ export const hidden = ({
|
||||||
visibleFor,
|
visibleFor,
|
||||||
hiddenFor,
|
hiddenFor,
|
||||||
titleHiddenFor,
|
titleHiddenFor,
|
||||||
descriptionHiddenFor
|
descriptionHiddenFor,
|
||||||
|
hidden
|
||||||
},
|
},
|
||||||
schoolClass
|
schoolClass
|
||||||
}) => {
|
}) => {
|
||||||
|
if (hidden === true) {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
switch (type) {
|
switch (type) {
|
||||||
case CONTENT_TYPE:
|
case CONTENT_TYPE:
|
||||||
case OBJECTIVE_TYPE:
|
case OBJECTIVE_TYPE:
|
||||||
|
|
|
||||||
|
|
@ -1,9 +1,5 @@
|
||||||
<template>
|
<template>
|
||||||
<div>
|
<module :module="snapshot"/>
|
||||||
Hello
|
|
||||||
{{ id }}
|
|
||||||
<module :module="snapshot" />
|
|
||||||
</div>
|
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
|
|
@ -20,7 +16,7 @@
|
||||||
},
|
},
|
||||||
|
|
||||||
components: {
|
components: {
|
||||||
Module
|
Module,
|
||||||
},
|
},
|
||||||
|
|
||||||
apollo: {
|
apollo: {
|
||||||
|
|
@ -28,9 +24,9 @@
|
||||||
query: SNAPSHOT_DETAIL_QUERY,
|
query: SNAPSHOT_DETAIL_QUERY,
|
||||||
variables() {
|
variables() {
|
||||||
return {
|
return {
|
||||||
id: this.id
|
id: this.id,
|
||||||
};
|
};
|
||||||
}
|
},
|
||||||
},
|
},
|
||||||
|
|
||||||
},
|
},
|
||||||
|
|
|
||||||
|
|
@ -8,3 +8,7 @@ class ContentBlockInterface(relay.Node):
|
||||||
title = graphene.String()
|
title = graphene.String()
|
||||||
contents = GenericStreamFieldType()
|
contents = GenericStreamFieldType()
|
||||||
type = graphene.String()
|
type = graphene.String()
|
||||||
|
|
||||||
|
@staticmethod
|
||||||
|
def resolve_type(parent, info, **kwargs):
|
||||||
|
return parent.type
|
||||||
|
|
|
||||||
|
|
@ -4,7 +4,7 @@ from graphene import relay
|
||||||
|
|
||||||
class ModuleInterface(relay.Node):
|
class ModuleInterface(relay.Node):
|
||||||
pk = graphene.Int()
|
pk = graphene.Int()
|
||||||
hero_image = graphene.String()
|
hero_image = graphene.String(required=True)
|
||||||
topic = graphene.Field('books.schema.nodes.TopicNode')
|
topic = graphene.Field('books.schema.nodes.TopicNode')
|
||||||
|
|
||||||
@staticmethod
|
@staticmethod
|
||||||
|
|
|
||||||
|
|
@ -1,16 +1,14 @@
|
||||||
import graphene
|
import graphene
|
||||||
from graphene import relay, ObjectType
|
|
||||||
from graphene_django import DjangoObjectType
|
from graphene_django import DjangoObjectType
|
||||||
|
|
||||||
from books.models import ContentBlock
|
from books.models import ContentBlock
|
||||||
from books.schema.interfaces.contentblock import ContentBlockInterface
|
from books.schema.interfaces.contentblock import ContentBlockInterface
|
||||||
from books.utils import are_solutions_enabled_for
|
from books.utils import are_solutions_enabled_for
|
||||||
|
from core.logger import get_logger
|
||||||
from notes.models import ContentBlockBookmark
|
from notes.models import ContentBlockBookmark
|
||||||
from notes.schema import ContentBlockBookmarkNode
|
from notes.schema import ContentBlockBookmarkNode
|
||||||
from rooms.models import ModuleRoomSlug
|
from rooms.models import ModuleRoomSlug
|
||||||
|
|
||||||
from core.logger import get_logger
|
|
||||||
|
|
||||||
logger = get_logger(__name__)
|
logger = get_logger(__name__)
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -39,6 +37,8 @@ def is_solution_and_hidden_for_user(type, user, module):
|
||||||
class ContentBlockNode(DjangoObjectType):
|
class ContentBlockNode(DjangoObjectType):
|
||||||
mine = graphene.Boolean()
|
mine = graphene.Boolean()
|
||||||
bookmarks = graphene.List(ContentBlockBookmarkNode)
|
bookmarks = graphene.List(ContentBlockBookmarkNode)
|
||||||
|
hidden_for = graphene.List('users.schema.SchoolClassNode')
|
||||||
|
visible_for = graphene.List('users.schema.SchoolClassNode')
|
||||||
|
|
||||||
class Meta:
|
class Meta:
|
||||||
model = ContentBlock
|
model = ContentBlock
|
||||||
|
|
@ -54,10 +54,6 @@ class ContentBlockNode(DjangoObjectType):
|
||||||
def resolve_mine(parent, info, **kwargs):
|
def resolve_mine(parent, info, **kwargs):
|
||||||
return parent.owner is not None and parent.owner.pk == info.context.user.pk
|
return parent.owner is not None and parent.owner.pk == info.context.user.pk
|
||||||
|
|
||||||
@staticmethod
|
|
||||||
def resolve_type(parent, info, **kwargs):
|
|
||||||
return parent.type
|
|
||||||
|
|
||||||
def resolve_contents(self, info, **kwargs):
|
def resolve_contents(self, info, **kwargs):
|
||||||
updated_stream_data = []
|
updated_stream_data = []
|
||||||
for content in self.contents.stream_data:
|
for content in self.contents.stream_data:
|
||||||
|
|
@ -82,6 +78,11 @@ class ContentBlockNode(DjangoObjectType):
|
||||||
content_block=self
|
content_block=self
|
||||||
)
|
)
|
||||||
|
|
||||||
|
def resolve_hidden_for(parent, info, **kwargs):
|
||||||
|
return parent.hidden_for.all()
|
||||||
|
|
||||||
|
def resolve_visible_for(parent, info, **kwargs):
|
||||||
|
return parent.visible_for.all()
|
||||||
|
|
||||||
|
|
||||||
def process_module_room_slug_block(content):
|
def process_module_room_slug_block(content):
|
||||||
|
|
|
||||||
|
|
@ -24,8 +24,7 @@ class ModuleNode(DjangoObjectType):
|
||||||
'slug': ['exact', 'icontains', 'in'],
|
'slug': ['exact', 'icontains', 'in'],
|
||||||
'title': ['exact', 'icontains', 'in'],
|
'title': ['exact', 'icontains', 'in'],
|
||||||
}
|
}
|
||||||
interfaces = (ModuleInterface, )
|
interfaces = (ModuleInterface,)
|
||||||
|
|
||||||
|
|
||||||
chapters = DjangoFilterConnectionField(ChapterNode)
|
chapters = DjangoFilterConnectionField(ChapterNode)
|
||||||
solutions_enabled = graphene.Boolean()
|
solutions_enabled = graphene.Boolean()
|
||||||
|
|
@ -36,7 +35,6 @@ class ModuleNode(DjangoObjectType):
|
||||||
my_chapter_bookmarks = DjangoFilterConnectionField(ChapterBookmarkNode)
|
my_chapter_bookmarks = DjangoFilterConnectionField(ChapterBookmarkNode)
|
||||||
snapshots = graphene.List('books.schema.nodes.SnapshotNode')
|
snapshots = graphene.List('books.schema.nodes.SnapshotNode')
|
||||||
|
|
||||||
|
|
||||||
def resolve_chapters(self, info, **kwargs):
|
def resolve_chapters(self, info, **kwargs):
|
||||||
return Chapter.get_by_parent(self)
|
return Chapter.get_by_parent(self)
|
||||||
|
|
||||||
|
|
@ -88,6 +86,7 @@ class ModuleNode(DjangoObjectType):
|
||||||
def resolve_snapshots(parent, info, **kwargs):
|
def resolve_snapshots(parent, info, **kwargs):
|
||||||
return parent.snapshots.all()
|
return parent.snapshots.all()
|
||||||
|
|
||||||
|
|
||||||
class RecentModuleNode(DjangoObjectType):
|
class RecentModuleNode(DjangoObjectType):
|
||||||
class Meta:
|
class Meta:
|
||||||
model = RecentModule
|
model = RecentModule
|
||||||
|
|
|
||||||
|
|
@ -17,7 +17,7 @@ class SnapshotContentBlock:
|
||||||
self.id = content_block.id
|
self.id = content_block.id
|
||||||
self.pk = content_block.pk
|
self.pk = content_block.pk
|
||||||
self.title = content_block.title
|
self.title = content_block.title
|
||||||
self.contents = content_block.title
|
self.contents = content_block.contents
|
||||||
self.type = content_block.type
|
self.type = content_block.type
|
||||||
self.hidden = snapshot.hidden_content_blocks.filter(id=content_block.id).exists()
|
self.hidden = snapshot.hidden_content_blocks.filter(id=content_block.id).exists()
|
||||||
|
|
||||||
|
|
@ -61,21 +61,18 @@ class SnapshotChapterNode(ObjectType):
|
||||||
title_hidden = graphene.Boolean()
|
title_hidden = graphene.Boolean()
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
class SnapshotNode(DjangoObjectType):
|
class SnapshotNode(DjangoObjectType):
|
||||||
title = graphene.String()
|
title = graphene.String()
|
||||||
# chapters = graphene.Field(SnapshotChapterNode)
|
|
||||||
snapshot_chapters = DjangoFilterConnectionField(ChapterInSnapshotNode)
|
|
||||||
chapters = graphene.List(SnapshotChapterNode)
|
chapters = graphene.List(SnapshotChapterNode)
|
||||||
|
meta_title = graphene.String()
|
||||||
|
hero_image = graphene.String()
|
||||||
|
|
||||||
class Meta:
|
class Meta:
|
||||||
model = Snapshot
|
model = Snapshot
|
||||||
interfaces = (relay.Node,)
|
interfaces = (relay.Node,)
|
||||||
|
|
||||||
@staticmethod
|
|
||||||
def resolve_snapshot_chapters(parent, info, **kwargs):
|
|
||||||
# return Chapter.objects.filter(chapter_snapshots__snapshot=self)
|
|
||||||
return parent.chapters.through.objects.all()
|
|
||||||
|
|
||||||
@staticmethod
|
@staticmethod
|
||||||
def resolve_chapters(parent, info, **kwargs):
|
def resolve_chapters(parent, info, **kwargs):
|
||||||
return [
|
return [
|
||||||
|
|
@ -85,9 +82,19 @@ class SnapshotNode(DjangoObjectType):
|
||||||
title_hidden=chapter_snapshot.title_hidden,
|
title_hidden=chapter_snapshot.title_hidden,
|
||||||
description_hidden=chapter_snapshot.description_hidden
|
description_hidden=chapter_snapshot.description_hidden
|
||||||
)
|
)
|
||||||
for chapter_snapshot in parent.chapters.through.objects.all()
|
for chapter_snapshot in parent.chapters.through.objects.filter(snapshot=parent)
|
||||||
]
|
]
|
||||||
|
|
||||||
@staticmethod
|
@staticmethod
|
||||||
def resolve_title(parent, info, **kwargs):
|
def resolve_title(parent, info, **kwargs):
|
||||||
return parent.__str__()
|
return parent.__str__()
|
||||||
|
|
||||||
|
@staticmethod
|
||||||
|
def resolve_meta_title(parent, info, **kwargs):
|
||||||
|
return parent.module.meta_title
|
||||||
|
|
||||||
|
@staticmethod
|
||||||
|
def resolve_hero_image(parent, info, **kwargs):
|
||||||
|
if parent.module.hero_image:
|
||||||
|
return parent.module.hero_image.file.url
|
||||||
|
return ''
|
||||||
|
|
|
||||||
|
|
@ -252,7 +252,7 @@ type ChapterNode implements ChapterInterface {
|
||||||
descriptionHiddenFor(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!
|
||||||
id: ID!
|
id: ID!
|
||||||
bookmark: ChapterBookmarkNode
|
bookmark: ChapterBookmarkNode
|
||||||
contentBlocks(offset: Int, before: String, after: String, first: Int, last: Int, slug: String, title: String): ContentBlockNodeConnection
|
contentBlocks: [ContentBlockNode]
|
||||||
}
|
}
|
||||||
|
|
||||||
type ChapterNodeConnection {
|
type ChapterNodeConnection {
|
||||||
|
|
@ -309,8 +309,8 @@ interface ContentBlockInterface {
|
||||||
type ContentBlockNode implements ContentBlockInterface {
|
type ContentBlockNode implements ContentBlockInterface {
|
||||||
title: String
|
title: String
|
||||||
slug: String!
|
slug: String!
|
||||||
hiddenFor(offset: Int, before: String, after: String, first: Int, last: Int, name: String): SchoolClassNodeConnection!
|
hiddenFor: [SchoolClassNode]
|
||||||
visibleFor(offset: Int, before: String, after: String, first: Int, last: Int, name: String): SchoolClassNodeConnection!
|
visibleFor: [SchoolClassNode]
|
||||||
userCreated: Boolean!
|
userCreated: Boolean!
|
||||||
contents: GenericStreamFieldType
|
contents: GenericStreamFieldType
|
||||||
type: String
|
type: String
|
||||||
|
|
@ -659,7 +659,7 @@ type ModuleEdge {
|
||||||
interface ModuleInterface {
|
interface ModuleInterface {
|
||||||
id: ID!
|
id: ID!
|
||||||
pk: Int
|
pk: Int
|
||||||
heroImage: String
|
heroImage: String!
|
||||||
topic: TopicNode
|
topic: TopicNode
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -667,7 +667,7 @@ type ModuleNode implements ModuleInterface {
|
||||||
title: String!
|
title: String!
|
||||||
slug: String!
|
slug: String!
|
||||||
metaTitle: String!
|
metaTitle: String!
|
||||||
heroImage: String
|
heroImage: String!
|
||||||
teaser: String!
|
teaser: String!
|
||||||
intro: String!
|
intro: String!
|
||||||
assignments(offset: Int, before: String, after: String, first: Int, last: Int): AssignmentNodeConnection!
|
assignments(offset: Int, before: String, after: String, first: Int, last: Int): AssignmentNodeConnection!
|
||||||
|
|
@ -929,7 +929,8 @@ type SnapshotNode implements Node {
|
||||||
creator: UserNode
|
creator: UserNode
|
||||||
chapterSnapshots(offset: Int, before: String, after: String, first: Int, last: Int, id: ID): ChapterInSnapshotNodeConnection!
|
chapterSnapshots(offset: Int, before: String, after: String, first: Int, last: Int, id: ID): ChapterInSnapshotNodeConnection!
|
||||||
title: String
|
title: String
|
||||||
snapshotChapters(offset: Int, before: String, after: String, first: Int, last: Int, id: ID): ChapterInSnapshotNodeConnection
|
metaTitle: String
|
||||||
|
heroImage: String
|
||||||
}
|
}
|
||||||
|
|
||||||
input SpellCheckInput {
|
input SpellCheckInput {
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue