Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8487763
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T21:20:36+00:00 2026-06-10T21:20:36+00:00

I render a table with django-tables2.This is it: class VehiclesTable(tables.Table): id = tables.TemplateColumn(verbose_name=’ ‘,template_name=’editButton.html’)

  • 0

I render a table with django-tables2.This is it:

class VehiclesTable(tables.Table):
    id = tables.TemplateColumn(verbose_name=' ',template_name='editButton.html')
    plate = tables.Column(verbose_name='plate')
    vht_id = tables.Column(verbose_name='vht_i')
    vlength = tables.Column(verbose_name='vlength')
    vwidth = tables.Column(verbose_name='vwidth')

    class Meta:
       attrs = {'class': 'custom'}

I have a template column(id) that each cell of it has a button that each one renders a template. In the view that handles this template I want to pass the value of the cell next to the button cell (same row->plate). This value will be used to query the object that I want to render in a form on the new template with the button click. How can i fetch the value of the next django table cell(plate) when the user “hits” the button?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-10T21:20:38+00:00Added an answer on June 10, 2026 at 9:20 pm

    TemplateColumn renders the template using a context containing a record variable (as described in the documentation).

    In your case, this means in editButton.html you can access the plate value via {{ record.plate }}.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm using django-tables (http://pypi.python.org/pypi/django-tables/0.2) to render the contents of a MySQL table. The model
I have a TemplateColumn in a django-tables2 table and I want to use a
class BaseForm(forms.Form): def as_custom_table(self): Returns this form rendered as HTML <tr>s -- excluding the
I'm rendering a queryset with django-tables 2 but since the table is rendered at
In Django, how do I render a ModelMultipleChoiceField as a multi-column <table> ? fav
I display a database table using django-tables2. All appears OK, but clicking on the
I'm using below code to check some form fields and render datatable table on
I've created a Javascript object via prototyping. I'm trying to render a table dynamically.
I'm trying to render the sortable table that's provided in Google visualization API in
I've got a django model that contains a manytomany relationship, of the type, class

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.