feat: ability to assign people to round robin from org members
What does this PR do?
Fixes #14190
https://github.com/calcom/cal.com/assets/74371312/84a92e94-cfa7-4e7f-b4c3-3cbb10a598fd
Type of change
- New feature (non-breaking change which adds functionality)
Mandatory Tasks
- [x] Make sure you have self-reviewed the code. A decent size PR without self-review might be rejected.
@Amit91848 is attempting to deploy a commit to the cal Team on Vercel.
A member of the Team first needs to authorize it.
Thank you for following the naming conventions! 🙏 Feel free to join our discord and post your PR link.
Graphite Automations
"Add consumer team as reviewer" took an action on this PR • (03/25/24)
1 reviewer was added to this PR based on Keith Williams's automation.
"Add community label" took an action on this PR • (03/25/24)
1 label was added to this PR based on Keith Williams's automation.
"Add foundation team as reviewer" took an action on this PR • (05/21/24)
1 reviewer was added to this PR based on Keith Williams's automation.
📦 Next.js Bundle Analysis for @calcom/web
This analysis was generated by the Next.js Bundle Analysis action. 🤖
Eighty-two Pages Changed Size
The following pages changed size from the code in this PR compared to its base branch:
| Page | Size (compressed) | First Load | % of Budget (350 KB) |
|---|---|---|---|
/[user]/[type] |
412.1 KB |
640.68 KB | 183.05% (🟢 -0.28%) |
/[user]/[type]/embed |
412.1 KB |
640.68 KB | 183.05% (🟢 -0.28%) |
/apps |
279.06 KB |
507.64 KB | 145.04% (🟢 -0.58%) |
/apps/[slug] |
296.56 KB |
525.14 KB | 150.04% (🟢 -0.58%) |
/apps/[slug]/[...pages] |
587.53 KB |
816.12 KB | 233.18% (🟢 -0.60%) |
/apps/categories |
256.79 KB |
485.37 KB | 138.68% (🟢 -0.59%) |
/apps/categories/[category] |
261.13 KB |
489.72 KB | 139.92% (🟢 -0.58%) |
/apps/installed/[category] |
280.33 KB |
508.91 KB | 145.40% (🟢 -0.58%) |
/auth/platform/authorize |
87.24 KB |
315.82 KB | 90.23% (🟢 -0.26%) |
/availability |
427.78 KB |
656.36 KB | 187.53% (🟢 -0.59%) |
/availability/[schedule] |
411.51 KB |
640.09 KB | 182.88% (🟢 -0.59%) |
/bookings/[status] |
324.61 KB |
553.19 KB | 158.05% (🟢 -0.58%) |
/d/[link]/[slug] |
411.91 KB |
640.49 KB | 183.00% (🟢 -0.28%) |
/enterprise |
256.85 KB |
485.43 KB | 138.69% (🟢 -0.58%) |
/event-types |
556.52 KB |
785.11 KB | 224.32% (🟢 -0.60%) |
/event-types/[type] |
436.42 KB |
665 KB | 190.00% (🟢 -0.59%) |
/insights |
475.75 KB |
704.34 KB | 201.24% (🟢 -0.58%) |
/more |
256.35 KB |
484.94 KB | 138.55% (🟢 -0.58%) |
/org/[orgSlug]/[user]/[type] |
412.3 KB |
640.88 KB | 183.11% (🟢 -0.28%) |
/org/[orgSlug]/[user]/[type]/embed |
412.32 KB |
640.91 KB | 183.12% (🟢 -0.28%) |
/org/[orgSlug]/instant-meeting/team/[slug]/[type] |
411.93 KB |
640.51 KB | 183.00% (🟢 -0.28%) |
/org/[orgSlug]/team/[slug]/[type] |
412.12 KB |
640.7 KB | 183.06% (🟢 -0.28%) |
/settings/admin |
262.45 KB |
491.03 KB | 140.29% (🟢 -0.58%) |
/settings/admin/apps |
275.58 KB |
504.16 KB | 144.05% (🟢 -0.59%) |
/settings/admin/apps/[category] |
275.56 KB |
504.15 KB | 144.04% (🟢 -0.58%) |
/settings/admin/flags |
266.56 KB |
495.14 KB | 141.47% (🟢 -0.58%) |
/settings/admin/impersonation |
262.93 KB |
491.51 KB | 140.43% (🟢 -0.58%) |
/settings/admin/lockedSMS |
283.61 KB |
512.19 KB | 146.34% (🟢 -0.59%) |
/settings/admin/oAuth |
274.61 KB |
503.19 KB | 143.77% (🟢 -0.58%) |
/settings/admin/orgMigrations/_OrgMigrationLayout |
251.36 KB |
479.94 KB | 137.13% (🟢 -0.59%) |
/settings/admin/orgMigrations/moveTeamToOrg |
300.52 KB |
529.1 KB | 151.17% (🟢 -0.58%) |
/settings/admin/orgMigrations/moveUserToOrg |
319.92 KB |
548.5 KB | 156.72% (🟢 -0.60%) |
/settings/admin/orgMigrations/removeTeamFromOrg |
300.26 KB |
528.84 KB | 151.10% (🟢 -0.58%) |
/settings/admin/orgMigrations/removeUserFromOrg |
300.27 KB |
528.86 KB | 151.10% (🟢 -0.58%) |
/settings/admin/organizations |
264.02 KB |
492.6 KB | 140.74% (🟢 -0.58%) |
/settings/admin/organizations/[id]/edit |
262.83 KB |
491.41 KB | 140.40% (🟢 -0.58%) |
/settings/admin/users |
264.69 KB |
493.28 KB | 140.94% (🟢 -0.59%) |
/settings/admin/users/[id]/edit |
393.37 KB |
621.96 KB | 177.70% (🟢 -0.58%) |
/settings/admin/users/add |
393.1 KB |
621.69 KB | 177.62% (🟢 -0.58%) |
/settings/billing |
262.55 KB |
491.13 KB | 140.32% (🟢 -0.58%) |
/settings/developer/api-keys |
266.61 KB |
495.19 KB | 141.48% (🟢 -0.58%) |
/settings/developer/webhooks |
266.7 KB |
495.28 KB | 141.51% (🟢 -0.58%) |
/settings/developer/webhooks/[id] |
267.7 KB |
496.28 KB | 141.79% (🟢 -0.58%) |
/settings/developer/webhooks/new |
267.7 KB |
496.28 KB | 141.79% (🟢 -0.58%) |
/settings/my-account/appearance |
315.41 KB |
543.99 KB | 155.43% (🟢 -0.59%) |
/settings/my-account/calendars |
273.13 KB |
501.71 KB | 143.35% (🟢 -0.59%) |
/settings/my-account/conferencing |
274.4 KB |
502.98 KB | 143.71% (🟢 -0.58%) |
/settings/my-account/general |
378.33 KB |
606.91 KB | 173.40% (🟢 -0.58%) |
/settings/my-account/out-of-office |
267.23 KB |
495.81 KB | 141.66% (🟢 -0.58%) |
/settings/my-account/profile |
405.87 KB |
634.45 KB | 181.27% (🟢 -0.58%) |
/settings/organizations/admin-api |
262.45 KB |
491.04 KB | 140.30% (🟢 -0.59%) |
/settings/organizations/appearance |
286.51 KB |
515.09 KB | 147.17% (🟢 -0.58%) |
/settings/organizations/billing |
262.63 KB |
491.22 KB | 140.35% (🟢 -0.59%) |
/settings/organizations/dsync |
294.73 KB |
523.32 KB | 149.52% (🟢 -0.58%) |
/settings/organizations/general |
350.3 KB |
578.88 KB | 165.40% (🟢 -0.59%) |
/settings/organizations/members |
401.33 KB |
629.92 KB | 179.98% (🟢 -0.23%) |
/settings/organizations/privacy |
268.22 KB |
496.8 KB | 141.94% (🟢 -0.58%) |
/settings/organizations/profile |
398.63 KB |
627.21 KB | 179.20% (🟢 -0.58%) |
/settings/organizations/sso |
273.3 KB |
501.88 KB | 143.39% (🟢 -0.58%) |
/settings/organizations/teams/other |
263.2 KB |
491.79 KB | 140.51% (🟢 -0.58%) |
/settings/organizations/teams/other/[id]/appearance |
275.34 KB |
503.93 KB | 143.98% (🟢 -0.58%) |
/settings/organizations/teams/other/[id]/members |
270.29 KB |
498.88 KB | 142.54% (🟢 -0.59%) |
/settings/organizations/teams/other/[id]/profile |
469.44 KB |
698.02 KB | 199.43% (🟢 -0.58%) |
/settings/platform |
261.74 KB |
490.32 KB | 140.09% (🟢 -0.34%) |
/settings/platform/oauth-clients/[clientId]/edit |
260.35 KB |
488.93 KB | 139.69% (🟢 -0.36%) |
/settings/platform/oauth-clients/create |
259.64 KB |
488.22 KB | 139.49% (🟢 -0.32%) |
/settings/security/impersonation |
267.46 KB |
496.04 KB | 141.73% (🟢 -0.59%) |
/settings/security/password |
305.02 KB |
533.6 KB | 152.46% (🟢 -0.58%) |
/settings/security/sso |
272.62 KB |
501.21 KB | 143.20% (🟢 -0.58%) |
/settings/security/two-factor-auth |
270.89 KB |
499.47 KB | 142.71% (🟢 -0.59%) |
/settings/teams |
262.12 KB |
490.7 KB | 140.20% (🟢 -0.58%) |
/settings/teams/[id]/appearance |
275.33 KB |
503.91 KB | 143.98% (🟢 -0.59%) |
/settings/teams/[id]/billing |
262.63 KB |
491.21 KB | 140.35% (🟢 -0.59%) |
/settings/teams/[id]/members |
380.34 KB |
608.92 KB | 173.98% (🟢 -0.58%) |
/settings/teams/[id]/profile |
470.28 KB |
698.86 KB | 199.67% (🟢 -0.58%) |
/team/[slug]/[type] |
412.09 KB |
640.67 KB | 183.05% (🟢 -0.28%) |
/team/[slug]/[type]/embed |
412.12 KB |
640.7 KB | 183.06% (🟢 -0.28%) |
/teams |
256.58 KB |
485.16 KB | 138.62% (🟢 -0.59%) |
/upgrade |
256.7 KB |
485.28 KB | 138.65% (🟢 -0.58%) |
/video/[uid] |
295.84 KB |
524.42 KB | 149.83% (🟡 +1.37%) |
/workflows |
288.05 KB |
516.63 KB | 147.61% (🟢 -0.59%) |
/workflows/[workflow] |
410.47 KB |
639.05 KB | 182.59% (🟢 -0.74%) |
Details
Only the gzipped size is provided here based on an expert tip.
First Load is the size of the global bundle plus the bundle for the individual page. If a user were to show up to your website and land on a given page, the first load size represents the amount of javascript that user would need to download. If next/link is used, subsequent page loads would only need to download that page's bundle (the number in the "Size" column), since the global bundle has already been downloaded.
Any third party scripts you have added directly to your app using the <script> tag are not accounted for in this analysis
The "Budget %" column shows what percentage of your performance budget the First Load total takes up. For example, if your budget was 100kb, and a given page's first load size was 10kb, it would be 10% of your budget. You can also see how much this has increased or decreased compared to the base branch of your PR. If this percentage has increased by 20% or more, there will be a red status indicator applied, indicating that special attention should be given to this. If you see "+/-
This PR is being marked as stale due to inactivity.
Also, I would change the icon of "Add to event type":
I think it makes sense to have same icon as "Event types" at the main page of dashboard sidebar since both refer to event type:
Good work Amit! Requested some changes. Let me know what you think! : )
Thanks for the review. Will look into it.
Do you think you can adjust this - if a user is part of the event-type, then have it checked after clicking "Add to event type": Fair enough, just wanted to confirm a few things.
Suppose the events where user is a host is checked, does clicking on them uncheck them, will anything happen on checking them? Or should we just disable those?
Understandably if multiple users are selected only check those where all the users are a part of.
Do you think you can adjust this - if a user is part of the event-type, then have it checked after clicking "Add to event type":
Added this. Currently clicking the boxes does nothing.
cc @sean-brydon the same happens when clicking "Add to team" - even though the user is already part of the team, the checkboxes are unchecked.
Since it hardly required any changes, fixed it for teams here itself.
https://github.com/calcom/cal.com/assets/74371312/bb1b5301-f457-431e-8738-993bb1eaeaa5
Do you think you can adjust this - if a user is part of the event-type, then have it checked after clicking "Add to event type": Fair enough, just wanted to confirm a few things.
Suppose the events where user is a host is checked, does clicking on them uncheck them, will anything happen on checking them? Or should we just disable those?
Understandably if multiple users are selected only check those where all the users are a part of.
I would expect that unchecking would do nothing by itself, but unchecking and then clicking "Apply" should remove them from the round robin.
I would expect that unchecking would do nothing by itself, but unchecking and then clicking "Apply" should remove them from the round robin.
That's what I thought too.
Do you think it's possible that if user is part of the event-type or team, to enable un-checking the box and after pressing "Apply" the user would be removed from the event-type or team?
https://github.com/calcom/cal.com/assets/74371312/f0d8f033-1a1b-4ebf-af39-1455981147ff
Added this for event types. For teams should I change removeMember handler to accept array of teams and members or create a new handler?
https://github.com/calcom/cal.com/blob/98235d00c8177c97bd55b738b23028271824f52f/packages/trpc/server/routers/viewer/teams/removeMember.schema.ts#L3-L7
Glad to see you liked it @supalarry . I think this is still incomplete, I haven't implemented removing members from teams yet, if you can confirm this I will get to working on it too.
Do you think it's possible that if user is part of the event-type or team, to enable un-checking the box and after pressing "Apply" the user would be removed from the event-type or team?
Added this for event types. For teams should I change removeMember handler to accept array of teams and members or create a new handler?
https://github.com/calcom/cal.com/blob/98235d00c8177c97bd55b738b23028271824f52f/packages/trpc/server/routers/viewer/teams/removeMember.schema.ts#L3-L7
Glad to see you liked it @supalarry . I think this is still incomplete, I haven't implemented removing members from teams yet, if you can confirm this I will get to working on it too.
Do you think it's possible that if user is part of the event-type or team, to enable un-checking the box and after pressing "Apply" the user would be removed from the event-type or team?
Added this for event types. For teams should I change removeMember handler to accept array of teams and members or create a new handler? https://github.com/calcom/cal.com/blob/98235d00c8177c97bd55b738b23028271824f52f/packages/trpc/server/routers/viewer/teams/removeMember.schema.ts#L3-L7
That would be amazing thank you!
@supalarry please review again
https://github.com/calcom/cal.com/assets/74371312/bb04ded5-61a7-4508-9fa2-477257c6e24b
how does this look on mobile?