Skip to content

Instantly share code, notes, and snippets.

@parzibyte
Created September 15, 2021 14:44
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save parzibyte/03080185993239146ffeb50eccd90b3c to your computer and use it in GitHub Desktop.
Save parzibyte/03080185993239146ffeb50eccd90b3c to your computer and use it in GitHub Desktop.
data: () => {
const datos = {
reglas: {
tipoEtiqueta: [
(tipoEtiqueta) => {
if (!datos.lista.incluyeForrado) {
return true;
}
if (!tipoEtiqueta) {
return "Ingresa el tipo de etiqueta";
}
return true;
},
],
nombre: [
(nombre) => {
if (!nombre) {
return "Ingresa el nombre";
}
return true;
},
],
grupo: [
(grupo) => {
if (!grupo) {
return "Ingresa el grupo";
}
return true;
},
],
grado: [
(grado) => {
if (!grado) {
return "Ingresa el grado";
}
return true;
},
],
escuela: [
(escuela) => {
if (!escuela) {
return "Ingresa la escuela";
}
return true;
},
],
contacto: [
(contacto) => {
if (!contacto) {
return "Ingresa el contacto";
}
return true;
},
],
},
lista: {
incluyeForrado: false,
tipoEtiqueta: "",
alumno: {
nombre: "",
grado: "",
grupo: "",
escuela: "",
contacto: "",
},
},
};
return datos;
},
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment