mirror of
https://github.com/Fayorg/calendrier-avant.git
synced 2026-05-27 17:18:38 +02:00
fix: removed unused database fields & fix prisma errors
This commit is contained in:
@@ -8,10 +8,9 @@ export default async function Dashboard() {
|
||||
console.log(authSession);
|
||||
if (!authSession) return redirect('/');
|
||||
|
||||
const tests = await prisma.test.findMany({ select: { isActive: true, isPassed: true, id: true, testOf: { select: { id: true, firstName: true, lastName: true, isTeacher: true } } } });
|
||||
const tests = await prisma.test.findMany({ select: { isActive: true, id: true, testOf: { select: { id: true, firstName: true, lastName: true, isTeacher: true } } } });
|
||||
|
||||
const activeTests = tests.filter((test) => test.isActive);
|
||||
const passedTests = tests.filter((test) => test.isPassed);
|
||||
|
||||
return (
|
||||
<div>
|
||||
|
||||
@@ -24,12 +24,11 @@ export default function Page({ params }: { params: { id: string } }) {
|
||||
|
||||
useEffect(() => {
|
||||
featchResults(testId);
|
||||
setTimeout(() => {
|
||||
featchResults(testId);
|
||||
}, 5000);
|
||||
}, [testId]);
|
||||
|
||||
setTimeout(() => {
|
||||
featchResults(testId);
|
||||
}, 5000);
|
||||
|
||||
return (
|
||||
<div className={'p-4 md:p-12 w-full h-screen bg-black flex flex-col justify-between gap-y-4'}>
|
||||
<Image src={logo} alt={'Logo'} width={100} height={200} className={'mx-auto w-full md:w-[400px]'} />
|
||||
|
||||
Reference in New Issue
Block a user