Open
Description
I'm migrating a larger project towards django-tables2
, and I'd like to reuse some snippets both for tables and for other locations. TemplateColumn
fills that niche very nicely, but it's hard-coded to use record
as context object name, which doesn't play well with existing templates.
There are several ways this could be solved with fairly minimal impact:
- allow to set
context_object_name
like in other Django places, defaulting torecord
- allow
extra_context
to be a callable, passing the arguments received byrender()
- move context collection to a
get_context_data
method allowing for easy subclassing
Metadata
Metadata
Assignees
Labels
No labels