示例#1
0
    def funnel(self, request: Request, *args: Any, **kwargs: Any) -> Response:

        team = request.user.team
        assert team is not None
        filter = Filter(request=request)
        response = ClickhouseFunnel(team=team, filter=filter).run()
        return Response(response)
示例#2
0
    def funnel(self, request: Request, *args: Any, **kwargs: Any) -> Response:

        if not endpoint_enabled(CH_FUNNEL_ENDPOINT, request.user.distinct_id):
            result = super().calculate_funnel(request)
            return Response(result)

        team = request.user.team
        filter = Filter(request=request)
        response = ClickhouseFunnel(team=team, filter=filter).run()
        return Response(response)
示例#3
0
文件: insights.py 项目: yianz/posthog
 def calculate_funnel(self, request: Request) -> List[Dict[str, Any]]:
     team = self.team
     filter = Filter(request=request, data={"insight": INSIGHT_FUNNELS})
     return ClickhouseFunnel(team=team, filter=filter).run()
示例#4
0
    def funnel(self, request: Request, *args: Any, **kwargs: Any) -> Response:

        team = self.team
        filter = Filter(request=request)
        response = ClickhouseFunnel(team=team, filter=filter).run()
        return Response(response)
示例#5
0
    def funnel(self, request: Request, *args: Any, **kwargs: Any) -> Response:

        team = self.team
        filter = Filter(request=request, data={"insight": INSIGHT_FUNNELS})
        response = ClickhouseFunnel(team=team, filter=filter).run()
        return Response(response)