This commit is contained in:
@@ -30,6 +30,14 @@ export const ADMIN_UPDATE_ENV_VARIABLE_MUTATION = `
|
||||
}
|
||||
`
|
||||
|
||||
export const CREATE_TOPIC_MUTATION = `
|
||||
mutation CreateTopic($topic_input: TopicInput!) {
|
||||
create_topic(topic_input: $topic_input) {
|
||||
error
|
||||
}
|
||||
}
|
||||
`
|
||||
|
||||
export const UPDATE_TOPIC_MUTATION = `
|
||||
mutation UpdateTopic($topic_input: TopicInput!) {
|
||||
update_topic(topic_input: $topic_input) {
|
||||
@@ -46,6 +54,14 @@ export const DELETE_TOPIC_MUTATION = `
|
||||
}
|
||||
`
|
||||
|
||||
export const CREATE_COMMUNITY_MUTATION = `
|
||||
mutation CreateCommunity($community_input: CommunityInput!) {
|
||||
create_community(community_input: $community_input) {
|
||||
error
|
||||
}
|
||||
}
|
||||
`
|
||||
|
||||
export const UPDATE_COMMUNITY_MUTATION = `
|
||||
mutation UpdateCommunity($community_input: CommunityInput!) {
|
||||
update_community(community_input: $community_input) {
|
||||
@@ -85,3 +101,30 @@ export const DELETE_COLLECTION_MUTATION = `
|
||||
}
|
||||
}
|
||||
`
|
||||
|
||||
export const ADMIN_CREATE_INVITE_MUTATION = `
|
||||
mutation AdminCreateInvite($invite: AdminInviteUpdateInput!) {
|
||||
adminCreateInvite(invite: $invite) {
|
||||
success
|
||||
error
|
||||
}
|
||||
}
|
||||
`
|
||||
|
||||
export const ADMIN_UPDATE_INVITE_MUTATION = `
|
||||
mutation AdminUpdateInvite($invite: AdminInviteUpdateInput!) {
|
||||
adminUpdateInvite(invite: $invite) {
|
||||
success
|
||||
error
|
||||
}
|
||||
}
|
||||
`
|
||||
|
||||
export const ADMIN_DELETE_INVITE_MUTATION = `
|
||||
mutation AdminDeleteInvite($inviter_id: Int!, $author_id: Int!, $shout_id: Int!) {
|
||||
adminDeleteInvite(inviter_id: $inviter_id, author_id: $author_id, shout_id: $shout_id) {
|
||||
success
|
||||
error
|
||||
}
|
||||
}
|
||||
`
|
||||
|
@@ -17,15 +17,10 @@ export const ADMIN_GET_SHOUTS_QUERY: string =
|
||||
cover
|
||||
cover_caption
|
||||
media {
|
||||
type
|
||||
url
|
||||
title
|
||||
body
|
||||
source
|
||||
pic
|
||||
date
|
||||
genre
|
||||
artist
|
||||
lyrics
|
||||
caption
|
||||
}
|
||||
seo
|
||||
created_at
|
||||
@@ -35,23 +30,45 @@ export const ADMIN_GET_SHOUTS_QUERY: string =
|
||||
deleted_at
|
||||
created_by {
|
||||
id
|
||||
email
|
||||
name
|
||||
email
|
||||
slug
|
||||
}
|
||||
updated_by {
|
||||
id
|
||||
name
|
||||
email
|
||||
slug
|
||||
}
|
||||
deleted_by {
|
||||
id
|
||||
name
|
||||
email
|
||||
slug
|
||||
}
|
||||
community {
|
||||
id
|
||||
name
|
||||
slug
|
||||
}
|
||||
authors {
|
||||
id
|
||||
name
|
||||
email
|
||||
slug
|
||||
}
|
||||
topics {
|
||||
id
|
||||
title
|
||||
slug
|
||||
}
|
||||
version_of
|
||||
draft
|
||||
stat {
|
||||
rating
|
||||
comments_count
|
||||
viewed
|
||||
last_commented_at
|
||||
}
|
||||
}
|
||||
total
|
||||
@@ -115,21 +132,24 @@ export const GET_COMMUNITIES_QUERY: string =
|
||||
gql`
|
||||
query GetCommunities {
|
||||
get_communities_all {
|
||||
id
|
||||
slug
|
||||
name
|
||||
desc
|
||||
pic
|
||||
created_at
|
||||
created_by {
|
||||
communities {
|
||||
id
|
||||
slug
|
||||
name
|
||||
email
|
||||
}
|
||||
stat {
|
||||
shouts
|
||||
followers
|
||||
authors
|
||||
desc
|
||||
pic
|
||||
created_at
|
||||
created_by {
|
||||
id
|
||||
name
|
||||
email
|
||||
slug
|
||||
}
|
||||
stat {
|
||||
shouts
|
||||
followers
|
||||
authors
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -139,17 +159,22 @@ export const GET_TOPICS_QUERY: string =
|
||||
gql`
|
||||
query GetTopics {
|
||||
get_topics_all {
|
||||
id
|
||||
slug
|
||||
title
|
||||
body
|
||||
pic
|
||||
community
|
||||
parent_ids
|
||||
stat {
|
||||
shouts
|
||||
authors
|
||||
followers
|
||||
topics {
|
||||
id
|
||||
slug
|
||||
title
|
||||
body
|
||||
pic
|
||||
community
|
||||
parent_ids
|
||||
stat {
|
||||
shouts
|
||||
followers
|
||||
authors
|
||||
comments
|
||||
}
|
||||
oid
|
||||
is_main
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -159,19 +184,64 @@ export const GET_COLLECTIONS_QUERY: string =
|
||||
gql`
|
||||
query GetCollections {
|
||||
get_collections_all {
|
||||
id
|
||||
slug
|
||||
title
|
||||
desc
|
||||
pic
|
||||
amount
|
||||
created_at
|
||||
published_at
|
||||
created_by {
|
||||
collections {
|
||||
id
|
||||
name
|
||||
email
|
||||
slug
|
||||
title
|
||||
desc
|
||||
pic
|
||||
amount
|
||||
published_at
|
||||
created_at
|
||||
created_by {
|
||||
id
|
||||
name
|
||||
email
|
||||
slug
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
`.loc?.source.body || ''
|
||||
|
||||
export const ADMIN_GET_INVITES_QUERY: string =
|
||||
gql`
|
||||
query AdminGetInvites($limit: Int, $offset: Int, $search: String, $status: String) {
|
||||
adminGetInvites(limit: $limit, offset: $offset, search: $search, status: $status) {
|
||||
invites {
|
||||
inviter_id
|
||||
author_id
|
||||
shout_id
|
||||
status
|
||||
inviter {
|
||||
id
|
||||
name
|
||||
email
|
||||
slug
|
||||
}
|
||||
author {
|
||||
id
|
||||
name
|
||||
email
|
||||
slug
|
||||
}
|
||||
shout {
|
||||
id
|
||||
title
|
||||
slug
|
||||
created_by {
|
||||
id
|
||||
name
|
||||
email
|
||||
slug
|
||||
}
|
||||
}
|
||||
created_at
|
||||
}
|
||||
total
|
||||
page
|
||||
perPage
|
||||
totalPages
|
||||
}
|
||||
}
|
||||
`.loc?.source.body || ''
|
||||
|
Reference in New Issue
Block a user