Skip to content

Commit a6cd6b9

Browse files
committed
add numbering to the teacher and student tables
1 parent a647932 commit a6cd6b9

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

src/client/components/ChatV2/CourseSettingsModal.tsx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -224,13 +224,15 @@ export const CourseSettingsModal = () => {
224224
<Table>
225225
<TableHead>
226226
<TableRow sx={{ backgroundColor: 'grey.100' }}>
227+
<TableCell />
227228
<TableCell sx={{ fontWeight: 'bold' }}>{t('rag:name')}</TableCell>
228229
<TableCell sx={{ fontWeight: 'bold' }}>{t('course:addedFrom')}</TableCell>
229230
</TableRow>
230231
</TableHead>
231232
<TableBody>
232-
{responsibilities.map((responsibility) => (
233+
{responsibilities.map((responsibility, idx) => (
233234
<TableRow>
235+
<TableCell>{idx + 1}</TableCell>
234236
<TableCell key={responsibility.id}>
235237
<Typography>
236238
{responsibility.user.last_name} {responsibility.user.first_names}

src/client/components/Courses/Course/Stats.tsx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,7 @@ const Stats: React.FC = () => {
6464
<Table sx={{ mt: 2 }}>
6565
<TableHead sx={{ borderRadius: 1, backgroundColor: 'grey.100' }}>
6666
<TableRow>
67+
<TableCell />
6768
<TableCell>
6869
<strong>{t('admin:studentNumber')}</strong>
6970
</TableCell>
@@ -141,8 +142,9 @@ const Stats: React.FC = () => {
141142
</TableRow>
142143
</TableHead>
143144
<TableBody>
144-
{sortedUsers.map((enrolled) => (
145+
{sortedUsers.map((enrolled, idx) => (
145146
<TableRow key={enrolled.id}>
147+
<TableCell>{idx + 1}</TableCell>
146148
<TableCell>{enrolled.student_number}</TableCell>
147149
<TableCell>{enrolled.last_name}</TableCell>
148150
<TableCell>{enrolled.first_names}</TableCell>

0 commit comments

Comments
 (0)