mirror of
https://gitcode.com/gh_mirrors/hy/Hydro.git
synced 2026-10-17 09:36:08 +08:00
ui: fix array was checked for single select option (#823)
This commit is contained in:
1 parent
d802a81a45
commit
1c8a6ee9ab
1 file changed
+3
-2
@@ -261,9 +261,10 @@ const page = new NamedPage(['problem_detail', 'contest_detail_problem', 'homewor
|
||||
for (const v of val) {
|
||||
if (isValidOption(v)) $(`.objective_${id} input[value="${v}"]`).prop('checked', true);
|
||||
}
|
||||
} else {
|
||||
$(`.objective_${id} input[type=text], .objective_${id} textarea`).val(val);
|
||||
if (isValidOption(val)) $(`.objective_${id}.radiobox [value="${val}"]`).prop('checked', true);
|
||||
}
|
||||
$(`.objective_${id} input[type=text], .objective_${id} textarea`).val(val);
|
||||
if (isValidOption(val)) $(`.objective_${id}.radiobox [value="${val}"]`).prop('checked', true);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user