Compare commits
No commits in common. "72e89dae77217415e90bed3d435e287d3365ce39" and "0ee4c50a24288fd0d43dbb9e92fd0c36a250e7bd" have entirely different histories.
72e89dae77
...
0ee4c50a24
|
@ -1,8 +0,0 @@
|
||||||
{
|
|
||||||
"recommendations": [
|
|
||||||
"ms-python.black-formatter",
|
|
||||||
"ms-python.python",
|
|
||||||
"ms-python.vscode-pylance",
|
|
||||||
"ms-python.debugpy",
|
|
||||||
]
|
|
||||||
}
|
|
|
@ -4,9 +4,8 @@
|
||||||
],
|
],
|
||||||
"python.testing.unittestEnabled": false,
|
"python.testing.unittestEnabled": false,
|
||||||
"python.testing.pytestEnabled": true,
|
"python.testing.pytestEnabled": true,
|
||||||
"python.analysis.typeCheckingMode": "strict",
|
"python.analysis.typeCheckingMode": "basic",
|
||||||
"[python]": {
|
"[python]": {
|
||||||
"editor.defaultFormatter": "ms-python.black-formatter",
|
"editor.defaultFormatter": "ms-python.black-formatter"
|
||||||
"editor.formatOnSave": true
|
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
|
@ -12,8 +12,9 @@ from django.db.models import (
|
||||||
Q,
|
Q,
|
||||||
Sum,
|
Sum,
|
||||||
fields,
|
fields,
|
||||||
|
IntegerField,
|
||||||
)
|
)
|
||||||
from django.db.models.functions import TruncDate, TruncMonth
|
from django.db.models.functions import TruncDate, ExtractMonth, TruncMonth
|
||||||
from django.http import (
|
from django.http import (
|
||||||
HttpRequest,
|
HttpRequest,
|
||||||
HttpResponse,
|
HttpResponse,
|
||||||
|
@ -491,7 +492,9 @@ def stats_alltime(request):
|
||||||
Purchase.objects.all().intersection(purchases_finished_this_year).count()
|
Purchase.objects.all().intersection(purchases_finished_this_year).count()
|
||||||
)
|
)
|
||||||
|
|
||||||
|
first_play_name = "N/A"
|
||||||
first_play_date = "N/A"
|
first_play_date = "N/A"
|
||||||
|
last_play_name = "N/A"
|
||||||
last_play_date = "N/A"
|
last_play_date = "N/A"
|
||||||
if this_year_sessions:
|
if this_year_sessions:
|
||||||
first_session = this_year_sessions.earliest()
|
first_session = this_year_sessions.earliest()
|
||||||
|
@ -716,7 +719,9 @@ def stats(request, year: int = 0):
|
||||||
.count()
|
.count()
|
||||||
)
|
)
|
||||||
|
|
||||||
|
first_play_name = "N/A"
|
||||||
first_play_date = "N/A"
|
first_play_date = "N/A"
|
||||||
|
last_play_name = "N/A"
|
||||||
last_play_date = "N/A"
|
last_play_date = "N/A"
|
||||||
if this_year_sessions:
|
if this_year_sessions:
|
||||||
first_session = this_year_sessions.earliest()
|
first_session = this_year_sessions.earliest()
|
||||||
|
|
Loading…
Reference in New Issue