Toggle navigation
Toggle navigation
This project
Loading...
Sign in
2020-1-capstone-design1
/
Triz_Project1
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
1
Merge Requests
0
Wiki
Snippets
Network
Create a new issue
Builds
Commits
Issue Boards
Authored by
sdy
2020-05-25 00:35:43 +0900
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
27fb10563cfc81da253d1a6cd16dd8501111895d
27fb1056
1 parent
5791f7eb
create GET_ROOM_BY_NAME query
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
23 additions
and
1 deletions
front/src/Routes/Chat/ChatQueries.js
front/src/Routes/Chat/ChatQueries.js
View file @
27fb105
...
...
@@ -15,7 +15,7 @@ export const SUBSCRIPTION_MSG = gql`
`
;
export
const
NEW_MESSAGE
=
gql
`
mutation newMessage($message: String) {
mutation newMessage($message: String
!
) {
newMessage(message: $message) {
id
text
...
...
@@ -27,3 +27,25 @@ export const NEW_MESSAGE = gql`
}
}
`
;
export
const
WHOLE_MESSAGE
=
gql
`
mutation wholeMessage($message: String!, $roomId: Int!) {
wholeMessage(message: $message, roomId: $roomId) {
id
text
sender {
id
username
}
createdAt
}
}
`
;
export
const
GET_ROOM_BY_NAME
=
gql
`
query getRoomByName($roomName: String!) {
getRoomByName(roomName: $roomName) {
id
}
}
`
;
...
...
Please
register
or
login
to post a comment