mirror of
https://github.com/hanzoai/calendar.git
synced 2026-10-30 14:46:43 +00:00
* Initial commit * routingForm to Booking a particular team member working * Happy path working * Fixes * Fix router query params forwarding * Add basicConfig within app * Tests * More tests * Update packages/app-store/routing-forms/components/SingleForm.tsx Co-authored-by: Omar López <[email protected]> --------- Co-authored-by: Omar López <[email protected]> Co-authored-by: Benny Joo <[email protected]>
12 lines
420 B
TypeScript
12 lines
420 B
TypeScript
export const getRoutedTeamMemberIdsFromSearchParams = (searchParams: URLSearchParams) => {
|
|
const routedTeamMemberIdsParam = searchParams.get("cal.routedTeamMemberIds");
|
|
const routedTeamMemberIds =
|
|
typeof routedTeamMemberIdsParam === "string"
|
|
? routedTeamMemberIdsParam
|
|
.split(",")
|
|
.filter(Boolean)
|
|
.map((id) => parseInt(id, 10))
|
|
: null;
|
|
return routedTeamMemberIds;
|
|
};
|