feat: observer team tab, admin-controlled applicant feedback visibility
All checks were successful
Build and Push Docker Image / build (push) Successful in 9m13s
All checks were successful
Build and Push Docker Image / build (push) Successful in 9m13s
- Add Team tab to observer project detail (configurable via admin settings) - Move applicant jury feedback visibility from per-round config to admin settings - Add per-round-type controls: evaluation, live final, deliberation - Support anonymous LiveVote and DeliberationVote display for applicants - Add fine-grained toggles: scores, criteria, written feedback, hide from rejected - Backwards compatible: falls back to old per-round config if admin settings not set - New admin settings section under Analytics tab with all visibility controls - Seed new SystemSettings keys for observer/applicant visibility Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -916,6 +916,27 @@ async function main() {
|
||||
}
|
||||
console.log(` ✓ ${visibilityLinks.length} submission visibility links created`)
|
||||
|
||||
// --- Applicant/Observer visibility settings ---
|
||||
const visibilitySettings = [
|
||||
{ key: 'observer_show_team_tab', value: 'true', type: SettingType.BOOLEAN, category: SettingCategory.ANALYTICS, description: 'Show Team tab on observer project detail page' },
|
||||
{ key: 'applicant_show_evaluation_feedback', value: 'false', type: SettingType.BOOLEAN, category: SettingCategory.ANALYTICS, description: 'Show anonymous jury evaluation feedback to applicants' },
|
||||
{ key: 'applicant_show_evaluation_scores', value: 'false', type: SettingType.BOOLEAN, category: SettingCategory.ANALYTICS, description: 'Show global scores in evaluation feedback' },
|
||||
{ key: 'applicant_show_evaluation_criteria', value: 'false', type: SettingType.BOOLEAN, category: SettingCategory.ANALYTICS, description: 'Show per-criterion scores in evaluation feedback' },
|
||||
{ key: 'applicant_show_evaluation_text', value: 'false', type: SettingType.BOOLEAN, category: SettingCategory.ANALYTICS, description: 'Show written feedback text in evaluation feedback' },
|
||||
{ key: 'applicant_show_livefinal_feedback', value: 'false', type: SettingType.BOOLEAN, category: SettingCategory.ANALYTICS, description: 'Show live final scores to applicants' },
|
||||
{ key: 'applicant_show_livefinal_scores', value: 'false', type: SettingType.BOOLEAN, category: SettingCategory.ANALYTICS, description: 'Show individual jury scores from live finals' },
|
||||
{ key: 'applicant_show_deliberation_feedback', value: 'false', type: SettingType.BOOLEAN, category: SettingCategory.ANALYTICS, description: 'Show deliberation results to applicants' },
|
||||
{ key: 'applicant_hide_feedback_from_rejected', value: 'false', type: SettingType.BOOLEAN, category: SettingCategory.ANALYTICS, description: 'Hide feedback from rejected projects' },
|
||||
]
|
||||
for (const s of visibilitySettings) {
|
||||
await prisma.systemSettings.upsert({
|
||||
where: { key: s.key },
|
||||
update: {},
|
||||
create: s,
|
||||
})
|
||||
}
|
||||
console.log(` ✓ Created ${visibilitySettings.length} applicant/observer visibility settings`)
|
||||
|
||||
// --- Feature flag: enable competition model ---
|
||||
await prisma.systemSettings.upsert({
|
||||
where: { key: 'feature.useCompetitionModel' },
|
||||
|
||||
Reference in New Issue
Block a user