sdy

update queries

...@@ -14,23 +14,9 @@ export const SUBSCRIPTION_MSG = gql` ...@@ -14,23 +14,9 @@ export const SUBSCRIPTION_MSG = gql`
14 } 14 }
15 `; 15 `;
16 16
17 -export const NEW_MESSAGE = gql` 17 +export const CREATE_MESSAGE = gql`
18 - mutation newMessage($message: String!) { 18 + mutation createMessage($message: String!, $roomId: Int!) {
19 - newMessage(message: $message) { 19 + createMessage(message: $message, roomId: $roomId) {
20 - id
21 - text
22 - sender {
23 - id
24 - username
25 - }
26 - createdAt
27 - }
28 - }
29 -`;
30 -
31 -export const WHOLE_MESSAGE = gql`
32 - mutation wholeMessage($message: String!, $roomId: Int!) {
33 - wholeMessage(message: $message, roomId: $roomId) {
34 id 20 id
35 text 21 text
36 sender { 22 sender {
......