mirror of
https://gitcode.com/gh_mirrors/hy/Hydro.git
synced 2026-10-17 17:36:08 +08:00
ui: judge_config: fix extra_files config (#355)
This commit is contained in:
1 parent
a9a7b3a451
commit
b5e312b609
5 files changed
+30
-9
No files matched your search
@@ -163,12 +163,22 @@ function GlobalTaskConfig() {
|
||||
|
||||
export function TaskConfig() {
|
||||
const len = useSelector((state: RootState) => state.config.subtasks?.length);
|
||||
const dispatch = useDispatch();
|
||||
return (
|
||||
<FormItem columns={12} label="Task Settings">
|
||||
<div className="row">
|
||||
<GlobalTaskConfig />
|
||||
<FormItem columns={12} label="TestCases" disableLabel>
|
||||
{len && [...Array(len).keys()].map((i) => <SubtasksTable index={i} key={i} />)}
|
||||
{len > 0
|
||||
? [...Array(len).keys()].map((i) => <SubtasksTable index={i} key={i} />)
|
||||
: (
|
||||
<>
|
||||
<span>Subtasks # </span>
|
||||
<a onClick={() => dispatch({ type: 'CONFIG_SUBTASK_UPDATE', id: 0, key: 'add' })}>
|
||||
<span className="icon icon-add"></span>
|
||||
</a>
|
||||
</>
|
||||
)}
|
||||
</FormItem>
|
||||
</div>
|
||||
</FormItem>
|
||||
|
||||
Reference in new issue
Block a user