get-shouts-drafts
This commit is contained in:
parent
dc719120b2
commit
449154bd1b
|
@ -177,7 +177,7 @@ export const apiClient = {
|
||||||
getDrafts: async (): Promise<Shout[]> => {
|
getDrafts: async (): Promise<Shout[]> => {
|
||||||
const response = await apiClient.private.query(draftsLoad, {}).toPromise()
|
const response = await apiClient.private.query(draftsLoad, {}).toPromise()
|
||||||
console.debug('[graphql.client.core] getDrafts:', response)
|
console.debug('[graphql.client.core] getDrafts:', response)
|
||||||
return response.data.load_shouts_drafts
|
return response.data.get_shouts_drafts
|
||||||
},
|
},
|
||||||
createReaction: async (input: ReactionInput) => {
|
createReaction: async (input: ReactionInput) => {
|
||||||
const response = await apiClient.private.mutation(reactionCreate, { reaction: input }).toPromise()
|
const response = await apiClient.private.mutation(reactionCreate, { reaction: input }).toPromise()
|
||||||
|
|
|
@ -2,7 +2,7 @@ import { gql } from '@urql/core'
|
||||||
|
|
||||||
export default gql`
|
export default gql`
|
||||||
query LoadDraftsQuery {
|
query LoadDraftsQuery {
|
||||||
load_shouts_drafts {
|
get_shouts_drafts {
|
||||||
id
|
id
|
||||||
title
|
title
|
||||||
subtitle
|
subtitle
|
||||||
|
@ -23,6 +23,13 @@ export default gql`
|
||||||
followers
|
followers
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
created_by {
|
||||||
|
id
|
||||||
|
name
|
||||||
|
slug
|
||||||
|
pic
|
||||||
|
created_at
|
||||||
|
}
|
||||||
authors {
|
authors {
|
||||||
id
|
id
|
||||||
name
|
name
|
||||||
|
@ -35,7 +42,6 @@ export default gql`
|
||||||
featured_at
|
featured_at
|
||||||
stat {
|
stat {
|
||||||
viewed
|
viewed
|
||||||
|
|
||||||
rating
|
rating
|
||||||
commented
|
commented
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user