Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions client/src/App.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ import { resourceEntityGuesser } from '@shared/components/crudContainers/EntityG
import attReport from "src/entities/att-report";
import attReportWithReportMonth from './entities/att-report-with-report-month';
import teacherAttReport from 'src/components/TeacherView/taecher-att-report-list';
import LeadTeacherAttReportList from './components/TeacherView/lead-teacher-att-report-list';
import TeacherPercentReportWithDatesList from 'src/components/TeacherView/percent-report-with-dates-list';
import TeacherStudentAttendanceList from 'src/components/TeacherView/student-attendance-list';
import grade from "src/entities/grade";
Expand Down Expand Up @@ -142,6 +143,7 @@ const App = () => (
<Route path="/in-lesson-report-grade/*" element={<TeacherGuard> <InLessonReport gradeMode /> </TeacherGuard>} />
<Route path="/percent-report-with-dates" element={<TeacherPercentReportWithDatesList />} />
<Route path="/student/student-attendance" element={<TeacherStudentAttendanceList />} />
<Route path="/att_report_with_report_month_lead" element={<LeadTeacherAttReportList/>}/>
</CustomRoutes>
</>
);
Expand Down
5 changes: 4 additions & 1 deletion client/src/GeneralLayout.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@ import EditCalendarIcon from '@mui/icons-material/EditCalendar';
import EventAvailableIcon from '@mui/icons-material/EventAvailable';
import PercentIcon from '@mui/icons-material/Percent';
import FileUploadIcon from '@mui/icons-material/FileUpload';
import ViewListIcon from '@mui/icons-material/ViewList';


import BaseLayout from "@shared/components/layout/Layout";
import BaseDashboard from '@shared/components/views/Dashboard';
Expand Down Expand Up @@ -48,7 +50,8 @@ const menuGroups = [
({ permissions }) => !isOnlyInLessonReport(permissions) && ({
name: 'report', icon: <AnalyticsIcon />, routes: [
({ permissions }) => !isTeacherView(permissions) && <MenuItemLink key="student-attendance" to="/student/student-attendance" primaryText="דוח נוכחות (פיבוט)" leftIcon={<SummarizeIcon />} />,
<MenuItemLink key="percent-report-with-dates" to="/percent-report-with-dates" primaryText="דוח אחוזים לתלמידה" leftIcon={<PercentIcon />} />
<MenuItemLink key="percent-report-with-dates" to="/percent-report-with-dates" primaryText="דוח אחוזים לתלמידה" leftIcon={<PercentIcon />} />,
<MenuItemLink key="att_report_with_report_month_lead" to="/att_report_with_report_month_lead" primaryText="דוח נוכחות לרכזת" leftIcon={<ViewListIcon />} />
]
}),
{ name: 'settings', icon: <SettingsIcon /> },
Expand Down
21 changes: 21 additions & 0 deletions client/src/components/TeacherView/lead-teacher-att-report-list.jsx

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

יש לך שגיאת כתיב בשם של הקובץ

Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
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 LeadTeacherAttReportList = (props) => {
const { value: teacher } = useObjectStore("teacher");

const leadTeacherFilter = {
'klass.klassType.teacherReferenceId': teacher?.id,
};

return (
<TeacherGuard>
<BaseList {...props} filter={leadTeacherFilter} />
</TeacherGuard>
);
};

export default LeadTeacherAttReportList;
1 change: 1 addition & 0 deletions client/src/entities/att-report-with-report-month.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,7 @@ export const Datagrid = ({ isAdmin, children, ...props }) => {
}

const entity = {
resource: 'att_report_with_report_month',
Datagrid,
Inputs,
filters,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ function getConfig(): BaseEntityModuleOptions {
teacher: { eager: false },
lesson: { eager: false },
klass: { eager: false },
'klass.klassType': { eager: false },
reportMonth: { eager: false },
reportGroupSession: { eager: false }
}
Expand Down