new message entity
This commit is contained in:
39
dataconnect/connector/message/queries.gql
Normal file
39
dataconnect/connector/message/queries.gql
Normal file
@@ -0,0 +1,39 @@
|
||||
query listMessage @auth(level: USER) {
|
||||
messages {
|
||||
id
|
||||
conversationId
|
||||
senderName
|
||||
content
|
||||
readBy
|
||||
}
|
||||
}
|
||||
|
||||
query getMessageById(
|
||||
$id: UUID!
|
||||
) @auth(level: USER) {
|
||||
message(id: $id) {
|
||||
id
|
||||
conversationId
|
||||
senderName
|
||||
content
|
||||
readBy
|
||||
}
|
||||
}
|
||||
|
||||
query filterMessage(
|
||||
$conversationId: UUID,
|
||||
$senderName: String
|
||||
) @auth(level: USER) {
|
||||
messages(
|
||||
where: {
|
||||
conversationId: { eq: $conversationId }
|
||||
senderName: { eq: $senderName }
|
||||
}
|
||||
) {
|
||||
id
|
||||
conversationId
|
||||
senderName
|
||||
content
|
||||
readBy
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user