Rallly is an open-source scheduling and collaboration tool designed to make organizing events and meetings easier.
TypeScript i18nextnext-authnextjspostgresqlprismareact-emailt3-stacktailwindcsstrpcturborepotypescriptzod
📈 Track poll kind (date/time) in PostHog (#2748)
Luke Vellaec3493ac818d
diff --git a/apps/web/src/trpc/routers/polls.ts b/apps/web/src/trpc/routers/polls.tsindex 8de1f5c1e..c2f447359 100644--- a/apps/web/src/trpc/routers/polls.ts+++ b/apps/web/src/trpc/routers/polls.ts@@ -256,6 +256,7 @@ export const polls = router({has_description: !!description,timezone: input.timeZone,muted: poll.muted,+ kind,},});@@ -265,6 +266,7 @@ export const polls = router({event: "poll_create",properties: {title: poll.title,+ kind,optionCount: poll.options.length,hasLocation: !!location,hasDescription: !!description,@@ -445,6 +447,7 @@ export const polls = router({select: {title: true,status: true,+ kind: true,createdAt: true,location: true,description: true,@@ -453,6 +456,7 @@ export const polls = router({hideParticipants: true,hideScores: true,timeZone: true,+ muted: true,_count: {select: {participants: {@@ -471,6 +475,23 @@ export const polls = router({});}+ identifyGroup({+ groupType: "poll",+ groupKey: pollId,+ properties: {+ name: updatedPoll.title,+ status: updatedPoll.status,+ kind: updatedPoll.kind,+ created_at: updatedPoll.createdAt,+ comment_count: updatedPoll._count.comments,+ option_count: updatedPoll._count.options,+ has_location: !!updatedPoll.location,+ has_description: !!updatedPoll.description,+ timezone: updatedPoll.timeZone,+ muted: updatedPoll.muted,+ },+ });+// Track specific poll update events based on what was changedconst hasDetailsUpdate =input.title !== undefined ||