Skip to content

Commit

Permalink
Add basic docs, remove stub get_context_data
Browse files Browse the repository at this point in the history
  • Loading branch information
jieter committed Oct 17, 2023
1 parent 7691bf3 commit 475dd3d
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions django_tables2/columns/templatecolumn.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ class TemplateColumn(Column):
Arguments:
template_code (str): template code to render
template_name (str): name of the template to render
context_object_name (str): name of the context variable to pas the record in, defaults to "record".
extra_context (dict): optional extra template context
A `~django.template.Template` object is created from the
Expand All @@ -25,6 +26,7 @@ class TemplateColumn(Column):
- *default* -- appropriate default value to use as fallback.
- *row_counter* -- The number of the row this cell is being rendered in.
- any context variables passed using the `extra_context` argument to `TemplateColumn`.
If ``extra_context`` is a callable, it will be called with optional record, table, value, bound_column arguments.
Example:
Expand Down Expand Up @@ -91,6 +93,3 @@ def value(self, **kwargs):
"""
html = super().value(**kwargs)
return strip_tags(html).strip() if isinstance(html, str) else html

def get_context_data(self, **kwargs):
return

0 comments on commit 475dd3d

Please sign in to comment.