Draft: Resolve "feat: Implement Team-Based Standup Upload Propagation"
Closes #14 (closed)
MR: Propagate Standup Upload Status to Teammates
Description
This Merge Request implements the "One-for-All" upload logic. It ensures that a valid standup upload by any team member propagates the "Uploaded" status to all other members within the same team.
Key Technical Changes
-
Logic Layer (
DashboardLayout.tsx):- Introduced a
teamUploadMapusinguseMemoto aggregate upload statuses byteamId. - Updated
handleVerifyTeamto reference this map, ensuring the verification check passes for the whole team if a single valid entry exists.
- Introduced a
-
Component Layer (
InternCard.tsx):- Modified the status conditional:
const isUploaded = individualStatus || teamPropagatedStatus;.
- Modified the status conditional:
-
UI Layer (
TeamList.tsx):- Adjusted the team-level summary logic to count members based on the new propagated status, ensuring the progress reflects 100% once the team threshold is met.
Testing & QA Steps
- Mock Data Test: Assign 3 interns to "Team Alpha."
- Action: Perform a "Valid Upload" for only one intern.
-
Verify: - Check that the
InternCardfor the other two interns displays the green "Uploaded" badge.- Check that the
TeamListheader shows "3/3 Uploaded."
- Check that the
-
Regression: Verify that interns without a
teamId(individual contributors) still function on an individual-only basis.
Checklist
-
Logic handles cases where teamIdmight be null or undefined. -
No unnecessary re-renders introduced in the DashboardLayoutloop. -
UI reflects changes in real-time (or upon state update). -
Documentation updated in the codebase.