feat(contest/submissions): problem title in chooser
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
Baoshuo Ren 2023-02-23 11:25:39 +08:00
parent 571d5cddc3
commit df7d1784d3
Signed by: baoshuo
GPG Key ID: 00CB9680AB29F51A

View File

@ -426,8 +426,11 @@ function echoMySubmissions() {
$options = [];
$options[] = ['value' => 'all', 'text' => '所有题目'];
for ($i = 0; $i < count($problems); $i++) {
$letter = chr(ord('A') + $i);
$options[] = ['value' => $letter, 'text' => "{$letter}"];
$problem = UOJContestProblem::query($problems[$i]);
$options[] = [
'value' => $problem->getLetter(),
'text' => $problem->getTitle(['with' => 'letter', 'simplify' => true]),
];
}
$chosen = UOJRequest::get('p');
@ -455,7 +458,7 @@ function echoMySubmissions() {
'show_all_submissions_status' => Cookie::get('show_all_submissions') !== null,
'options' => $options,
'chosen' => $chosen,
'conds' => $conds
'conds' => $conds,
]);
}