-
-
Save uno-de-piera/04de7ee33f533671fde555260532998e to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<template> | |
<user-form @createUser="createUser" /> | |
</template> | |
<script> | |
import { API, graphqlOperation } from "aws-amplify"; | |
import { | |
sendEmailToNewUser | |
} from "@/graphql/mutations"; | |
export default { | |
name: "UserForm", | |
methods: { | |
async createUser({ user }) { | |
try { | |
await API.graphql( | |
graphqlOperation(sendEmailToNewUser, { | |
user, | |
subject: "Bienvenido a Cursosdesarrolloweb", | |
message: "Ya eres miembro de la plataforma, disfruta de todo el contenido y no olvides suscribirte!" | |
}) | |
); | |
} catch (e) { | |
} finally { | |
} | |
} | |
} | |
}; | |
</script> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment