Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -138,6 +138,7 @@ export const GET = withWorkspace(async ({ workspace, searchParams }) => {
if (groupBy === "partnerId") {
return byPartnerId({
where,
programId,
});
}

Expand All @@ -155,8 +156,10 @@ export const GET = withWorkspace(async ({ workspace, searchParams }) => {

async function byPartnerId({
where,
programId,
}: {
where: Prisma.ProgramApplicationEventWhereInput;
programId: string;
}) {
const events = await prisma.programApplicationEvent.groupBy({
by: ["referredByPartnerId"],
Expand All @@ -175,6 +178,12 @@ async function byPartnerId({
id: {
in: partnerIds,
},
// TODO: remove this once we have a way to show the partners + CTA to invite them
programs: {
some: {
programId,
},
},
},
select: {
id: true,
Expand Down
5 changes: 2 additions & 3 deletions apps/web/ui/analytics/use-analytics-filters.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -223,7 +223,6 @@ export function useAnalyticsFilters({
// Skip special cases we handled above
if (
[
"domain",
"key",
"tagId",
"partnerTagId",
Expand All @@ -234,8 +233,8 @@ export function useAnalyticsFilters({
return;
// Also skip date range filters and qr
if (["interval", "start", "end", "qr"].includes(filter)) return;
// Skip domain if we're showing a specific link (domain + key) without linkId
if (filter === "domain" && domain && key && !params.linkId) return;
// Skip domain when domain+key identify a specific link (link chip / linkId handles that)
if (filter === "domain" && domain && key) return;

const value =
params[filter] ||
Expand Down
2 changes: 1 addition & 1 deletion apps/web/ui/layout/sidebar/app-sidebar-nav.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -478,7 +478,7 @@ const NAV_AREAS: SidebarNavAreas<SidebarNavData> = {
{
name: "Notifications",
icon: Bell,
href: `/${slug}/settings/notifications`,
href: "/settings/notifications",
arrow: true,
},
],
Expand Down
Loading