|
|
@ -324,6 +324,7 @@ app.get('/contest/:id/submissions', async (req, res) => { |
|
|
|
if (!isNaN(minScore) || !isNaN(maxScore)) { |
|
|
|
if (!isNaN(minScore) || !isNaN(maxScore)) { |
|
|
|
if (isNaN(minScore)) minScore = 0; |
|
|
|
if (isNaN(minScore)) minScore = 0; |
|
|
|
if (isNaN(maxScore)) maxScore = 100; |
|
|
|
if (isNaN(maxScore)) maxScore = 100; |
|
|
|
|
|
|
|
if (!(minScore === 0 && maxScore === 100)) { |
|
|
|
where.score = { |
|
|
|
where.score = { |
|
|
|
$and: { |
|
|
|
$and: { |
|
|
|
$gte: parseInt(minScore), |
|
|
|
$gte: parseInt(minScore), |
|
|
@ -332,6 +333,7 @@ app.get('/contest/:id/submissions', async (req, res) => { |
|
|
|
}; |
|
|
|
}; |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
if (req.query.language) { |
|
|
|
if (req.query.language) { |
|
|
|
if (req.query.language === 'submit-answer') where.language = ''; |
|
|
|
if (req.query.language === 'submit-answer') where.language = ''; |
|
|
|