Fix voting gate to use round status, make eval doc uploads toggleable
All checks were successful
Build and Push Docker Image / build (push) Successful in 8m26s
All checks were successful
Build and Push Docker Image / build (push) Successful in 8m26s
Voting check now uses round.status === ROUND_ACTIVE instead of requiring windowOpenAt/windowCloseAt date range, fixing manual open/reopen scenarios. Added requireDocumentUpload toggle (default off) to evaluation round config so rounds reusing prior-round documents don't need file requirements. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -468,16 +468,18 @@ export default function RoundDetailPage() {
|
||||
action: undefined as Route | undefined,
|
||||
actionLabel: undefined as string | undefined,
|
||||
},
|
||||
{
|
||||
label: 'File requirements set',
|
||||
ready: (fileRequirements?.length ?? 0) > 0,
|
||||
detail:
|
||||
(fileRequirements?.length ?? 0) > 0
|
||||
? `${fileRequirements?.length} requirement(s)`
|
||||
: 'No file requirements \u2014 configure in Config tab',
|
||||
action: undefined as Route | undefined,
|
||||
actionLabel: undefined as string | undefined,
|
||||
},
|
||||
...((isEvaluation && !(config.requireDocumentUpload as boolean))
|
||||
? []
|
||||
: [{
|
||||
label: 'File requirements set',
|
||||
ready: (fileRequirements?.length ?? 0) > 0,
|
||||
detail:
|
||||
(fileRequirements?.length ?? 0) > 0
|
||||
? `${fileRequirements?.length} requirement(s)`
|
||||
: 'No file requirements \u2014 configure in Config tab',
|
||||
action: undefined as Route | undefined,
|
||||
actionLabel: undefined as string | undefined,
|
||||
}]),
|
||||
]
|
||||
const readyCount = readinessItems.filter((i) => i.ready).length
|
||||
|
||||
@@ -1738,25 +1740,27 @@ export default function RoundDetailPage() {
|
||||
{/* Evaluation Criteria Editor (EVALUATION rounds only) */}
|
||||
{isEvaluation && <EvaluationCriteriaEditor roundId={roundId} />}
|
||||
|
||||
{/* Document Requirements */}
|
||||
<Card>
|
||||
<CardHeader>
|
||||
<CardTitle className="text-base">Document Requirements</CardTitle>
|
||||
<CardDescription>
|
||||
Files applicants must submit for this round
|
||||
{round.windowCloseAt && (
|
||||
<> — due by {new Date(round.windowCloseAt).toLocaleDateString()}</>
|
||||
)}
|
||||
</CardDescription>
|
||||
</CardHeader>
|
||||
<CardContent>
|
||||
<FileRequirementsEditor
|
||||
roundId={roundId}
|
||||
windowOpenAt={round.windowOpenAt}
|
||||
windowCloseAt={round.windowCloseAt}
|
||||
/>
|
||||
</CardContent>
|
||||
</Card>
|
||||
{/* Document Requirements — hidden for EVALUATION rounds unless requireDocumentUpload is on */}
|
||||
{(!isEvaluation || !!(config.requireDocumentUpload as boolean)) && (
|
||||
<Card>
|
||||
<CardHeader>
|
||||
<CardTitle className="text-base">Document Requirements</CardTitle>
|
||||
<CardDescription>
|
||||
Files applicants must submit for this round
|
||||
{round.windowCloseAt && (
|
||||
<> — due by {new Date(round.windowCloseAt).toLocaleDateString()}</>
|
||||
)}
|
||||
</CardDescription>
|
||||
</CardHeader>
|
||||
<CardContent>
|
||||
<FileRequirementsEditor
|
||||
roundId={roundId}
|
||||
windowOpenAt={round.windowOpenAt}
|
||||
windowCloseAt={round.windowCloseAt}
|
||||
/>
|
||||
</CardContent>
|
||||
</Card>
|
||||
)}
|
||||
</TabsContent>
|
||||
|
||||
{/* ═══════════ AWARDS TAB ═══════════ */}
|
||||
|
||||
Reference in New Issue
Block a user