From a7a6e965979f7c46c2511a33cb601172573f3c84 Mon Sep 17 00:00:00 2001 From: zwlucas Date: Tue, 1 Apr 2025 14:30:52 -0300 Subject: removed cpf --- app/votar/page.tsx | 101 ++++++++++++++++++++++++++--------------------------- 1 file changed, 49 insertions(+), 52 deletions(-) (limited to 'app/votar') diff --git a/app/votar/page.tsx b/app/votar/page.tsx index 5ca0cb4..6d0efdc 100644 --- a/app/votar/page.tsx +++ b/app/votar/page.tsx @@ -16,31 +16,28 @@ export default function VotarPage() { const searchParams = useSearchParams(); const rm = searchParams.get("rm") || ""; const nome = searchParams.get("nome") || ""; - const cpf = searchParams.get("cpf") || ""; const [selectedOption, setSelectedOption] = useState(null); - const [audioElement, setAudioElement] = useState() + const [audioElement, setAudioElement] = useState(); useEffect(() => { - if (!rm || !nome || !cpf) { + if (!rm || !nome) { router.push("/"); return; } - const audio = new Audio('/confirma.mp3') - setAudioElement(audio) - }, [rm, nome, cpf, router]); + const audio = new Audio("/confirma.mp3"); + setAudioElement(audio); + }, [rm, nome, router]); const handleVote = (option: string) => { setSelectedOption(option); if (!audioElement) return; - audioElement.play() + audioElement.play(); setTimeout(() => { router.push( - `/obrigado?rm=${rm}&nome=${encodeURIComponent( - nome - )}&cpf=${cpf}&option=${option}` + `/obrigado?rm=${rm}&nome=${encodeURIComponent(nome)}&option=${option}` ); }, 500); }; @@ -48,53 +45,53 @@ export default function VotarPage() { return (
-
-
-
- JUSTIÇA ELEITORAL ESTUDANTIL +
+
+
+ JUSTIÇA ELEITORAL ESTUDANTIL +
+
+
-
-
-
- - - SEU VOTO PARA - - CHAPA DO GREMIO ESTUDANTIL - - - -
- - -
-
- Toque no quadro correspondente para VOTAR -
-
-
+ + + SEU VOTO PARA + + CHAPA DO GREMIO ESTUDANTIL + + + +
+ + +
+
+ Toque no quadro correspondente para VOTAR +
+
+
-
-
- © {new Date().getFullYear()} Justiça Eleitoral Estudantil +
+
+ © {new Date().getFullYear()} Justiça Eleitoral Estudantil +
-
); } -- cgit v1.2.3