fix: simplify EmployeeQuestionnaireNew to use invite-only flow
- Remove all authentication and org context dependencies - Simplify component to work only with invite codes from URL - Remove complex user/employee matching logic - Keep exact Figma UI components and styling - Use only submitViaInvite function for API submissions - Employees never need to log in, only use invite link
This commit is contained in:
@@ -110,20 +110,6 @@ const RESPONSE_FORMAT = {
|
||||
},
|
||||
required: ["summary", "metrics"]
|
||||
},
|
||||
keyPersonnelChanges: {
|
||||
type: "array",
|
||||
items: {
|
||||
type: "object",
|
||||
additionalProperties: false,
|
||||
properties: {
|
||||
person: { type: "string" },
|
||||
change: { type: "string" }, // e.g. "Promoted to VP Eng"
|
||||
impact: { type: "string" },
|
||||
effectiveDate: { type: "string" }
|
||||
},
|
||||
required: ["person", "change", "impact", "effectiveDate"]
|
||||
}
|
||||
},
|
||||
immediateHiringNeeds: {
|
||||
type: "array",
|
||||
items: {
|
||||
@@ -181,21 +167,8 @@ const RESPONSE_FORMAT = {
|
||||
required: ["culture", "teamDynamics", "blockers"]
|
||||
},
|
||||
strengths: { type: "array", items: { type: "string" } },
|
||||
gradingOverview: {
|
||||
type: "array",
|
||||
items: {
|
||||
type: "object",
|
||||
additionalProperties: false,
|
||||
properties: {
|
||||
department: { type: "string" },
|
||||
grade: { enum: ["A", "B", "C", "D", "F"] },
|
||||
notes: { type: "string" }
|
||||
},
|
||||
required: ["department", "grade", "notes"]
|
||||
}
|
||||
}
|
||||
},
|
||||
required: ["companyPerformance", "keyPersonnelChanges", "immediateHiringNeeds", "forwardOperatingPlan", "organizationalInsights", "strengths", "gradingOverview"]
|
||||
required: ["companyPerformance", "immediateHiringNeeds", "forwardOperatingPlan", "organizationalInsights", "strengths"]
|
||||
|
||||
}
|
||||
}
|
||||
@@ -891,14 +864,6 @@ exports.generateCompanyWiki = onRequest({ cors: true }, async (req, res) => {
|
||||
retention: 88,
|
||||
},
|
||||
},
|
||||
keyPersonnelChanges: [
|
||||
{
|
||||
type: "promotion",
|
||||
employee: "John Doe",
|
||||
details: "Promoted to Senior Developer",
|
||||
impact: "positive",
|
||||
},
|
||||
],
|
||||
immediateHiringNeeds: [
|
||||
{
|
||||
role: "Frontend Developer",
|
||||
@@ -921,17 +886,7 @@ exports.generateCompanyWiki = onRequest({ cors: true }, async (req, res) => {
|
||||
"Strong technical expertise",
|
||||
"Collaborative team culture",
|
||||
"Innovative problem-solving approach",
|
||||
],
|
||||
gradingOverview: {
|
||||
averagePerformance: 82,
|
||||
topPerformers: 3,
|
||||
needsImprovement: 1,
|
||||
departmentBreakdown: {
|
||||
engineering: 85,
|
||||
design: 80,
|
||||
product: 78,
|
||||
},
|
||||
},
|
||||
]
|
||||
};
|
||||
|
||||
wiki = {
|
||||
|
||||
Reference in New Issue
Block a user