fix(contest/manage): add bonus problem

This commit is contained in:
Baoshuo Ren 2023-02-07 20:09:35 +08:00
parent db0651381a
commit eaceefbbbc
Signed by: baoshuo
GPG Key ID: 00CB9680AB29F51A

View File

@ -223,6 +223,12 @@ EOD);
$contest['extra_config']["problem_{$vdata['problem_id']}"] = $judge_type;
}
if ($_POST['bonus']) {
$contest['extra_config']['bonus']["problem_{$vdata['problem_id']}"] = true;
} else {
unset($contest['extra_config']['bonus']["problem_{$vdata['problem_id']}"]);
}
$esc_extra_config = json_encode($contest['extra_config']);
DB::update([
"update contests",