diff --git a/webapp/src/Controller/Jury/ProblemController.php b/webapp/src/Controller/Jury/ProblemController.php index e4a8b33e9f..d25cf7f3cf 100644 --- a/webapp/src/Controller/Jury/ProblemController.php +++ b/webapp/src/Controller/Jury/ProblemController.php @@ -212,7 +212,7 @@ public function indexAction(): Response $type .= ' interactive'; } if ($p->isMultipassProblem()) { - $type .= ' multi-pass'; + $type .= ' multi-pass (max passes: ' . $p->getMultipassLimit() . ')'; } $problemdata = array_merge($problemdata, [ 'num_contests' => ['value' => (int)($contestCounts[$p->getProbid()] ?? 0)], @@ -498,7 +498,7 @@ public function viewAction(Request $request, SubmissionService $submissionServic $type .= ' interactive'; } if ($problem->isMultipassProblem()) { - $type .= ' multi-pass'; + $type .= ' multi-pass (max passes: ' . $problem->getMultipassLimit() . ')'; } $data = [ 'problem' => $problem, diff --git a/webapp/src/Form/Type/ProblemType.php b/webapp/src/Form/Type/ProblemType.php index 736d7ec288..96d2f18075 100644 --- a/webapp/src/Form/Type/ProblemType.php +++ b/webapp/src/Form/Type/ProblemType.php @@ -81,6 +81,15 @@ public function buildForm(FormBuilderInterface $builder, array $options): void 'label' => 'Use run script as compare script.', 'required' => false, ]); + $builder->add('multipassProblem', CheckboxType::class, [ + 'label' => 'Multi-pass problem', + 'required' => false, + ]); + $builder->add('multipassLimit', IntegerType::class, [ + 'label' => 'Multi-pass limit', + 'required' => false, + 'help' => 'leave empty for default', + ]); $builder->add('save', SubmitType::class); // Remove clearProblemstatement field when we do not have a problem text.