Implement floating drilldown modals

This commit is contained in:
2022-08-28 20:26:15 +01:00
parent 2ce3c11da2
commit f7cda73ddf
12 changed files with 470 additions and 99 deletions

View File

@@ -411,7 +411,7 @@ class ThresholdInfoModal(APIView):
plan_name = "drilldown"
template_name = "modals/drilldown.html"
def post(self, request):
def post(self, request, type=None):
# if not request.user.has_plan(self.plan_name):
# return JsonResponse({"success": False})
if "net" not in request.data:
@@ -420,6 +420,8 @@ class ThresholdInfoModal(APIView):
return JsonResponse({"success": False})
if "channel" not in request.data:
return JsonResponse({"success": False})
if type == "window":
self.template_name = "windows/drilldown.html"
net = request.data["net"]
nick = request.data["nick"]