Properly display non-game type names
This commit is contained in:
parent
57184ceea0
commit
c738245783
|
@ -44,6 +44,7 @@ def list_purchases(request: HttpRequest) -> HttpResponse:
|
||||||
"data": {
|
"data": {
|
||||||
"columns": [
|
"columns": [
|
||||||
"Name",
|
"Name",
|
||||||
|
"Type",
|
||||||
"Platform",
|
"Platform",
|
||||||
"Price",
|
"Price",
|
||||||
"Currency",
|
"Currency",
|
||||||
|
@ -67,8 +68,13 @@ def list_purchases(request: HttpRequest) -> HttpResponse:
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
],
|
],
|
||||||
truncate_with_popover(purchase.edition.game.name),
|
truncate_with_popover(
|
||||||
|
purchase.edition.game.name
|
||||||
|
if purchase.type == "game"
|
||||||
|
else f"{purchase.edition.game.name} ({purchase.name})"
|
||||||
),
|
),
|
||||||
|
),
|
||||||
|
purchase.get_type_display(),
|
||||||
purchase.platform,
|
purchase.platform,
|
||||||
purchase.price,
|
purchase.price,
|
||||||
purchase.price_currency,
|
purchase.price_currency,
|
||||||
|
|
Loading…
Reference in New Issue