feat: Integrate Data Connect and Implement Staff List View Directory
This commit is contained in:
33
apps/web/dataconnect/connector/task_comment/mutations.gql
Normal file
33
apps/web/dataconnect/connector/task_comment/mutations.gql
Normal file
@@ -0,0 +1,33 @@
|
||||
mutation createTaskComment(
|
||||
$taskId: UUID!
|
||||
$teamMemberId: UUID!
|
||||
$comment: String!
|
||||
$isSystem: Boolean
|
||||
) @auth(level: USER) {
|
||||
taskComment_insert(
|
||||
data: {
|
||||
taskId: $taskId
|
||||
teamMemberId: $teamMemberId
|
||||
comment: $comment
|
||||
isSystem: $isSystem
|
||||
}
|
||||
)
|
||||
}
|
||||
|
||||
mutation updateTaskComment(
|
||||
$id: UUID!
|
||||
$comment: String
|
||||
$isSystem: Boolean
|
||||
) @auth(level: USER) {
|
||||
taskComment_update(
|
||||
id: $id
|
||||
data: {
|
||||
comment: $comment
|
||||
isSystem: $isSystem
|
||||
}
|
||||
)
|
||||
}
|
||||
|
||||
mutation deleteTaskComment($id: UUID!) @auth(level: USER) {
|
||||
taskComment_delete(id: $id)
|
||||
}
|
||||
62
apps/web/dataconnect/connector/task_comment/queries.gql
Normal file
62
apps/web/dataconnect/connector/task_comment/queries.gql
Normal file
@@ -0,0 +1,62 @@
|
||||
query listTaskComments @auth(level: USER) {
|
||||
taskComments {
|
||||
id
|
||||
taskId
|
||||
teamMemberId
|
||||
comment
|
||||
isSystem
|
||||
createdAt
|
||||
|
||||
teamMember{
|
||||
|
||||
user {
|
||||
fullName
|
||||
email
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
query getTaskCommentById($id: UUID!) @auth(level: USER) {
|
||||
taskComment(id: $id) {
|
||||
id
|
||||
taskId
|
||||
teamMemberId
|
||||
comment
|
||||
isSystem
|
||||
createdAt
|
||||
|
||||
teamMember{
|
||||
|
||||
user {
|
||||
fullName
|
||||
email
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
query getTaskCommentsByTaskId($taskId: UUID!) @auth(level: USER) {
|
||||
taskComments(where: { taskId: { eq: $taskId } }) {
|
||||
id
|
||||
taskId
|
||||
teamMemberId
|
||||
comment
|
||||
isSystem
|
||||
createdAt
|
||||
|
||||
teamMember{
|
||||
|
||||
user {
|
||||
fullName
|
||||
email
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user