allow returning all check data
This commit is contained in:
@@ -146,11 +146,12 @@ class CheckHistory(APIView):
|
||||
timeFilter = Q()
|
||||
|
||||
if "timeFilter" in request.data:
|
||||
timeFilter = Q(
|
||||
x__lte=djangotime.make_aware(dt.today()),
|
||||
x__gt=djangotime.make_aware(dt.today())
|
||||
- djangotime.timedelta(days=request.data["timeFilter"]),
|
||||
)
|
||||
if timeFilter != 0:
|
||||
timeFilter = Q(
|
||||
x__lte=djangotime.make_aware(dt.today()),
|
||||
x__gt=djangotime.make_aware(dt.today())
|
||||
- djangotime.timedelta(days=request.data["timeFilter"]),
|
||||
)
|
||||
|
||||
check_history = check.check_history.filter(timeFilter).order_by("-x")
|
||||
|
||||
|
||||
@@ -54,6 +54,7 @@ export default {
|
||||
{ value: 1, label: "Last 24 Hours" },
|
||||
{ value: 7, label: "Last 7 Days" },
|
||||
{ value: 30, label: "Last 30 Days" },
|
||||
{ value: 0, label: "Everything" },
|
||||
],
|
||||
chartOptions: {
|
||||
tooltip: {
|
||||
|
||||
Reference in New Issue
Block a user