#34292: Support display function in InlineModelAdmin
-----------------------------------------+------------------------
Reporter: Al Mahdi | Owner: nobody
Type: New feature | Status: new
Component: contrib.admin | Version: 4.2
Severity: Normal | Keywords:
Triage Stage: Unreviewed | Has patch: 0
Needs documentation: 0 | Needs tests: 0
Patch needs improvement: 0 | Easy pickings: 0
UI/UX: 0 |
-----------------------------------------+------------------------
{{{InlineModelAdmin}}} doesn't support display function
{{{
from django.contrib import admin
class SaleInline(admin.TabularInline):
model = Sale
@admin.display(description="Price")
def cost(sale):
return sale.price - sale.discount
fields = ("product", "count", "cost")
}}}
== FieldError
**Unknown field(s) (cost) specified for Sale**
--
Ticket URL: <https://code.djangoproject.com/ticket/34292>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.
--
You received this message because you are subscribed to the Google Groups
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/django-updates/01070185e9a0a6ee-885ff4ba-e8d2-4935-9651-b09228180878-000000%40eu-central-1.amazonses.com.