Skip to content

Commit 763abd2

Browse files
committed
StudentStats: исправление для 0 лучших решений
1 parent 533ed06 commit 763abd2

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

hwproj.front/src/components/Courses/StudentStats.tsx

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -306,11 +306,13 @@ const StudentStats: React.FC<IStudentStatsProps> = (props) => {
306306
}}
307307
label={testsSum}/>
308308
</TableCell>}
309-
{showBestSolutions && bestSolutionsCount > 0 && <TableCell
309+
{showBestSolutions && <TableCell
310310
align="center"
311311
padding="none"
312312
style={{borderLeft: borderStyle}}>
313-
<Typography variant={"caption"} color={"grey"}>{bestSolutionsCount}</Typography>
313+
{bestSolutionsCount > 0
314+
? <Typography variant={"caption"} color={"grey"}>{bestSolutionsCount}</Typography>
315+
: ""}
314316
</TableCell>}
315317
{homeworks.map((homework, idx) =>
316318
homework.tasks!.map((task, i) => {

0 commit comments

Comments
 (0)