Отображение групп

This commit is contained in:
Никита Потапов 2024-01-11 16:45:32 +04:00
parent ba30230395
commit 1aea56c499

View File

@ -1,11 +1,30 @@
import { Container } from "react-bootstrap";
import { useGroups } from "../../hooks/GroupHook";
import { useOnlyTeachers } from "../../hooks/UserHooks";
import GroupTableRow from "../../components/grouptablerow/grouptablerow";
Container
const GroupsPage = () => {
useOnlyTeachers();
const { groups, handleGroupsChange } = useGroups();
return (
<>
<h5>GroupsPage</h5>
<Container>
<table className="table">
<thead>
<tr>
<th scope="col">ID</th>
<th scope="col">Название</th>
</tr>
</thead>
<tbody>
{
groups.map((group, index) => <GroupTableRow key={index} group={group} />)
}
</tbody>
</table>
</Container>
</>
);
};