Get config and display/hide register button
This commit is contained in:
@@ -1,40 +1,10 @@
|
||||
import gql from 'graphql-tag';
|
||||
|
||||
export const CREATE_USER = gql`
|
||||
mutation CreateUser($email: String!, $password: String!) {
|
||||
createUser(email: $email, password: $password) {
|
||||
email,
|
||||
confirmationSentAt
|
||||
}
|
||||
}
|
||||
`;
|
||||
|
||||
export const VALIDATE_USER = gql`
|
||||
mutation ValidateUser($token: String!) {
|
||||
validateUser(token: $token) {
|
||||
token,
|
||||
user {
|
||||
id,
|
||||
email,
|
||||
defaultActor {
|
||||
id
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
`;
|
||||
|
||||
export const CURRENT_USER_CLIENT = gql`
|
||||
export const CONFIG = gql`
|
||||
query {
|
||||
currentUser @client {
|
||||
id,
|
||||
email
|
||||
config {
|
||||
name,
|
||||
registrationsOpen
|
||||
}
|
||||
}
|
||||
`;
|
||||
|
||||
export const UPDATE_CURRENT_USER_CLIENT = gql`
|
||||
mutation UpdateCurrentUser($id: Int!, $email: String!) {
|
||||
updateCurrentUser(id: $id, email: $email) @client
|
||||
}
|
||||
`;
|
||||
|
||||
Reference in New Issue
Block a user