Initial commit: MOPC platform with Docker deployment setup
Full Next.js 15 platform with tRPC, Prisma, PostgreSQL, NextAuth. Includes production Dockerfile (multi-stage, port 7600), docker-compose with registry-based image pull, Gitea Actions CI workflow, nginx config for portal.monaco-opc.com, deployment scripts, and DEPLOYMENT.md guide. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
92
src/types/round-settings.ts
Normal file
92
src/types/round-settings.ts
Normal file
@@ -0,0 +1,92 @@
|
||||
/**
|
||||
* Round type-specific settings interfaces
|
||||
*/
|
||||
|
||||
// Filtering round settings (Round 1: High-volume screening)
|
||||
export interface FilteringRoundSettings {
|
||||
// Auto-elimination configuration
|
||||
autoEliminationEnabled: boolean
|
||||
autoEliminationThreshold: number // Minimum average score (e.g., 4)
|
||||
autoEliminationMinReviews: number // Min reviews required before elimination
|
||||
targetAdvancing: number // Target number of projects to advance (e.g., 60)
|
||||
|
||||
// Display options
|
||||
showAverageScore: boolean
|
||||
showRanking: boolean
|
||||
}
|
||||
|
||||
// Evaluation round settings (Round 2: In-depth review)
|
||||
export interface EvaluationRoundSettings {
|
||||
// Requirements
|
||||
detailedCriteriaRequired: boolean
|
||||
minimumFeedbackLength: number // Minimum characters for feedback
|
||||
targetFinalists: number // Target number of finalists (e.g., 6)
|
||||
|
||||
// Display options
|
||||
showAverageScore: boolean
|
||||
showRanking: boolean
|
||||
requireAllCriteria: boolean
|
||||
}
|
||||
|
||||
// Live event round settings (Round 3: Event day)
|
||||
export interface LiveEventRoundSettings {
|
||||
// Presentation
|
||||
presentationDurationMinutes: number
|
||||
presentationOrder: string[] // Project IDs in order
|
||||
|
||||
// Voting
|
||||
votingWindowSeconds: number
|
||||
showLiveScores: boolean
|
||||
allowVoteChange: boolean
|
||||
|
||||
// Display
|
||||
displayMode: 'SCORES' | 'RANKING' | 'NONE'
|
||||
}
|
||||
|
||||
// Union type for all round settings
|
||||
export type RoundSettings =
|
||||
| { type: 'FILTERING'; settings: FilteringRoundSettings }
|
||||
| { type: 'EVALUATION'; settings: EvaluationRoundSettings }
|
||||
| { type: 'LIVE_EVENT'; settings: LiveEventRoundSettings }
|
||||
|
||||
// Default settings for each round type
|
||||
export const defaultFilteringSettings: FilteringRoundSettings = {
|
||||
autoEliminationEnabled: false,
|
||||
autoEliminationThreshold: 4,
|
||||
autoEliminationMinReviews: 3,
|
||||
targetAdvancing: 60,
|
||||
showAverageScore: true,
|
||||
showRanking: true,
|
||||
}
|
||||
|
||||
export const defaultEvaluationSettings: EvaluationRoundSettings = {
|
||||
detailedCriteriaRequired: true,
|
||||
minimumFeedbackLength: 50,
|
||||
targetFinalists: 6,
|
||||
showAverageScore: true,
|
||||
showRanking: true,
|
||||
requireAllCriteria: true,
|
||||
}
|
||||
|
||||
export const defaultLiveEventSettings: LiveEventRoundSettings = {
|
||||
presentationDurationMinutes: 5,
|
||||
presentationOrder: [],
|
||||
votingWindowSeconds: 30,
|
||||
showLiveScores: true,
|
||||
allowVoteChange: false,
|
||||
displayMode: 'RANKING',
|
||||
}
|
||||
|
||||
// Round type labels
|
||||
export const roundTypeLabels: Record<string, string> = {
|
||||
FILTERING: 'Filtering Round',
|
||||
EVALUATION: 'Evaluation Round',
|
||||
LIVE_EVENT: 'Live Event',
|
||||
}
|
||||
|
||||
// Round type descriptions
|
||||
export const roundTypeDescriptions: Record<string, string> = {
|
||||
FILTERING: 'High-volume initial screening with auto-elimination options',
|
||||
EVALUATION: 'In-depth evaluation with detailed criteria and feedback',
|
||||
LIVE_EVENT: 'Real-time voting during presentations',
|
||||
}
|
||||
Reference in New Issue
Block a user