This commit is contained in:
Your Name 2022-08-09 13:35:43 -05:00
parent 6bb11167f1
commit cb720061cf

View File

@ -82,8 +82,11 @@ export default {
}
},
methods: {
login() {
if (this.usuario && this.password && !this.error) {
async login() {
const token = await this.$recaptcha.getResponse()
console.log('ReCaptcha token:', token)
if (this.usuario && this.password && !this.error && !token) {
const data = {
operador: this.usuario,
password: this.password,
@ -172,6 +175,9 @@ export default {
created() {
this.obtenerCatalogoInstitucion()
},
beforeDestroy() {
this.$recaptcha.destroy()
}
}
</script>