diff --git a/components/registro/CapturaDatos.vue b/components/registro/CapturaDatos.vue
index 3e638b7..795d65a 100644
--- a/components/registro/CapturaDatos.vue
+++ b/components/registro/CapturaDatos.vue
@@ -90,7 +90,15 @@
- Inscribir
@@ -106,6 +114,14 @@
import axios from 'axios'
export default {
+ props: {
+ pedirInscripciones: { type: Function, required: true },
+ imprimirMensaje: { type: Function, required: true },
+ imprimirWarning: { type: Function, required: true },
+ imprimirError: { type: Function, required: true },
+ updateIsLoading: { type: Function, required: true },
+ },
+
data() {
const today = new Date()
return {
@@ -130,7 +146,6 @@ export default {
},
methods: {
inscribir() {
- console.log(this.datosUsuario)
const data = {
idUsuario: this.datosUsuario.idUsuario,
folio: this.folio,
@@ -139,15 +154,17 @@ export default {
fechaTicket: this.fechaTicket,
idFechaInscripcion: 1,
}
- console.log(data)
+ this.updateIsLoading(false)
axios
.post(`${process.env.api}/usuario/inscripcionUsuario`, data)
.then((res) => {
- console.log(res)
+ this.updateIsLoading(false)
+ this.imprimirMensaje(res.data.message)
+ this.pedirInscripciones()
})
.catch((err) => {
console.log(err)
- // this.updateIsLoading(false)
+ this.updateIsLoading(false)
// this.imprimirError(err.response.data)
})
// this.mensajeWarning()
@@ -216,15 +233,6 @@ export default {
today.getDate() + mesesCortos[today.getMonth()] - today.getDate()
)
},
- mensajeWarning() {
- this.$buefy.dialog.alert({
- title: 'Terminos y condiciones',
- message:
- 'En caso de que los datos del ticket de pago sean incorrectos, tu inscripcion será cancelada',
- confirmText: 'OK',
- type: 'is-info',
- })
- },
deleteDropFile(index) {
this.dropFiles.splice(index, 1)
},
diff --git a/components/registro/DatosUsuario.vue b/components/registro/DatosUsuario.vue
index 1200293..2f687b2 100644
--- a/components/registro/DatosUsuario.vue
+++ b/components/registro/DatosUsuario.vue
@@ -35,13 +35,16 @@
diff --git a/pages/index.vue b/pages/index.vue
index 34562a8..df0d5e9 100644
--- a/pages/index.vue
+++ b/pages/index.vue
@@ -91,12 +91,6 @@ export default {
// }
// },
},
- created() {
- // this.getLocalhostInfo()
- // if (this.admin.idTipoUsuario === 2) this.$router.push('/responsable')
- // if (this.admin.idTipoUsuario === 3) this.$router.push('/alumno')
- // if (this.admin.idTipoUsuario === 4) this.$router.push('/casoEspecial')
- },
layout: 'login',
}
diff --git a/pages/registro/index.vue b/pages/registro/index.vue
index 3a490c6..6aa14e7 100644
--- a/pages/registro/index.vue
+++ b/pages/registro/index.vue
@@ -34,14 +34,26 @@
Datos del alumno
-
+
Instrucciones
-
+