Lucas/t 369 on comment drawer i can reply to a comment thread and it (#206)
* Added prisma to suggested extension in container * Added comments and authors on drawer with proper resolving * Fix lint * Fix console log * Fixed generated front graphql from rebase * Fixed right drawer width and shared in theme * Added date packages and tooltip * Added date utils and tests * Added comment thread components * Fixed comment chip * wip * wip 2 * - Added string typing for DateTime scalar - Refactored user in a recoil state and workspace using it - Added comment creation * Prepared EditableCell refactor * Fixed line height and tooltip * Fix lint
This commit is contained in:
31
front/src/modules/comments/services/create.ts
Normal file
31
front/src/modules/comments/services/create.ts
Normal file
@ -0,0 +1,31 @@
|
||||
import { gql } from '@apollo/client';
|
||||
|
||||
export const CREATE_COMMENT = gql`
|
||||
mutation CreateComment(
|
||||
$commentId: String!
|
||||
$commentText: String!
|
||||
$authorId: String!
|
||||
$commentThreadId: String!
|
||||
$createdAt: DateTime!
|
||||
) {
|
||||
createOneComment(
|
||||
data: {
|
||||
id: $commentId
|
||||
createdAt: $createdAt
|
||||
body: $commentText
|
||||
author: { connect: { id: $authorId } }
|
||||
commentThread: { connect: { id: $commentThreadId } }
|
||||
}
|
||||
) {
|
||||
id
|
||||
createdAt
|
||||
body
|
||||
author {
|
||||
id
|
||||
displayName
|
||||
avatarUrl
|
||||
}
|
||||
commentThreadId
|
||||
}
|
||||
}
|
||||
`;
|
||||
Reference in New Issue
Block a user