From 5323cd2c4b5166b370f3ae7b82c71524b94fefa1 Mon Sep 17 00:00:00 2001
From: yaely20 <145603125+yaely20@users.noreply.github.com>
Date: Mon, 5 Jan 2026 17:28:51 +0000
Subject: [PATCH 1/3] filter attendance reports by teacher identity
---
client/src/App.jsx | 4 +++-
client/src/RootDashboard.jsx | 2 +-
.../{ => TeacherView}/TeacherAccess.jsx | 0
.../TeacherView/taecher-att-report-list.jsx | 17 +++++++++++++++++
4 files changed, 21 insertions(+), 2 deletions(-)
rename client/src/components/{ => TeacherView}/TeacherAccess.jsx (100%)
create mode 100644 client/src/components/TeacherView/taecher-att-report-list.jsx
diff --git a/client/src/App.jsx b/client/src/App.jsx
index 34f08c16..8bbc066d 100644
--- a/client/src/App.jsx
+++ b/client/src/App.jsx
@@ -19,10 +19,12 @@ const appTheme = createTheme({
import { Layout } from 'src/GeneralLayout';
import { RootDashboard } from 'src/RootDashboard';
+import { TeacherGuard } from './components/TeacherView/TeacherAccess';
import { resourceEntityGuesser } from '@shared/components/crudContainers/EntityGuesser';
import attReport from "src/entities/att-report";
import attReportWithReportMonth from './entities/att-report-with-report-month';
+import techaeAttReportList from 'src/components/TeacherView/taecher-att-report-list';
import grade from "src/entities/grade";
import klass from "src/entities/klass";
import klassType from "src/entities/klass-type";
@@ -100,7 +102,6 @@ import PermContactCalendarIcon from '@mui/icons-material/PermContactCalendar';
import MonetizationOnIcon from '@mui/icons-material/MonetizationOn';
import LocalAtmIcon from '@mui/icons-material/LocalAtm';
import AdminPanelSettingsIcon from '@mui/icons-material/AdminPanelSettings';
-import { TeacherGuard } from './components/TeacherAccess';
const i18nProvider = getI18nProvider(domainTranslations);
@@ -131,6 +132,7 @@ const App = () => (
<>
+
} />
} />
diff --git a/client/src/RootDashboard.jsx b/client/src/RootDashboard.jsx
index 194425ff..9e7a81bb 100644
--- a/client/src/RootDashboard.jsx
+++ b/client/src/RootDashboard.jsx
@@ -1,7 +1,7 @@
import React from 'react';
import { Dashboard } from 'src/GeneralLayout';
import { useIsTeacherView } from 'src/utils/appPermissions';
-import { TeacherGuard } from 'src/components/TeacherAccess';
+import { TeacherGuard } from 'src/components/TeacherView/TeacherAccess';
export const RootDashboard = (props) => {
const isTeacherView = useIsTeacherView();
diff --git a/client/src/components/TeacherAccess.jsx b/client/src/components/TeacherView/TeacherAccess.jsx
similarity index 100%
rename from client/src/components/TeacherAccess.jsx
rename to client/src/components/TeacherView/TeacherAccess.jsx
diff --git a/client/src/components/TeacherView/taecher-att-report-list.jsx b/client/src/components/TeacherView/taecher-att-report-list.jsx
new file mode 100644
index 00000000..d5073fde
--- /dev/null
+++ b/client/src/components/TeacherView/taecher-att-report-list.jsx
@@ -0,0 +1,17 @@
+import attReport from '../../entities/att-report-with-report-month.jsx';
+import { TeacherGuard } from 'src/components/TeacherView/TeacherAccess.jsx';
+import { useObjectStore } from 'src/utils/storeUtil';
+
+const BaseList = attReport.list;
+
+const techaeAttReportList = (props) => {
+ const { value: teacher } = useObjectStore('teacher');
+ const teacherFilter = {
+ teacherReferenceId: teacher?.tz
+ };
+
+ return ;
+
+
+}
+export default { list: techaeAttReportList };
From 257e7d937e51f5bd903d6cf0fb9ae5b1ce9759c3 Mon Sep 17 00:00:00 2001
From: yaely20 <145603125+yaely20@users.noreply.github.com>
Date: Mon, 5 Jan 2026 20:15:08 +0000
Subject: [PATCH 2/3] change teacherAttReportList
---
client/src/App.jsx | 4 ++--
.../src/components/TeacherView/taecher-att-report-list.jsx | 6 +++---
2 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/client/src/App.jsx b/client/src/App.jsx
index 8bbc066d..96a3b5ca 100644
--- a/client/src/App.jsx
+++ b/client/src/App.jsx
@@ -24,7 +24,7 @@ import { TeacherGuard } from './components/TeacherView/TeacherAccess';
import { resourceEntityGuesser } from '@shared/components/crudContainers/EntityGuesser';
import attReport from "src/entities/att-report";
import attReportWithReportMonth from './entities/att-report-with-report-month';
-import techaeAttReportList from 'src/components/TeacherView/taecher-att-report-list';
+import teacherAttReportList from 'src/components/TeacherView/taecher-att-report-list';
import grade from "src/entities/grade";
import klass from "src/entities/klass";
import klassType from "src/entities/klass-type";
@@ -132,7 +132,7 @@ const App = () => (
<>
-
+
} />
} />
diff --git a/client/src/components/TeacherView/taecher-att-report-list.jsx b/client/src/components/TeacherView/taecher-att-report-list.jsx
index d5073fde..59bf0a30 100644
--- a/client/src/components/TeacherView/taecher-att-report-list.jsx
+++ b/client/src/components/TeacherView/taecher-att-report-list.jsx
@@ -4,14 +4,14 @@ import { useObjectStore } from 'src/utils/storeUtil';
const BaseList = attReport.list;
-const techaeAttReportList = (props) => {
+const teacherAttReportList = (props) => {
const { value: teacher } = useObjectStore('teacher');
const teacherFilter = {
- teacherReferenceId: teacher?.tz
+ teacherReferenceId: teacher.tz
};
return ;
}
-export default { list: techaeAttReportList };
+export default { list: teacherAttReportList };
From 19f3d83d0773059c5af149adce0f6d363801e2ab Mon Sep 17 00:00:00 2001
From: yaely20 <145603125+yaely20@users.noreply.github.com>
Date: Mon, 5 Jan 2026 20:42:09 +0000
Subject: [PATCH 3/3] change teacher?.id
---
client/src/components/TeacherView/taecher-att-report-list.jsx | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/client/src/components/TeacherView/taecher-att-report-list.jsx b/client/src/components/TeacherView/taecher-att-report-list.jsx
index 59bf0a30..bb95adaa 100644
--- a/client/src/components/TeacherView/taecher-att-report-list.jsx
+++ b/client/src/components/TeacherView/taecher-att-report-list.jsx
@@ -7,7 +7,7 @@ const BaseList = attReport.list;
const teacherAttReportList = (props) => {
const { value: teacher } = useObjectStore('teacher');
const teacherFilter = {
- teacherReferenceId: teacher.tz
+ teacherReferenceId: teacher?.id
};
return ;