mirror of
https://github.com/Ocelot-Social-Community/Ocelot-Social.git
synced 2025-12-13 07:46:06 +00:00
Terms and conditions are handed over cleanly during registration
This commit is contained in:
parent
53532025d6
commit
877b0ea77e
@ -87,10 +87,24 @@ import gql from 'graphql-tag'
|
|||||||
import PasswordStrength from '../Password/Strength'
|
import PasswordStrength from '../Password/Strength'
|
||||||
import { SweetalertIcon } from 'vue-sweetalert-icons'
|
import { SweetalertIcon } from 'vue-sweetalert-icons'
|
||||||
import PasswordForm from '~/components/utils/PasswordFormHelper'
|
import PasswordForm from '~/components/utils/PasswordFormHelper'
|
||||||
|
import { VERSION } from '~/pages/terms-and-conditions'
|
||||||
|
|
||||||
/* TODO: hier muss die version rein */
|
/* TODO: hier muss die version rein */
|
||||||
export const SignupVerificationMutation = gql`
|
export const SignupVerificationMutation = gql`
|
||||||
mutation($nonce: String!, $name: String!, $email: String!, $password: String!) {
|
mutation(
|
||||||
SignupVerification(nonce: $nonce, email: $email, name: $name, password: $password) {
|
$nonce: String!
|
||||||
|
$name: String!
|
||||||
|
$email: String!
|
||||||
|
$password: String!
|
||||||
|
$termsAndConditionsAgreedVersion: String!
|
||||||
|
) {
|
||||||
|
SignupVerification(
|
||||||
|
nonce: $nonce
|
||||||
|
email: $email
|
||||||
|
name: $name
|
||||||
|
password: $password
|
||||||
|
termsAndConditionsAgreedVersion: $termsAndConditionsAgreedVersion
|
||||||
|
) {
|
||||||
id
|
id
|
||||||
name
|
name
|
||||||
slug
|
slug
|
||||||
@ -139,10 +153,11 @@ export default {
|
|||||||
async submit() {
|
async submit() {
|
||||||
const { name, password, about } = this.formData
|
const { name, password, about } = this.formData
|
||||||
const { email, nonce } = this
|
const { email, nonce } = this
|
||||||
|
const termsAndConditionsAgreedVersion = VERSION
|
||||||
try {
|
try {
|
||||||
await this.$apollo.mutate({
|
await this.$apollo.mutate({
|
||||||
mutation: SignupVerificationMutation,
|
mutation: SignupVerificationMutation,
|
||||||
variables: { name, password, about, email, nonce },
|
variables: { name, password, about, email, nonce, termsAndConditionsAgreedVersion },
|
||||||
})
|
})
|
||||||
this.success = true
|
this.success = true
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user