diff --git a/backend/src/schema/types/schema.gql b/backend/src/schema/types/schema.gql index b043a5c27..8b0f422c8 100644 --- a/backend/src/schema/types/schema.gql +++ b/backend/src/schema/types/schema.gql @@ -40,42 +40,6 @@ type Mutation { follow(id: ID!, type: FollowTypeEnum): Boolean! # Unfollow the given Type and ID unfollow(id: ID!, type: FollowTypeEnum): Boolean! - CreatePost( - id: ID - activityId: String - objectId: String - title: String! - slug: String - content: String! - image: String - imageUpload: Upload - visibility: Visibility - deleted: Boolean - disabled: Boolean - createdAt: String - updatedAt: String - language: String - categoryIds: [ID] - contentExcerpt: String - ): Post - UpdatePost( - id: ID! - activityId: String - objectId: String - title: String! - slug: String - content: String! - contentExcerpt: String - image: String - imageUpload: Upload - visibility: Visibility - deleted: Boolean - disabled: Boolean - createdAt: String - updatedAt: String - language: String - categoryIds: [ID] - ): Post DeleteUser(id: ID!, resource: [Deletable]): User } diff --git a/backend/src/schema/types/type/Comment.gql b/backend/src/schema/types/type/Comment.gql index e11623453..441fba179 100644 --- a/backend/src/schema/types/type/Comment.gql +++ b/backend/src/schema/types/type/Comment.gql @@ -20,6 +20,7 @@ type Mutation { contentExcerpt: String deleted: Boolean disabled: Boolean + createdAt: String ): Comment UpdateComment( id: ID! @@ -28,7 +29,5 @@ type Mutation { deleted: Boolean disabled: Boolean ): Comment - DeleteComment( - id: ID! - ): Comment + DeleteComment(id: ID!): Comment } diff --git a/backend/src/schema/types/type/Post.gql b/backend/src/schema/types/type/Post.gql index 271d92750..deb1d8f85 100644 --- a/backend/src/schema/types/type/Post.gql +++ b/backend/src/schema/types/type/Post.gql @@ -49,3 +49,42 @@ type Post { """ ) } + +type Mutation { + CreatePost( + id: ID + activityId: String + objectId: String + title: String! + slug: String + content: String! + image: String + imageUpload: Upload + visibility: Visibility + deleted: Boolean + disabled: Boolean + createdAt: String + updatedAt: String + language: String + categoryIds: [ID] + contentExcerpt: String + ): Post + UpdatePost( + id: ID! + activityId: String + objectId: String + title: String! + slug: String + content: String! + contentExcerpt: String + image: String + imageUpload: Upload + visibility: Visibility + deleted: Boolean + disabled: Boolean + createdAt: String + updatedAt: String + language: String + categoryIds: [ID] + ): Post +} diff --git a/webapp/components/ContributionForm/ContributionForm.spec.js b/webapp/components/ContributionForm/ContributionForm.spec.js index 2b47c5a06..0813d16f0 100644 --- a/webapp/components/ContributionForm/ContributionForm.spec.js +++ b/webapp/components/ContributionForm/ContributionForm.spec.js @@ -243,7 +243,7 @@ describe('ContributionForm.vue', () => { expect(mocks.$apollo.mutate).toHaveBeenCalledWith(expect.objectContaining(expectedParams)) }) - it('supports updateing categories', async () => { + it('supports updating categories', async () => { const categoryIds = ['cat3', 'cat51', 'cat37'] postTitleInput = wrapper.find('.ds-input') postTitleInput.setValue(postTitle)